<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/drivers/virtio, branch next</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<entry>
<title>Merge tag 'v2026.07-rc3' into next</title>
<updated>2026-05-25T17:35:35+00:00</updated>
<author>
<name>Tom Rini</name>
<email>trini@konsulko.com</email>
</author>
<published>2026-05-25T17:35:35+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=7bb1917b15b77a7d8c27045df33b6bbc214c2f67'/>
<id>7bb1917b15b77a7d8c27045df33b6bbc214c2f67</id>
<content type='text'>
Prepare v2026.07-rc3
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Prepare v2026.07-rc3
</pre>
</div>
</content>
</entry>
<entry>
<title>virtio: blk: Fix converting the vendor id to a string</title>
<updated>2026-05-22T22:47:54+00:00</updated>
<author>
<name>Daniel Palmer</name>
<email>daniel@thingy.jp</email>
</author>
<published>2026-05-16T07:40:00+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=ddba15ab72df5a01fd483a0f4fc40f9ae4d2475c'/>
<id>ddba15ab72df5a01fd483a0f4fc40f9ae4d2475c</id>
<content type='text'>
Currently we are trying to work out if the vendor id is from
a virtio-mmio device and then casting a u32 to a char* and using
it as a C-string. By chance there is usually a zero after the u32
and it works.

Since the vendor id we are trying to convert to a string is QEMU's
just define a value for the QEMU vendor id, check if the vendor
id matches and then use a predefined string for "QEMU".

I don't think we should have been assumming all virtio-mmio vendor
ids are printable ASCII chars in the first place so do this special
casing just for QEMU. If the vendor id isn't QEMU print the hex
value of it.

Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
Reviewed-by: Kuan-Wei Chiu &lt;visitorckw@gmail.com&gt;
Signed-off-by: Daniel Palmer &lt;daniel@thingy.jp&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently we are trying to work out if the vendor id is from
a virtio-mmio device and then casting a u32 to a char* and using
it as a C-string. By chance there is usually a zero after the u32
and it works.

Since the vendor id we are trying to convert to a string is QEMU's
just define a value for the QEMU vendor id, check if the vendor
id matches and then use a predefined string for "QEMU".

I don't think we should have been assumming all virtio-mmio vendor
ids are printable ASCII chars in the first place so do this special
casing just for QEMU. If the vendor id isn't QEMU print the hex
value of it.

Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
Reviewed-by: Kuan-Wei Chiu &lt;visitorckw@gmail.com&gt;
Signed-off-by: Daniel Palmer &lt;daniel@thingy.jp&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>virtio: mmio: Allow instantiation via platform data</title>
<updated>2026-05-22T22:47:54+00:00</updated>
<author>
<name>Daniel Palmer</name>
<email>daniel@thingy.jp</email>
</author>
<published>2026-05-16T07:39:58+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=009cd5b56dbc2d0f7675e4262347a1a6b6a55cb2'/>
<id>009cd5b56dbc2d0f7675e4262347a1a6b6a55cb2</id>
<content type='text'>
The m68k QEMU virt machine doesn't use devicetree, yet, so
allow it to create virtio-mmio instances via platform data.

Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
Reviewed-by: Kuan-Wei Chiu &lt;visitorckw@gmail.com&gt;
Reviewed-by: Angelo Dureghello &lt;angelo@kernel-space.org&gt;
Signed-off-by: Daniel Palmer &lt;daniel@thingy.jp&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The m68k QEMU virt machine doesn't use devicetree, yet, so
allow it to create virtio-mmio instances via platform data.

Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
Reviewed-by: Kuan-Wei Chiu &lt;visitorckw@gmail.com&gt;
Reviewed-by: Angelo Dureghello &lt;angelo@kernel-space.org&gt;
Signed-off-by: Daniel Palmer &lt;daniel@thingy.jp&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>virtio: fix return value check</title>
<updated>2026-05-12T18:38:49+00:00</updated>
<author>
<name>Christian Pötzsch</name>
<email>christian.poetzsch@kernkonzept.com</email>
</author>
<published>2026-05-12T08:39:49+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=36d4c653580824b16574560b21d4401614d8b68e'/>
<id>36d4c653580824b16574560b21d4401614d8b68e</id>
<content type='text'>
The virtio_blk_do_single_req function returns ulong, which normally is
the processed size, but in an error case can be the actual error. Use
the special IS_ERR_VALUE macro to test for error.

Addresses-Coverity-ID: CID 645833 (DEADCODE) &amp; CID 645834 (NO_EFFECT)
Signed-off-by: Christian Pötzsch &lt;christian.poetzsch@kernkonzept.com&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The virtio_blk_do_single_req function returns ulong, which normally is
the processed size, but in an error case can be the actual error. Use
the special IS_ERR_VALUE macro to test for error.

Addresses-Coverity-ID: CID 645833 (DEADCODE) &amp; CID 645834 (NO_EFFECT)
Signed-off-by: Christian Pötzsch &lt;christian.poetzsch@kernkonzept.com&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>virtio: fix boot device hunting in qemu with virtio</title>
<updated>2026-05-08T21:49:27+00:00</updated>
<author>
<name>Ludwig Nussel</name>
<email>ludwig.nussel@siemens.com</email>
</author>
<published>2026-05-04T07:10:23+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=18806dae0e6fa9e0912a258e15f61b1b346dfdbc'/>
<id>18806dae0e6fa9e0912a258e15f61b1b346dfdbc</id>
<content type='text'>
Commit 70101c3217ae ("virtio: mmio: Return error codes on probe
failures") returns -ENODEV where it would return 0 before. That path is
apparently hit in qemu and breaks boot device discovery
(virtio_bootdev_hunt() expects only ENOENT). So return -ENOENT in
that path instead.
The remaining two error returns in the function are untouched as I
don't know where they play a role.

Signed-off-by: Ludwig Nussel &lt;ludwig.nussel@siemens.com&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
Acked-by: Kuan-Wei Chiu &lt;visitorckw@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit 70101c3217ae ("virtio: mmio: Return error codes on probe
failures") returns -ENODEV where it would return 0 before. That path is
apparently hit in qemu and breaks boot device discovery
(virtio_bootdev_hunt() expects only ENOENT). So return -ENOENT in
that path instead.
The remaining two error returns in the function are untouched as I
don't know where they play a role.

Signed-off-by: Ludwig Nussel &lt;ludwig.nussel@siemens.com&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
Acked-by: Kuan-Wei Chiu &lt;visitorckw@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>virtio: add support for SIZE_MAX &amp; SEG_MAX features</title>
<updated>2026-04-27T17:11:54+00:00</updated>
<author>
<name>Christian Pötzsch</name>
<email>christian.poetzsch@kernkonzept.com</email>
</author>
<published>2026-04-17T12:03:19+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=bb4142af7ed8c94b3df3e75ca9ab3ef450e80885'/>
<id>bb4142af7ed8c94b3df3e75ca9ab3ef450e80885</id>
<content type='text'>
Some virtio implementations may forward the virtio requests directly to
the underlying hw. The hw may have some restrictions in how many and how
big the requests can be. Therefore, the corresponding virtio device will
announce this limitations with the SIZE_MAX &amp; SEG_MAX feature.

Add support for those features. Split an io request into multiple virtio
requests if more than seg_max segments would be used. Also split a
single buffer request into multiple segments if the buffer is bigger
then size_max.

Signed-off-by: Christian Pötzsch &lt;christian.poetzsch@kernkonzept.com&gt;
Signed-off-by: Adam Lackorzynski &lt;adam@l4re.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Some virtio implementations may forward the virtio requests directly to
the underlying hw. The hw may have some restrictions in how many and how
big the requests can be. Therefore, the corresponding virtio device will
announce this limitations with the SIZE_MAX &amp; SEG_MAX feature.

Add support for those features. Split an io request into multiple virtio
requests if more than seg_max segments would be used. Also split a
single buffer request into multiple segments if the buffer is bigger
then size_max.

Signed-off-by: Christian Pötzsch &lt;christian.poetzsch@kernkonzept.com&gt;
Signed-off-by: Adam Lackorzynski &lt;adam@l4re.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>virtio: mmio: Return error codes on probe failures</title>
<updated>2026-04-22T17:07:55+00:00</updated>
<author>
<name>Kuan-Wei Chiu</name>
<email>visitorckw@gmail.com</email>
</author>
<published>2026-04-07T09:49:00+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=70101c3217aec849d509040554ef0cf7c0f1ef56'/>
<id>70101c3217aec849d509040554ef0cf7c0f1ef56</id>
<content type='text'>
Currently, virtio_mmio_probe() returns 0 when it encounters an invalid
magic value, an unsupported version, or a dummy device (ID 0). In
U-Boot's driver model, returning 0 indicates a successful probe. This
causes the system to incorrectly register and activate invalid or
placeholder devices, potentially leading to undefined behavior or
crashes later on.

Update the probe function to return appropriate error codes (-ENODEV
for invalid magic values and dummy devices, and -ENXIO for unsupported
versions). This fix correctly instructs the DM to abort the binding
process.

Fixes: fdc4aca89ecb ("virtio: Add virtio over mmio transport driver")
Signed-off-by: Kuan-Wei Chiu &lt;visitorckw@gmail.com&gt;
Acked-by: Daniel Palmer &lt;daniel@thingy.jp&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently, virtio_mmio_probe() returns 0 when it encounters an invalid
magic value, an unsupported version, or a dummy device (ID 0). In
U-Boot's driver model, returning 0 indicates a successful probe. This
causes the system to incorrectly register and activate invalid or
placeholder devices, potentially leading to undefined behavior or
crashes later on.

Update the probe function to return appropriate error codes (-ENODEV
for invalid magic values and dummy devices, and -ENXIO for unsupported
versions). This fix correctly instructs the DM to abort the binding
process.

Fixes: fdc4aca89ecb ("virtio: Add virtio over mmio transport driver")
Signed-off-by: Kuan-Wei Chiu &lt;visitorckw@gmail.com&gt;
Acked-by: Daniel Palmer &lt;daniel@thingy.jp&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>virtio: Fix virtio initialization sequence</title>
<updated>2026-03-25T20:33:00+00:00</updated>
<author>
<name>Christian Pötzsch</name>
<email>christian.poetzsch@kernkonzept.com</email>
</author>
<published>2026-03-10T14:16:42+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=30e1733297ac7d9703bd0950bd237648dcb41850'/>
<id>30e1733297ac7d9703bd0950bd237648dcb41850</id>
<content type='text'>
The virtio spec clearly states in "3.1.1 Driver Requirements: Device
Initialization" the sequence a client has to follow after device reset.
Because u-boot resets here again, it also needs to set the "acknowledge"
bit again even if this was done in virtio_uclass_child_post_bind already
once before.

Signed-off-by: Christian Pötzsch &lt;christian.poetzsch@kernkonzept.com&gt;
Signed-off-by: Adam Lackorzynski &lt;adam@l4re.org&gt;
[trini: Add VIRTIO_CONFIG_S_ACKNOWLEDGE flag check to the test]
Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The virtio spec clearly states in "3.1.1 Driver Requirements: Device
Initialization" the sequence a client has to follow after device reset.
Because u-boot resets here again, it also needs to set the "acknowledge"
bit again even if this was done in virtio_uclass_child_post_bind already
once before.

Signed-off-by: Christian Pötzsch &lt;christian.poetzsch@kernkonzept.com&gt;
Signed-off-by: Adam Lackorzynski &lt;adam@l4re.org&gt;
[trini: Add VIRTIO_CONFIG_S_ACKNOWLEDGE flag check to the test]
Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>virtio: rng: Handle oversized return buffers</title>
<updated>2026-03-25T20:32:38+00:00</updated>
<author>
<name>Kavin Gunasekara</name>
<email>kavin.gunasekara@arm.com</email>
</author>
<published>2026-03-09T16:55:05+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=e0eef12a1f46bf946e24050a1da0f067c3952b89'/>
<id>e0eef12a1f46bf946e24050a1da0f067c3952b89</id>
<content type='text'>
If extra random bytes are returned, truncate and use the requested number
instead of returning an error.

Signed-off-by: Kavin Gunasekara &lt;kavin.gunasekara@arm.com&gt;
Signed-off-by: Meet Patel &lt;meet.patel2@arm.com&gt;
Reviewed-by: Andre Przywara &lt;andre.przywara@arm.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If extra random bytes are returned, truncate and use the requested number
instead of returning an error.

Signed-off-by: Kavin Gunasekara &lt;kavin.gunasekara@arm.com&gt;
Signed-off-by: Meet Patel &lt;meet.patel2@arm.com&gt;
Reviewed-by: Andre Przywara &lt;andre.przywara@arm.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>virtio: typo 'private date'</title>
<updated>2025-11-07T21:34:22+00:00</updated>
<author>
<name>Heinrich Schuchardt</name>
<email>heinrich.schuchardt@canonical.com</email>
</author>
<published>2025-11-04T23:42:31+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=6978d6ae5964c79bd25e0754a65141906e823cca'/>
<id>6978d6ae5964c79bd25e0754a65141906e823cca</id>
<content type='text'>
%s/private date/private data/

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
Reviewed-by: Bin Meng &lt;bmeng.cn@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
%s/private date/private data/

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
Reviewed-by: Bin Meng &lt;bmeng.cn@gmail.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
