diff options
author | Neil Brown <neilb@suse.de> | 2005-09-13 04:25:36 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-09-13 11:22:31 -0400 |
commit | 849823c52d9c96cf777038670bb0ee3a291ca69d (patch) | |
tree | d593c56185566e1257bf9483509c8ce5acad5ee6 /fs/nfsd/nfs4state.c | |
parent | fff71312e7227c6850f367ff9c72f96d5b33b1d0 (diff) |
[PATCH] nfsd4: printk reduction
Demote some printk's that look like they could be triggered by non-buggy
clients to dprintk's. (For example, stale clientid's are normal
occurrences on reboot, and on a server with a lot of clients these messages
could become annoying.)
Also remove some redundant dprintk's (e.g. no need for both STALE_CLIENTID
and its callers to do dprintks).
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/nfsd/nfs4state.c')
-rw-r--r-- | fs/nfsd/nfs4state.c | 27 |
1 files changed, 10 insertions, 17 deletions
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index b83f8fb441e1..109fd8c3d4f5 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c | |||
@@ -624,7 +624,7 @@ gen_callback(struct nfs4_client *clp, struct nfsd4_setclientid *se) | |||
624 | cb->cb_ident = se->se_callback_ident; | 624 | cb->cb_ident = se->se_callback_ident; |
625 | return; | 625 | return; |
626 | out_err: | 626 | out_err: |
627 | printk(KERN_INFO "NFSD: this client (clientid %08x/%08x) " | 627 | dprintk(KERN_INFO "NFSD: this client (clientid %08x/%08x) " |
628 | "will not receive delegations\n", | 628 | "will not receive delegations\n", |
629 | clp->cl_clientid.cl_boot, clp->cl_clientid.cl_id); | 629 | clp->cl_clientid.cl_boot, clp->cl_clientid.cl_id); |
630 | 630 | ||
@@ -2014,7 +2014,7 @@ STALE_STATEID(stateid_t *stateid) | |||
2014 | { | 2014 | { |
2015 | if (stateid->si_boot == boot_time) | 2015 | if (stateid->si_boot == boot_time) |
2016 | return 0; | 2016 | return 0; |
2017 | printk("NFSD: stale stateid (%08x/%08x/%08x/%08x)!\n", | 2017 | dprintk("NFSD: stale stateid (%08x/%08x/%08x/%08x)!\n", |
2018 | stateid->si_boot, stateid->si_stateownerid, stateid->si_fileid, | 2018 | stateid->si_boot, stateid->si_stateownerid, stateid->si_fileid, |
2019 | stateid->si_generation); | 2019 | stateid->si_generation); |
2020 | return 1; | 2020 | return 1; |
@@ -2275,7 +2275,7 @@ nfs4_preprocess_seqid_op(struct svc_fh *current_fh, u32 seqid, stateid_t *statei | |||
2275 | 2275 | ||
2276 | check_replay: | 2276 | check_replay: |
2277 | if (seqid == sop->so_seqid - 1) { | 2277 | if (seqid == sop->so_seqid - 1) { |
2278 | printk("NFSD: preprocess_seqid_op: retransmission?\n"); | 2278 | dprintk("NFSD: preprocess_seqid_op: retransmission?\n"); |
2279 | /* indicate replay to calling function */ | 2279 | /* indicate replay to calling function */ |
2280 | return NFSERR_REPLAY_ME; | 2280 | return NFSERR_REPLAY_ME; |
2281 | } | 2281 | } |
@@ -2500,8 +2500,7 @@ find_stateid(stateid_t *stid, int flags) | |||
2500 | (local->st_stateid.si_fileid == f_id)) | 2500 | (local->st_stateid.si_fileid == f_id)) |
2501 | return local; | 2501 | return local; |
2502 | } | 2502 | } |
2503 | } else | 2503 | } |
2504 | printk("NFSD: find_stateid: ERROR: no state flag\n"); | ||
2505 | return NULL; | 2504 | return NULL; |
2506 | } | 2505 | } |
2507 | 2506 | ||
@@ -2705,10 +2704,8 @@ nfsd4_lock(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_lock | |||
2705 | struct nfs4_file *fp; | 2704 | struct nfs4_file *fp; |
2706 | 2705 | ||
2707 | status = nfserr_stale_clientid; | 2706 | status = nfserr_stale_clientid; |
2708 | if (STALE_CLIENTID(&lock->lk_new_clientid)) { | 2707 | if (STALE_CLIENTID(&lock->lk_new_clientid)) |
2709 | printk("NFSD: nfsd4_lock: clientid is stale!\n"); | ||
2710 | goto out; | 2708 | goto out; |
2711 | } | ||
2712 | 2709 | ||
2713 | /* validate and update open stateid and open seqid */ | 2710 | /* validate and update open stateid and open seqid */ |
2714 | status = nfs4_preprocess_seqid_op(current_fh, | 2711 | status = nfs4_preprocess_seqid_op(current_fh, |
@@ -2751,7 +2748,7 @@ nfsd4_lock(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_lock | |||
2751 | filp = lock_stp->st_vfs_file; | 2748 | filp = lock_stp->st_vfs_file; |
2752 | 2749 | ||
2753 | if ((status = fh_verify(rqstp, current_fh, S_IFREG, MAY_LOCK))) { | 2750 | if ((status = fh_verify(rqstp, current_fh, S_IFREG, MAY_LOCK))) { |
2754 | printk("NFSD: nfsd4_lock: permission denied!\n"); | 2751 | dprintk("NFSD: nfsd4_lock: permission denied!\n"); |
2755 | goto out; | 2752 | goto out; |
2756 | } | 2753 | } |
2757 | 2754 | ||
@@ -2866,13 +2863,11 @@ nfsd4_lockt(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_lock | |||
2866 | nfs4_lock_state(); | 2863 | nfs4_lock_state(); |
2867 | 2864 | ||
2868 | status = nfserr_stale_clientid; | 2865 | status = nfserr_stale_clientid; |
2869 | if (STALE_CLIENTID(&lockt->lt_clientid)) { | 2866 | if (STALE_CLIENTID(&lockt->lt_clientid)) |
2870 | printk("NFSD: nfsd4_lockt: clientid is stale!\n"); | ||
2871 | goto out; | 2867 | goto out; |
2872 | } | ||
2873 | 2868 | ||
2874 | if ((status = fh_verify(rqstp, current_fh, S_IFREG, 0))) { | 2869 | if ((status = fh_verify(rqstp, current_fh, S_IFREG, 0))) { |
2875 | printk("NFSD: nfsd4_lockt: fh_verify() failed!\n"); | 2870 | dprintk("NFSD: nfsd4_lockt: fh_verify() failed!\n"); |
2876 | if (status == nfserr_symlink) | 2871 | if (status == nfserr_symlink) |
2877 | status = nfserr_inval; | 2872 | status = nfserr_inval; |
2878 | goto out; | 2873 | goto out; |
@@ -2976,7 +2971,7 @@ nfsd4_locku(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_lock | |||
2976 | if (file_lock.fl_ops && file_lock.fl_ops->fl_release_private) | 2971 | if (file_lock.fl_ops && file_lock.fl_ops->fl_release_private) |
2977 | file_lock.fl_ops->fl_release_private(&file_lock); | 2972 | file_lock.fl_ops->fl_release_private(&file_lock); |
2978 | if (status) { | 2973 | if (status) { |
2979 | printk("NFSD: nfs4_locku: posix_lock_file failed!\n"); | 2974 | dprintk("NFSD: nfs4_locku: posix_lock_file failed!\n"); |
2980 | goto out_nfserr; | 2975 | goto out_nfserr; |
2981 | } | 2976 | } |
2982 | /* | 2977 | /* |
@@ -3036,10 +3031,8 @@ nfsd4_release_lockowner(struct svc_rqst *rqstp, struct nfsd4_release_lockowner * | |||
3036 | /* XXX check for lease expiration */ | 3031 | /* XXX check for lease expiration */ |
3037 | 3032 | ||
3038 | status = nfserr_stale_clientid; | 3033 | status = nfserr_stale_clientid; |
3039 | if (STALE_CLIENTID(clid)) { | 3034 | if (STALE_CLIENTID(clid)) |
3040 | printk("NFSD: nfsd4_release_lockowner: clientid is stale!\n"); | ||
3041 | return status; | 3035 | return status; |
3042 | } | ||
3043 | 3036 | ||
3044 | nfs4_lock_state(); | 3037 | nfs4_lock_state(); |
3045 | 3038 | ||