<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/io_uring/kbuf.c, branch v6.0</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v6.0</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v6.0'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2022-08-12T23:01:00Z</updated>
<entry>
<title>io_uring: make io_kiocb_to_cmd() typesafe</title>
<updated>2022-08-12T23:01:00Z</updated>
<author>
<name>Stefan Metzmacher</name>
<email>metze@samba.org</email>
</author>
<published>2022-08-11T07:11:15Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=f2ccb5aed7bce1d8b3ed5b3385759a5509663028'/>
<id>urn:sha1:f2ccb5aed7bce1d8b3ed5b3385759a5509663028</id>
<content type='text'>
We need to make sure (at build time) that struct io_cmd_data is not
casted to a structure that's larger.

Signed-off-by: Stefan Metzmacher &lt;metze@samba.org&gt;
Link: https://lore.kernel.org/r/c024cdf25ae19fc0319d4180e2298bade8ed17b8.1660201408.git.metze@samba.org
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring: mem-account pbuf buckets</title>
<updated>2022-08-04T14:35:07Z</updated>
<author>
<name>Pavel Begunkov</name>
<email>asml.silence@gmail.com</email>
</author>
<published>2022-08-04T14:13:46Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=cc18cc5e82033d406f54144ad6f8092206004684'/>
<id>urn:sha1:cc18cc5e82033d406f54144ad6f8092206004684</id>
<content type='text'>
Potentially, someone may create as many pbuf bucket as there are indexes
in an xarray without any other restrictions bounding our memory usage,
put memory needed for the buckets under memory accounting.

Cc: &lt;stable@vger.kernel.org&gt;
Signed-off-by: Pavel Begunkov &lt;asml.silence@gmail.com&gt;
Link: https://lore.kernel.org/r/d34c452e45793e978d26e2606211ec9070d329ea.1659622312.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring: allow 0 length for buffer select</title>
<updated>2022-07-25T00:39:16Z</updated>
<author>
<name>Dylan Yudaken</name>
<email>dylany@fb.com</email>
</author>
<published>2022-06-30T09:12:20Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=b8c015598c8ef9195b8a2a5089e275c4f64ca999'/>
<id>urn:sha1:b8c015598c8ef9195b8a2a5089e275c4f64ca999</id>
<content type='text'>
If user gives 0 for length, we can set it from the available buffer size.

Signed-off-by: Dylan Yudaken &lt;dylany@fb.com&gt;
Link: https://lore.kernel.org/r/20220630091231.1456789-2-dylany@fb.com
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring: kbuf: inline io_kbuf_recycle_ring()</title>
<updated>2022-07-25T00:39:16Z</updated>
<author>
<name>Hao Xu</name>
<email>howeyxu@tencent.com</email>
</author>
<published>2022-06-23T13:01:26Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=795bbbc8a9a1bbbafce762c706bfb5733c9d0426'/>
<id>urn:sha1:795bbbc8a9a1bbbafce762c706bfb5733c9d0426</id>
<content type='text'>
Make io_kbuf_recycle_ring() inline since it is the fast path of
provided buffer.

Signed-off-by: Hao Xu &lt;howeyxu@tencent.com&gt;
Link: https://lore.kernel.org/r/20220623130126.179232-1-hao.xu@linux.dev
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring: kbuf: kill __io_kbuf_recycle()</title>
<updated>2022-07-25T00:39:15Z</updated>
<author>
<name>Hao Xu</name>
<email>howeyxu@tencent.com</email>
</author>
<published>2022-06-22T05:55:51Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=024b8fde3320ea34d7a5a3fc9dbc47ec736cd8eb'/>
<id>urn:sha1:024b8fde3320ea34d7a5a3fc9dbc47ec736cd8eb</id>
<content type='text'>
__io_kbuf_recycle() is only called in io_kbuf_recycle(). Kill it and
tweak the code so that the legacy pbuf and ring pbuf code become clear

Signed-off-by: Hao Xu &lt;howeyxu@tencent.com&gt;
Link: https://lore.kernel.org/r/20220622055551.642370-1-hao.xu@linux.dev
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring: kill extra io_uring_types.h includes</title>
<updated>2022-07-25T00:39:14Z</updated>
<author>
<name>Pavel Begunkov</name>
<email>asml.silence@gmail.com</email>
</author>
<published>2022-06-16T12:57:18Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=27a9d66fec77cff0e32d2ecd5d0ac7ef878a7bb0'/>
<id>urn:sha1:27a9d66fec77cff0e32d2ecd5d0ac7ef878a7bb0</id>
<content type='text'>
io_uring/io_uring.h already includes io_uring_types.h, no need to
include it every time. Kill it in a bunch of places, it prepares us for
following patches.

Signed-off-by: Pavel Begunkov &lt;asml.silence@gmail.com&gt;
Link: https://lore.kernel.org/r/94d8c943fbe0ef949981c508ddcee7fc1c18850f.1655384063.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring: kbuf: add comments for some tricky code</title>
<updated>2022-07-25T00:39:14Z</updated>
<author>
<name>Hao Xu</name>
<email>howeyxu@tencent.com</email>
</author>
<published>2022-06-17T05:04:29Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=f09c8643f0fad0e287b9f737955276000fd76a5d'/>
<id>urn:sha1:f09c8643f0fad0e287b9f737955276000fd76a5d</id>
<content type='text'>
Add comments to explain why it is always under uring lock when
incrementing head in __io_kbuf_recycle. And rectify one comemnt about
kbuf consuming in iowq case.

Signed-off-by: Hao Xu &lt;howeyxu@tencent.com&gt;
Link: https://lore.kernel.org/r/20220617050429.94293-1-hao.xu@linux.dev
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring: don't inline io_put_kbuf</title>
<updated>2022-07-25T00:39:13Z</updated>
<author>
<name>Pavel Begunkov</name>
<email>asml.silence@gmail.com</email>
</author>
<published>2022-06-16T09:22:00Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=53ccf69bda6f51e462f3c4ab7eb9c0ec34e78be4'/>
<id>urn:sha1:53ccf69bda6f51e462f3c4ab7eb9c0ec34e78be4</id>
<content type='text'>
io_put_kbuf() is huge, don't bloat the kernel with inlining.

Signed-off-by: Pavel Begunkov &lt;asml.silence@gmail.com&gt;
Link: https://lore.kernel.org/r/2e21ccf0be471ffa654032914b9430813cae53f8.1655371007.git.asml.silence@gmail.com
Reviewed-by: Hao Xu &lt;howeyxu@tencent.com&gt;
Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
<entry>
<title>io_uring: split provided buffers handling into its own file</title>
<updated>2022-07-25T00:39:12Z</updated>
<author>
<name>Jens Axboe</name>
<email>axboe@kernel.dk</email>
</author>
<published>2022-06-13T13:07:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=3b77495a97239faa27989f946d29b6be7dd091e9'/>
<id>urn:sha1:3b77495a97239faa27989f946d29b6be7dd091e9</id>
<content type='text'>
Move both the opcodes related to it, and the internals code dealing with
it.

Signed-off-by: Jens Axboe &lt;axboe@kernel.dk&gt;
</content>
</entry>
</feed>
