linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Weston Andros Adamson <dros@netapp.com>
To: bfields@fieldses.org
Cc: bjschuma@netapp.com, linux-nfs@vger.kernel.org,
	Weston Andros Adamson <dros@netapp.com>
Subject: [PATCH] nfsd: return 0 on reads of fault injection files
Date: Thu, 10 May 2012 15:31:10 -0400	[thread overview]
Message-ID: <1336678270-791-1-git-send-email-dros@netapp.com> (raw)

debugfs read operations were returning the contents of an uninitialized u64.

Signed-off-by: Weston Andros Adamson <dros@netapp.com>
---
I found this while working on (forthcoming) fault injection tests for 
CB_PATH_DOWN.

 fs/nfsd/fault_inject.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/fs/nfsd/fault_inject.c b/fs/nfsd/fault_inject.c
index 46b7696..ab81144 100644
--- a/fs/nfsd/fault_inject.c
+++ b/fs/nfsd/fault_inject.c
@@ -62,6 +62,7 @@ static int nfsd_inject_set(void *op_ptr, u64 val)
 
 static int nfsd_inject_get(void *data, u64 *val)
 {
+	*val = 0;
 	return 0;
 }
 
-- 
1.7.4.4


             reply	other threads:[~2012-05-10 19:31 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-10 19:31 Weston Andros Adamson [this message]
2012-05-16 21:16 ` [PATCH] nfsd: return 0 on reads of fault injection files J. Bruce Fields
2012-05-16 21:50   ` Adamson, Dros
2012-05-16 21:58     ` J. Bruce Fields
2012-05-16 22:10       ` Adamson, Dros
2012-05-17 11:33         ` J. Bruce Fields

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1336678270-791-1-git-send-email-dros@netapp.com \
    --to=dros@netapp.com \
    --cc=bfields@fieldses.org \
    --cc=bjschuma@netapp.com \
    --cc=linux-nfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).