mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
virtio-devices: balloon: Report used length of 0 for inflate/deflate
The inflate and deflate queues carry device-readable PFN arrays: the driver writes them and the device only reads. The device never writes to the descriptor buffers, so the used ring entry should report 0 bytes written rather than the descriptor length. Signed-off-by: Rob Bradford <rbradford@meta.com> Assisted-by: Claude:claude-opus-4-6
This commit is contained in:
@@ -322,7 +322,7 @@ impl BalloonEpollHandler {
|
||||
}
|
||||
|
||||
self.queues[queue_index]
|
||||
.add_used(desc_chain.memory(), desc_chain.head_index(), desc.len())
|
||||
.add_used(desc_chain.memory(), desc_chain.head_index(), 0)
|
||||
.map_err(Error::QueueAddUsed)?;
|
||||
used_descs = true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user