From: Al Viro <viro@zeniv.linux.org.uk>
To: Stefan Roesch <shr@fb.com>
Cc: io-uring@vger.kernel.org, linux-fsdevel@vger.kernel.org,
kernel-team@fb.com
Subject: Re: [PATCH v2 1/2] fs: replace const char* parameter in vfs_statx and do_statx with struct filename
Date: Tue, 15 Feb 2022 01:15:11 +0000 [thread overview]
Message-ID: <Ygr+nzDK6ft6LXfG@zeniv-ca.linux.org.uk> (raw)
In-Reply-To: <20220215002121.2049686-2-shr@fb.com>
On Mon, Feb 14, 2022 at 04:21:20PM -0800, Stefan Roesch wrote:
> {
> - return do_statx(dfd, filename, flags, mask, buffer);
> + int ret;
> + struct filename *name;
> +
> + name = getname_flags(filename, getname_statx_lookup_flags(flags), NULL);
> + ret = do_statx(dfd, name, flags, mask, buffer);
> + if (name)
> + putname(name);
... and the same comment goes for this one - getname... does *not*
report a failure as NULL; it's ERR_PTR(), and putname(ERR_PTR(...))
is an explicit no-op.
next prev parent reply other threads:[~2022-02-15 1:15 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-15 0:21 [PATCH v2 0/2] io-uring: Make statx api stable Stefan Roesch
2022-02-15 0:21 ` [PATCH v2 1/2] fs: replace const char* parameter in vfs_statx and do_statx with struct filename Stefan Roesch
2022-02-15 1:15 ` Al Viro [this message]
2022-02-15 18:19 ` Stefan Roesch
2022-02-15 0:21 ` [PATCH v2 2/2] io-uring: Copy path name during prepare stage for statx Stefan Roesch
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=Ygr+nzDK6ft6LXfG@zeniv-ca.linux.org.uk \
--to=viro@zeniv.linux.org.uk \
--cc=io-uring@vger.kernel.org \
--cc=kernel-team@fb.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=shr@fb.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.