mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-06-24 06:29:19 +00:00
dm: NULL check of vq->used in virtio_net_ping_rxq
Add a check on this place to avoid NULL access issue. Tracked-On: #6100 Signed-off-by: Jie Deng <jie.deng@intel.com>
This commit is contained in:
parent
e5f0e2e4f8
commit
2e08f32e7a
@ -476,7 +476,9 @@ virtio_net_ping_rxq(void *vdev, struct virtio_vq_info *vq)
|
||||
*/
|
||||
if (net->rx_ready == 0) {
|
||||
net->rx_ready = 1;
|
||||
vq->used->flags |= VRING_USED_F_NO_NOTIFY;
|
||||
if (vq->used != NULL) {
|
||||
vq->used->flags |= VRING_USED_F_NO_NOTIFY;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user