Re: [PATCH] virtio-mmio: fix guest kernel crash with SHM regions

2021-01-23 Thread Laurent Vivier
Anyone to merge this? Thanks, Laurent Le 20/12/2020 à 17:35, Laurent Vivier a écrit : > In the kernel, virtio_gpu_init() uses virtio_get_shm_region() > since > commit 6076a9711dc5 ("drm/virtio: implement blob resources: probe for host > visible region") > but vm_get_shm_region() unconditionally

Re: [PATCH] virtio-mmio: fix guest kernel crash with SHM regions

2021-01-08 Thread Stefano Garzarella
On Sun, Dec 20, 2020 at 05:35:39PM +0100, Laurent Vivier wrote: In the kernel, virtio_gpu_init() uses virtio_get_shm_region() since commit 6076a9711dc5 ("drm/virtio: implement blob resources: probe for host visible region") but vm_get_shm_region() unconditionally uses VIRTIO_MMIO_SHM_SEL to get

Re: [PATCH] virtio-mmio: fix guest kernel crash with SHM regions

2021-01-07 Thread Gerd Hoffmann
Hi, > > According to the comments in the kernel, a non existent shared region > > has a length of (u64)-1. virtio spec says the same. > > + case VIRTIO_MMIO_SHM_LEN_LOW: > > + case VIRTIO_MMIO_SHM_LEN_HIGH: > > +/* > > + * VIRTIO_MMIO_SHM_SEL is unimplemented > > +

Re: [PATCH] virtio-mmio: fix guest kernel crash with SHM regions

2021-01-07 Thread Laurent Vivier
Hi, any comment? Thanks, Laurent Le 20/12/2020 à 17:35, Laurent Vivier a écrit : > In the kernel, virtio_gpu_init() uses virtio_get_shm_region() > since > commit 6076a9711dc5 ("drm/virtio: implement blob resources: probe for host > visible region") > but vm_get_shm_region() unconditionally uses

[PATCH] virtio-mmio: fix guest kernel crash with SHM regions

2020-12-20 Thread Laurent Vivier
In the kernel, virtio_gpu_init() uses virtio_get_shm_region() since commit 6076a9711dc5 ("drm/virtio: implement blob resources: probe for host visible region") but vm_get_shm_region() unconditionally uses VIRTIO_MMIO_SHM_SEL to get the address and the length of the region. commit 38e895487afc ("v