Re: [PATCH 2/5] ksmbd: don't open-code file_path()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2022-08-18 11:58 GMT+09:00, Al Viro <viro@xxxxxxxxxxxxxxxxxx>:
> Signed-off-by: Al Viro <viro@xxxxxxxxxxxxxxxxxx>
Acked-by: Namjae Jeon <linkinjeon@xxxxxxxxxx>

Thanks!
> ---
>  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
>
>



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux