aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2013-09-16 10:57:01 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2013-10-24 23:34:51 -0400
commita6a9f18f0a9f943ada095753bdc4346aee67b1aa (patch)
tree267b42f505d580dd29c15dd7bf553ba27548bfe1 /fs
parent6de1472f1a4a3bd912f515f29d3cf52a65a4c718 (diff)
nfsd: switch to %p[dD]
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs')
-rw-r--r--fs/nfsd/nfs4recover.c12
-rw-r--r--fs/nfsd/nfs4state.c15
-rw-r--r--fs/nfsd/nfsfh.c28
-rw-r--r--fs/nfsd/nfsfh.h4
-rw-r--r--fs/nfsd/vfs.c9
5 files changed, 31 insertions, 37 deletions
diff --git a/fs/nfsd/nfs4recover.c b/fs/nfsd/nfs4recover.c
index e0a65a9e37e9..9c271f42604a 100644
--- a/fs/nfsd/nfs4recover.c
+++ b/fs/nfsd/nfs4recover.c
@@ -385,8 +385,8 @@ purge_old(struct dentry *parent, struct dentry *child, struct nfsd_net *nn)
385 385
386 status = vfs_rmdir(parent->d_inode, child); 386 status = vfs_rmdir(parent->d_inode, child);
387 if (status) 387 if (status)
388 printk("failed to remove client recovery directory %s\n", 388 printk("failed to remove client recovery directory %pd\n",
389 child->d_name.name); 389 child);
390 /* Keep trying, success or failure: */ 390 /* Keep trying, success or failure: */
391 return 0; 391 return 0;
392} 392}
@@ -410,15 +410,15 @@ out:
410 nfs4_release_reclaim(nn); 410 nfs4_release_reclaim(nn);
411 if (status) 411 if (status)
412 printk("nfsd4: failed to purge old clients from recovery" 412 printk("nfsd4: failed to purge old clients from recovery"
413 " directory %s\n", nn->rec_file->f_path.dentry->d_name.name); 413 " directory %pD\n", nn->rec_file);
414} 414}
415 415
416static int 416static int
417load_recdir(struct dentry *parent, struct dentry *child, struct nfsd_net *nn) 417load_recdir(struct dentry *parent, struct dentry *child, struct nfsd_net *nn)
418{ 418{
419 if (child->d_name.len != HEXDIR_LEN - 1) { 419 if (child->d_name.len != HEXDIR_LEN - 1) {
420 printk("nfsd4: illegal name %s in recovery directory\n", 420 printk("nfsd4: illegal name %pd in recovery directory\n",
421 child->d_name.name); 421 child);
422 /* Keep trying; maybe the others are OK: */ 422 /* Keep trying; maybe the others are OK: */
423 return 0; 423 return 0;
424 } 424 }
@@ -437,7 +437,7 @@ nfsd4_recdir_load(struct net *net) {
437 status = nfsd4_list_rec_dir(load_recdir, nn); 437 status = nfsd4_list_rec_dir(load_recdir, nn);
438 if (status) 438 if (status)
439 printk("nfsd4: failed loading clients from recovery" 439 printk("nfsd4: failed loading clients from recovery"
440 " directory %s\n", nn->rec_file->f_path.dentry->d_name.name); 440 " directory %pD\n", nn->rec_file);
441 return status; 441 return status;
442} 442}
443 443
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
index 0874998a49cd..a601fd49f997 100644
--- a/fs/nfsd/nfs4state.c
+++ b/fs/nfsd/nfs4state.c
@@ -3843,9 +3843,8 @@ nfsd4_open_confirm(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
3843 struct nfs4_ol_stateid *stp; 3843 struct nfs4_ol_stateid *stp;
3844 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id); 3844 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
3845 3845
3846 dprintk("NFSD: nfsd4_open_confirm on file %.*s\n", 3846 dprintk("NFSD: nfsd4_open_confirm on file %pd\n",
3847 (int)cstate->current_fh.fh_dentry->d_name.len, 3847 cstate->current_fh.fh_dentry);
3848 cstate->current_fh.fh_dentry->d_name.name);
3849 3848
3850 status = fh_verify(rqstp, &cstate->current_fh, S_IFREG, 0); 3849 status = fh_verify(rqstp, &cstate->current_fh, S_IFREG, 0);
3851 if (status) 3850 if (status)
@@ -3922,9 +3921,8 @@ nfsd4_open_downgrade(struct svc_rqst *rqstp,
3922 struct nfs4_ol_stateid *stp; 3921 struct nfs4_ol_stateid *stp;
3923 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id); 3922 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
3924 3923
3925 dprintk("NFSD: nfsd4_open_downgrade on file %.*s\n", 3924 dprintk("NFSD: nfsd4_open_downgrade on file %pd\n",
3926 (int)cstate->current_fh.fh_dentry->d_name.len, 3925 cstate->current_fh.fh_dentry);
3927 cstate->current_fh.fh_dentry->d_name.name);
3928 3926
3929 /* We don't yet support WANT bits: */ 3927 /* We don't yet support WANT bits: */
3930 if (od->od_deleg_want) 3928 if (od->od_deleg_want)
@@ -3980,9 +3978,8 @@ nfsd4_close(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
3980 struct net *net = SVC_NET(rqstp); 3978 struct net *net = SVC_NET(rqstp);
3981 struct nfsd_net *nn = net_generic(net, nfsd_net_id); 3979 struct nfsd_net *nn = net_generic(net, nfsd_net_id);
3982 3980
3983 dprintk("NFSD: nfsd4_close on file %.*s\n", 3981 dprintk("NFSD: nfsd4_close on file %pd\n",
3984 (int)cstate->current_fh.fh_dentry->d_name.len, 3982 cstate->current_fh.fh_dentry);
3985 cstate->current_fh.fh_dentry->d_name.name);
3986 3983
3987 nfs4_lock_state(); 3984 nfs4_lock_state();
3988 status = nfs4_preprocess_seqid_op(cstate, close->cl_seqid, 3985 status = nfs4_preprocess_seqid_op(cstate, close->cl_seqid,
diff --git a/fs/nfsd/nfsfh.c b/fs/nfsd/nfsfh.c
index 814afaa4458a..3d0e15ae6f72 100644
--- a/fs/nfsd/nfsfh.c
+++ b/fs/nfsd/nfsfh.c
@@ -47,7 +47,7 @@ static int nfsd_acceptable(void *expv, struct dentry *dentry)
47 tdentry = parent; 47 tdentry = parent;
48 } 48 }
49 if (tdentry != exp->ex_path.dentry) 49 if (tdentry != exp->ex_path.dentry)
50 dprintk("nfsd_acceptable failed at %p %s\n", tdentry, tdentry->d_name.name); 50 dprintk("nfsd_acceptable failed at %p %pd\n", tdentry, tdentry);
51 rv = (tdentry == exp->ex_path.dentry); 51 rv = (tdentry == exp->ex_path.dentry);
52 dput(tdentry); 52 dput(tdentry);
53 return rv; 53 return rv;
@@ -253,8 +253,8 @@ static __be32 nfsd_set_fh_dentry(struct svc_rqst *rqstp, struct svc_fh *fhp)
253 253
254 if (S_ISDIR(dentry->d_inode->i_mode) && 254 if (S_ISDIR(dentry->d_inode->i_mode) &&
255 (dentry->d_flags & DCACHE_DISCONNECTED)) { 255 (dentry->d_flags & DCACHE_DISCONNECTED)) {
256 printk("nfsd: find_fh_dentry returned a DISCONNECTED directory: %s/%s\n", 256 printk("nfsd: find_fh_dentry returned a DISCONNECTED directory: %pd2\n",
257 dentry->d_parent->d_name.name, dentry->d_name.name); 257 dentry);
258 } 258 }
259 259
260 fhp->fh_dentry = dentry; 260 fhp->fh_dentry = dentry;
@@ -361,10 +361,9 @@ skip_pseudoflavor_check:
361 error = nfsd_permission(rqstp, exp, dentry, access); 361 error = nfsd_permission(rqstp, exp, dentry, access);
362 362
363 if (error) { 363 if (error) {
364 dprintk("fh_verify: %s/%s permission failure, " 364 dprintk("fh_verify: %pd2 permission failure, "
365 "acc=%x, error=%d\n", 365 "acc=%x, error=%d\n",
366 dentry->d_parent->d_name.name, 366 dentry,
367 dentry->d_name.name,
368 access, ntohl(error)); 367 access, ntohl(error));
369 } 368 }
370out: 369out:
@@ -514,14 +513,13 @@ fh_compose(struct svc_fh *fhp, struct svc_export *exp, struct dentry *dentry,
514 */ 513 */
515 514
516 struct inode * inode = dentry->d_inode; 515 struct inode * inode = dentry->d_inode;
517 struct dentry *parent = dentry->d_parent;
518 __u32 *datap; 516 __u32 *datap;
519 dev_t ex_dev = exp_sb(exp)->s_dev; 517 dev_t ex_dev = exp_sb(exp)->s_dev;
520 518
521 dprintk("nfsd: fh_compose(exp %02x:%02x/%ld %s/%s, ino=%ld)\n", 519 dprintk("nfsd: fh_compose(exp %02x:%02x/%ld %pd2, ino=%ld)\n",
522 MAJOR(ex_dev), MINOR(ex_dev), 520 MAJOR(ex_dev), MINOR(ex_dev),
523 (long) exp->ex_path.dentry->d_inode->i_ino, 521 (long) exp->ex_path.dentry->d_inode->i_ino,
524 parent->d_name.name, dentry->d_name.name, 522 dentry,
525 (inode ? inode->i_ino : 0)); 523 (inode ? inode->i_ino : 0));
526 524
527 /* Choose filehandle version and fsid type based on 525 /* Choose filehandle version and fsid type based on
@@ -534,13 +532,13 @@ fh_compose(struct svc_fh *fhp, struct svc_export *exp, struct dentry *dentry,
534 fh_put(ref_fh); 532 fh_put(ref_fh);
535 533
536 if (fhp->fh_locked || fhp->fh_dentry) { 534 if (fhp->fh_locked || fhp->fh_dentry) {
537 printk(KERN_ERR "fh_compose: fh %s/%s not initialized!\n", 535 printk(KERN_ERR "fh_compose: fh %pd2 not initialized!\n",
538 parent->d_name.name, dentry->d_name.name); 536 dentry);
539 } 537 }
540 if (fhp->fh_maxsize < NFS_FHSIZE) 538 if (fhp->fh_maxsize < NFS_FHSIZE)
541 printk(KERN_ERR "fh_compose: called with maxsize %d! %s/%s\n", 539 printk(KERN_ERR "fh_compose: called with maxsize %d! %pd2\n",
542 fhp->fh_maxsize, 540 fhp->fh_maxsize,
543 parent->d_name.name, dentry->d_name.name); 541 dentry);
544 542
545 fhp->fh_dentry = dget(dentry); /* our internal copy */ 543 fhp->fh_dentry = dget(dentry); /* our internal copy */
546 fhp->fh_export = exp; 544 fhp->fh_export = exp;
@@ -613,8 +611,8 @@ out_bad:
613 printk(KERN_ERR "fh_update: fh not verified!\n"); 611 printk(KERN_ERR "fh_update: fh not verified!\n");
614 goto out; 612 goto out;
615out_negative: 613out_negative:
616 printk(KERN_ERR "fh_update: %s/%s still negative!\n", 614 printk(KERN_ERR "fh_update: %pd2 still negative!\n",
617 dentry->d_parent->d_name.name, dentry->d_name.name); 615 dentry);
618 goto out; 616 goto out;
619} 617}
620 618
diff --git a/fs/nfsd/nfsfh.h b/fs/nfsd/nfsfh.h
index e5e6707ba687..4775bc4896c8 100644
--- a/fs/nfsd/nfsfh.h
+++ b/fs/nfsd/nfsfh.h
@@ -173,8 +173,8 @@ fh_lock_nested(struct svc_fh *fhp, unsigned int subclass)
173 BUG_ON(!dentry); 173 BUG_ON(!dentry);
174 174
175 if (fhp->fh_locked) { 175 if (fhp->fh_locked) {
176 printk(KERN_WARNING "fh_lock: %s/%s already locked!\n", 176 printk(KERN_WARNING "fh_lock: %pd2 already locked!\n",
177 dentry->d_parent->d_name.name, dentry->d_name.name); 177 dentry);
178 return; 178 return;
179 } 179 }
180 180
diff --git a/fs/nfsd/vfs.c b/fs/nfsd/vfs.c
index c827acb0e943..13886f7f40d5 100644
--- a/fs/nfsd/vfs.c
+++ b/fs/nfsd/vfs.c
@@ -1317,9 +1317,8 @@ nfsd_create(struct svc_rqst *rqstp, struct svc_fh *fhp,
1317 if (!fhp->fh_locked) { 1317 if (!fhp->fh_locked) {
1318 /* not actually possible */ 1318 /* not actually possible */
1319 printk(KERN_ERR 1319 printk(KERN_ERR
1320 "nfsd_create: parent %s/%s not locked!\n", 1320 "nfsd_create: parent %pd2 not locked!\n",
1321 dentry->d_parent->d_name.name, 1321 dentry);
1322 dentry->d_name.name);
1323 err = nfserr_io; 1322 err = nfserr_io;
1324 goto out; 1323 goto out;
1325 } 1324 }
@@ -1329,8 +1328,8 @@ nfsd_create(struct svc_rqst *rqstp, struct svc_fh *fhp,
1329 */ 1328 */
1330 err = nfserr_exist; 1329 err = nfserr_exist;
1331 if (dchild->d_inode) { 1330 if (dchild->d_inode) {
1332 dprintk("nfsd_create: dentry %s/%s not negative!\n", 1331 dprintk("nfsd_create: dentry %pd/%pd not negative!\n",
1333 dentry->d_name.name, dchild->d_name.name); 1332 dentry, dchild);
1334 goto out; 1333 goto out;
1335 } 1334 }
1336 1335