Re: [PATCH 07/11] virtio: pci: Check virtio configs are mapped

2022-03-25 Thread Bin Meng
On Fri, Mar 25, 2022 at 3:07 PM Andrew Scull wrote: > > On Fri, 25 Mar 2022 at 04:38, Bin Meng wrote: > > > > On Sun, Mar 20, 2022 at 7:42 PM Andrew Scull wrote: > > > > > > The calls to `virtio_pci_map_capability()` return NULL on error. If this > > > happens, later accesses to the pointers wou

Re: [PATCH 07/11] virtio: pci: Check virtio configs are mapped

2022-03-24 Thread Bin Meng
On Sun, Mar 20, 2022 at 7:42 PM Andrew Scull wrote: > > The calls to `virtio_pci_map_capability()` return NULL on error. If this > happens, later accesses to the pointers would be unsafe. Avoid this by > failing if the configs were not successfully mapped. > > Signed-off-by: Andrew Scull > --- >