From: Jia He <justin.he@arm.com>
To: Linus Torvalds <torvalds@linux-foundation.org>,
Petr Mladek <pmladek@suse.com>,
Steven Rostedt <rostedt@goodmis.org>,
Sergey Senozhatsky <senozhatsky@chromium.org>,
Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
Rasmus Villemoes <linux@rasmusvillemoes.dk>,
Jonathan Corbet <corbet@lwn.net>,
Alexander Viro <viro@zeniv.linux.org.uk>,
Luca Coelho <luciano.coelho@intel.com>,
Kalle Valo <kvalo@codeaurora.org>,
"David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
Heiko Carstens <hca@linux.ibm.com>,
Vasily Gorbik <gor@linux.ibm.com>
Cc: Christian Borntraeger <borntraeger@de.ibm.com>,
Johannes Berg <johannes.berg@intel.com>,
linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-wireless@vger.kernel.org, netdev@vger.kernel.org,
linux-s390@vger.kernel.org, Jia He <justin.he@arm.com>
Subject: [PATCH RFCv2 3/3] s390/hmcdrv: remove the redundant directory path in debug message
Date: Fri, 28 May 2021 19:39:51 +0800 [thread overview]
Message-ID: <20210528113951.6225-4-justin.he@arm.com> (raw)
In-Reply-To: <20210528113951.6225-1-justin.he@arm.com>
It would be better to use full file path with '%pD' instead of hard coding.
Signed-off-by: Jia He <justin.he@arm.com>
---
drivers/s390/char/hmcdrv_dev.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/s390/char/hmcdrv_dev.c b/drivers/s390/char/hmcdrv_dev.c
index 20e9cd542e03..cdde75508c8a 100644
--- a/drivers/s390/char/hmcdrv_dev.c
+++ b/drivers/s390/char/hmcdrv_dev.c
@@ -137,7 +137,7 @@ static int hmcdrv_dev_open(struct inode *inode, struct file *fp)
if (rc)
module_put(THIS_MODULE);
- pr_debug("open file '/dev/%pD' with return code %d\n", fp, rc);
+ pr_debug("open file '%pD' with return code %d\n", fp, rc);
return rc;
}
@@ -146,7 +146,7 @@ static int hmcdrv_dev_open(struct inode *inode, struct file *fp)
*/
static int hmcdrv_dev_release(struct inode *inode, struct file *fp)
{
- pr_debug("closing file '/dev/%pD'\n", fp);
+ pr_debug("closing file '%pD'\n", fp);
kfree(fp->private_data);
fp->private_data = NULL;
hmcdrv_ftp_shutdown();
@@ -231,7 +231,7 @@ static ssize_t hmcdrv_dev_read(struct file *fp, char __user *ubuf,
retlen = hmcdrv_dev_transfer((char *) fp->private_data,
*pos, ubuf, len);
- pr_debug("read from file '/dev/%pD' at %lld returns %zd/%zu\n",
+ pr_debug("read from file '%pD' at %lld returns %zd/%zu\n",
fp, (long long) *pos, retlen, len);
if (retlen > 0)
@@ -248,7 +248,7 @@ static ssize_t hmcdrv_dev_write(struct file *fp, const char __user *ubuf,
{
ssize_t retlen;
- pr_debug("writing file '/dev/%pD' at pos. %lld with length %zd\n",
+ pr_debug("writing file '%pD' at pos. %lld with length %zd\n",
fp, (long long) *pos, len);
if (!fp->private_data) { /* first expect a cmd write */
@@ -272,7 +272,7 @@ static ssize_t hmcdrv_dev_write(struct file *fp, const char __user *ubuf,
if (retlen > 0)
*pos += retlen;
- pr_debug("write to file '/dev/%pD' returned %zd\n", fp, retlen);
+ pr_debug("write to file '%pD' returned %zd\n", fp, retlen);
return retlen;
}
--
2.17.1
prev parent reply other threads:[~2021-05-28 11:40 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-28 11:39 [PATCH RFCv2 0/3] make '%pD' print full path for file Jia He
2021-05-28 11:39 ` [PATCH RFCv2 1/3] fs: introduce helper d_path_fast() Jia He
2021-05-28 12:44 ` Al Viro
2021-05-28 12:51 ` Matthew Wilcox
2021-05-28 14:23 ` Justin He
2021-05-28 11:39 ` [PATCH RFCv2 2/3] lib/vsprintf.c: make %pD print full path for file Jia He
2021-05-28 12:59 ` Matthew Wilcox
2021-05-28 14:22 ` Justin He
2021-05-28 14:52 ` Matthew Wilcox
2021-05-28 15:09 ` Justin He
2021-05-28 15:22 ` Matthew Wilcox
2021-05-31 0:39 ` Justin He
2021-06-01 14:42 ` Justin He
2021-06-01 15:30 ` Matthew Wilcox
2021-06-01 15:36 ` Andy Shevchenko
2021-06-01 15:44 ` Matthew Wilcox
2021-06-01 15:53 ` Andy Shevchenko
2021-06-01 16:10 ` Andy Shevchenko
2021-06-01 17:05 ` Matthew Wilcox
2021-06-01 19:01 ` Rasmus Villemoes
2021-06-02 5:47 ` Justin He
2021-05-28 20:06 ` Rasmus Villemoes
2021-05-30 15:18 ` Matthew Wilcox
2021-05-31 9:40 ` Petr Mladek
2021-05-28 11:39 ` Jia He [this message]
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=20210528113951.6225-4-justin.he@arm.com \
--to=justin.he@arm.com \
--cc=andriy.shevchenko@linux.intel.com \
--cc=borntraeger@de.ibm.com \
--cc=corbet@lwn.net \
--cc=davem@davemloft.net \
--cc=gor@linux.ibm.com \
--cc=hca@linux.ibm.com \
--cc=johannes.berg@intel.com \
--cc=kuba@kernel.org \
--cc=kvalo@codeaurora.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=linux@rasmusvillemoes.dk \
--cc=luciano.coelho@intel.com \
--cc=netdev@vger.kernel.org \
--cc=pmladek@suse.com \
--cc=rostedt@goodmis.org \
--cc=senozhatsky@chromium.org \
--cc=torvalds@linux-foundation.org \
--cc=viro@zeniv.linux.org.uk \
/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).