> The misaligned I/O fallback copies the full bounce scatterlist to the
> request buffer during completion. If a data-in command transfers less
> than requested, part of a newly allocated bounce page can remain unwritten.
>
> Allocate bounce pages with __GFP_ZERO so all bytes copied during completion
> have a defined value. This path is already the slow fallback for
> misaligned I/O, so the added initialization cost is acceptable.
>
> Found during an LLM-assisted source audit and validated with a QEMU/KVM
> vhost-scsi target using misaligned data-in commands.
>
> Fixes: 5ced58bfa132 ("vhost-scsi: Fix alignment handling with windows")
> Cc: [email protected]
> Assisted-by: LLM (OpenAI Codex, gpt-5.6-sol)
> Signed-off-by: Shubham Antil <[email protected]>
Sashiko has reviewed this patch and found no issues.
--
Sashiko AI review ยท
https://sashiko.dev/#/patchset/[email protected]?part=1