From: Al Viro <viro@zeniv.linux.org.uk>
To: Jens Axboe <axboe@kernel.dk>
Cc: linux-fsdevel <linux-fsdevel@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v4] eventfd: convert to f_op->read_iter()
Date: Sat, 2 May 2020 00:12:31 +0100 [thread overview]
Message-ID: <20200501231231.GR23230@ZenIV.linux.org.uk> (raw)
In-Reply-To: <6b29f015-bd7c-0601-cf94-2c077285b933@kernel.dk>
On Fri, May 01, 2020 at 01:11:09PM -0600, Jens Axboe wrote:
> + flags &= EFD_SHARED_FCNTL_FLAGS;
> + flags |= O_RDWR;
> + fd = get_unused_fd_flags(flags);
> if (fd < 0)
> - eventfd_free_ctx(ctx);
> + goto err;
> +
> + file = anon_inode_getfile("[eventfd]", &eventfd_fops, ctx, flags);
> + if (IS_ERR(file)) {
> + put_unused_fd(fd);
> + fd = PTR_ERR(file);
> + goto err;
> + }
>
> + file->f_mode |= FMODE_NOWAIT;
> + fd_install(fd, file);
> + return fd;
> +err:
> + eventfd_free_ctx(ctx);
> return fd;
> }
Looks sane... I can take it via vfs.git, or leave it for you if you
have other stuff in the same area...
next prev parent reply other threads:[~2020-05-01 23:12 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-01 19:11 [PATCH v4] eventfd: convert to f_op->read_iter() Jens Axboe
2020-05-01 23:12 ` Al Viro [this message]
2020-05-01 23:54 ` Jens Axboe
2020-05-03 13:46 ` Al Viro
2020-05-03 14:42 ` Jens Axboe
2020-05-03 16:50 ` Jens Axboe
2020-05-04 12:39 ` Christoph Hellwig
2020-05-08 8:58 ` [eventfd] a4ef93e263: will-it-scale.per_process_ops -2.2% regression kernel test robot
2020-05-08 8:58 ` kernel test robot
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=20200501231231.GR23230@ZenIV.linux.org.uk \
--to=viro@zeniv.linux.org.uk \
--cc=axboe@kernel.dk \
--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 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.