<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/io_uring/eventfd.c, branch v6.19.11</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.19.11</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.19.11'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2026-03-19T15:15:33+00:00</updated>
<entry>
<title>io_uring/eventfd: use ctx-&gt;rings_rcu for flags checking</title>
<updated>2026-03-19T15:15:33+00:00</updated>
<author>
<name>Jens Axboe</name>
<email>axboe@kernel.dk</email>
</author>
<published>2026-03-09T20:35:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=4dab7000edcc6cc694bf388e8de9b896198b9c85'/>
<id>urn:sha1:4dab7000edcc6cc694bf388e8de9b896198b9c85</id>
<content type='text'>
Commit 177c69432161f6e4bab07ccacf8a1748a6898a6b upstream.

Similarly to what commit e78f7b70e837 did for local task work additions,
use -&gt;rings_rcu under RCU rather than dereference -&gt;rings directly. See
that commit for more details.

Cc: stable@vger.kernel.org
Fixes: 79cfe9e59c2a ("io_uring/register: add IORING_REGISTER_RESIZE_RINGS")
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>io_uring/eventfd: open code io_eventfd_grab()</title>
<updated>2025-04-24T14:33:54+00:00</updated>
<author>
<name>Pavel Begunkov</name>
<email>asml.silence@gmail.com</email>
</author>
<published>2025-04-24T11:31:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f6da4fee69860d4a02d14b016021ffb516a25f38'/>
<id>urn:sha1:f6da4fee69860d4a02d14b016021ffb516a25f38</id>
<content type='text'>
io_eventfd_grab() doesn't help wit understanding the path, it'll be
simpler to keep the helper open coded.

Signed-off-by: Pavel Begunkov &lt;asml.silence@gmail.com&gt;
Link: https://lore.kernel.org/r/5cb53ce3876c2819db9e8055cf41dca4398521db.1745493845.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring/eventfd: clean up rcu locking</title>
<updated>2025-04-24T14:33:54+00:00</updated>
<author>
<name>Pavel Begunkov</name>
<email>asml.silence@gmail.com</email>
</author>
<published>2025-04-24T11:31:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=da01f60f8ad144a8a0844833a8d0f0005b0a7c51'/>
<id>urn:sha1:da01f60f8ad144a8a0844833a8d0f0005b0a7c51</id>
<content type='text'>
Conditional locking is never welcome if there are better options. Move
rcu locking into io_eventfd_signal(), make it unconditional and use
guards. It also helps with sparse warnings.

Signed-off-by: Pavel Begunkov &lt;asml.silence@gmail.com&gt;
Link: https://lore.kernel.org/r/91a925e708ca8a5aa7fee61f96d29b24ea9adeaf.1745493845.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring/eventfd: dedup signalling helpers</title>
<updated>2025-04-24T14:33:54+00:00</updated>
<author>
<name>Pavel Begunkov</name>
<email>asml.silence@gmail.com</email>
</author>
<published>2025-04-24T11:31:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=62f666df765ecaf9cc1892ca056d5c071a335d85'/>
<id>urn:sha1:62f666df765ecaf9cc1892ca056d5c071a335d85</id>
<content type='text'>
Consolidate io_eventfd_flush_signal() and io_eventfd_signal(). Not much
of a difference for now, but it prepares it for following changes.

Signed-off-by: Pavel Begunkov &lt;asml.silence@gmail.com&gt;
Link: https://lore.kernel.org/r/5beecd4da65d8d2d83df499196f84b329387f6a2.1745493845.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring/eventfd: ensure io_eventfd_signal() defers another RCU period</title>
<updated>2025-01-09T14:16:45+00:00</updated>
<author>
<name>Jens Axboe</name>
<email>axboe@kernel.dk</email>
</author>
<published>2025-01-08T17:28:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=c9a40292a44e78f71258b8522655bffaf5753bdb'/>
<id>urn:sha1:c9a40292a44e78f71258b8522655bffaf5753bdb</id>
<content type='text'>
io_eventfd_do_signal() is invoked from an RCU callback, but when
dropping the reference to the io_ev_fd, it calls io_eventfd_free()
directly if the refcount drops to zero. This isn't correct, as any
potential freeing of the io_ev_fd should be deferred another RCU grace
period.

Just call io_eventfd_put() rather than open-code the dec-and-test and
free, which will correctly defer it another RCU grace period.

Fixes: 21a091b970cd ("io_uring: signal registered eventfd to process deferred task work")
Reported-by: Jann Horn &lt;jannh@google.com&gt;
Cc: stable@vger.kernel.org
Tested-by: Li Zetao &lt;lizetao1@huawei.com&gt;
Reviewed-by: Li Zetao&lt;lizetao1@huawei.com&gt;
Reviewed-by: Prasanna Kumar T S M &lt;ptsm@linux.microsoft.com&gt;
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring/eventfd: move ctx-&gt;evfd_last_cq_tail into io_ev_fd</title>
<updated>2024-10-29T19:43:26+00:00</updated>
<author>
<name>Jens Axboe</name>
<email>axboe@kernel.dk</email>
</author>
<published>2024-09-21T07:59:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f4bb2f65bb8154c1a2c2d7e01db0c98dffb5918f'/>
<id>urn:sha1:f4bb2f65bb8154c1a2c2d7e01db0c98dffb5918f</id>
<content type='text'>
Everything else about the io_uring eventfd support is nicely kept
private to that code, except the cached_cq_tail tracking. With
everything else in place, move io_eventfd_flush_signal() to using
the ev_fd grab+release helpers, which then enables the direct use of
io_ev_fd for this tracking too.

Link: https://lore.kernel.org/r/20240921080307.185186-7-axboe@kernel.dk
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring/eventfd: abstract out ev_fd grab + release helpers</title>
<updated>2024-10-29T19:43:26+00:00</updated>
<author>
<name>Jens Axboe</name>
<email>axboe@kernel.dk</email>
</author>
<published>2024-09-21T07:59:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=83a4f865e273b83426eafdd3aa51334cc21ac0fd'/>
<id>urn:sha1:83a4f865e273b83426eafdd3aa51334cc21ac0fd</id>
<content type='text'>
In preparation for needing the ev_fd grabbing (and releasing) from
another path, abstract out two helpers for that.

Link: https://lore.kernel.org/r/20240921080307.185186-6-axboe@kernel.dk
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring/eventfd: move trigger check into a helper</title>
<updated>2024-10-29T19:43:26+00:00</updated>
<author>
<name>Jens Axboe</name>
<email>axboe@kernel.dk</email>
</author>
<published>2024-09-21T07:59:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3ca5a356041438534ecbb74159df91736238c6b1'/>
<id>urn:sha1:3ca5a356041438534ecbb74159df91736238c6b1</id>
<content type='text'>
It's a bit hard to read what guards the triggering, move it into a
helper and add a comment explaining it too. This additionally moves
the ev_fd == NULL check in there as well.

Link: https://lore.kernel.org/r/20240921080307.185186-5-axboe@kernel.dk
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring/eventfd: move actual signaling part into separate helper</title>
<updated>2024-10-29T19:43:26+00:00</updated>
<author>
<name>Jens Axboe</name>
<email>axboe@kernel.dk</email>
</author>
<published>2024-09-21T07:59:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=60c5f15800f21883615689e2423217a9c8a1b502'/>
<id>urn:sha1:60c5f15800f21883615689e2423217a9c8a1b502</id>
<content type='text'>
In preparation for using this from multiple spots, move the signaling
into a helper.

Link: https://lore.kernel.org/r/20240921080307.185186-4-axboe@kernel.dk
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring/eventfd: check for the need to async notifier earlier</title>
<updated>2024-10-29T19:43:26+00:00</updated>
<author>
<name>Jens Axboe</name>
<email>axboe@kernel.dk</email>
</author>
<published>2024-09-21T07:59:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3c90b80df5b574c2c61626fd40fa3b23be21fa26'/>
<id>urn:sha1:3c90b80df5b574c2c61626fd40fa3b23be21fa26</id>
<content type='text'>
It's not necessary to do this post grabbing a reference. With that, we
can drop the out goto path as well.

Link: https://lore.kernel.org/r/20240921080307.185186-3-axboe@kernel.dk
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
</feed>
