From: Al Viro <viro@zeniv.linux.org.uk>
To: linux-fsdevel@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH 2/5] ksmbd: don't open-code file_path()
Date: Thu, 18 Aug 2022 03:58:17 +0100 [thread overview]
Message-ID: <Yv2qyayq+Jo/+Uvs@ZenIV> (raw)
In-Reply-To: <Yv2qoNQg48rtymGE@ZenIV>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
---
fs/ksmbd/smb2pdu.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/ksmbd/smb2pdu.c b/fs/ksmbd/smb2pdu.c
index 9751cc92c111..0e1924a6476d 100644
--- a/fs/ksmbd/smb2pdu.c
+++ b/fs/ksmbd/smb2pdu.c
@@ -5416,7 +5416,7 @@ static int smb2_rename(struct ksmbd_work *work,
if (!pathname)
return -ENOMEM;
- abs_oldname = d_path(&fp->filp->f_path, pathname, PATH_MAX);
+ abs_oldname = file_path(fp->filp, pathname, PATH_MAX);
if (IS_ERR(abs_oldname)) {
rc = -EINVAL;
goto out;
@@ -5551,7 +5551,7 @@ static int smb2_create_link(struct ksmbd_work *work,
}
ksmbd_debug(SMB, "link name is %s\n", link_name);
- target_name = d_path(&filp->f_path, pathname, PATH_MAX);
+ target_name = file_path(filp, pathname, PATH_MAX);
if (IS_ERR(target_name)) {
rc = -EINVAL;
goto out;
--
2.30.2
next prev parent reply other threads:[~2022-08-18 2:58 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-18 2:57 [PATCH 1/5] dynamic_dname(): drop unused dentry argument Al Viro
2022-08-18 2:58 ` Al Viro [this message]
2022-08-18 6:19 ` [PATCH 2/5] ksmbd: don't open-code file_path() Namjae Jeon
2022-08-18 2:58 ` [PATCH 3/5] ->getprocattr(): attribute name is const char *, TYVM Al Viro
2022-08-18 18:34 ` Schaufler, Casey
2022-08-26 7:45 ` Christian Brauner
2022-08-18 2:59 ` [PATCH 4/5] ksmbd: don't open-code %pf Al Viro
2022-08-18 6:08 ` Namjae Jeon
2022-08-18 20:35 ` Al Viro
2022-08-18 23:26 ` Namjae Jeon
2022-08-20 3:47 ` Al Viro
2022-08-20 5:44 ` Namjae Jeon
2022-08-20 15:33 ` Al Viro
2022-08-21 2:06 ` Steve French
2022-08-18 2:59 ` [PATCH 5/5] d_path.c: typo fix Al Viro
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=Yv2qyayq+Jo/+Uvs@ZenIV \
--to=viro@zeniv.linux.org.uk \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@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).