mirror of
https://xff.cz/git/u-boot/
synced 2025-09-03 09:42:22 +02:00
virtio_ring: Check used descriptors are chain heads
When the device returns used buffers, it should refer to the descriptor that is the head of the descriptor chain for that buffer. Confirm this to be the case by tracking the head of descriptor chains that have been made available to the device. Signed-off-by: Andrew Scull <ascull@google.com> Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -61,6 +61,8 @@ struct vring_desc_shadow {
|
||||
u32 len;
|
||||
u16 flags;
|
||||
u16 next;
|
||||
/* Metadata about the descriptor. */
|
||||
bool chain_head;
|
||||
};
|
||||
|
||||
struct vring_avail {
|
||||
|
Reference in New Issue
Block a user