mirror of
https://github.com/torvalds/linux.git
synced 2026-11-27 08:52:27 +00:00
When using a virtio transport, the 9p net device may pass the physical address of a kernel buffer to userspace via a scatterlist inside a virtqueue. If the kernel buffer is mapped outside of the linear mapping (e.g. highmem), then virt_to_page will return a bogus value and we will populate the scatterlist with junk. This patch uses kmap_to_page when populating the page array for a kernel buffer. Cc: [email protected] Cc: Sasha Levin <[email protected]> Signed-off-by: Will Deacon <[email protected]> Signed-off-by: Rusty Russell <[email protected]>