mirror of
https://github.com/torvalds/linux.git
synced 2024-11-17 17:41:44 +00:00
0210a8db2a
When the IOTLB device is enabled, the vring addresses we get
from userspace are GIOVAs. It is thus wrong to pass them down
to access_ok() which only takes HVAs.
Access validation is done at prefetch time with IOTLB. Teach
vq_access_ok() about that by moving the (vq->iotlb) check
from vhost_vq_access_ok() to vq_access_ok(). This prevents
vhost_vring_set_addr() to fail when verifying the accesses.
No behavior change for vhost_vq_access_ok().
BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=1883084
Fixes:
|
||
---|---|---|
.. | ||
iotlb.c | ||
Kconfig | ||
Makefile | ||
net.c | ||
scsi.c | ||
test.c | ||
test.h | ||
vdpa.c | ||
vhost.c | ||
vhost.h | ||
vringh.c | ||
vsock.c |