diff options
author | Mohsin Kazmi <sykazmi@cisco.com> | 2022-10-20 12:53:28 +0000 |
---|---|---|
committer | Beno�t Ganne <bganne@cisco.com> | 2022-10-20 14:05:43 +0000 |
commit | 049dee954f6acfc21c15a1a2926f6fb36d58a3e1 (patch) | |
tree | 9c520474008a1131415260a6d3f292856e67960f /src | |
parent | f0d71c6b7feb0c6a3ba99f90588dbc6c5c62163f (diff) |
virtio: fix the missing unlock
Type: fix
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I7003162ee72c39c44be1e7ff0d27f4416b3eca5a
Diffstat (limited to 'src')
-rw-r--r-- | src/vnet/devices/virtio/virtio_pre_input.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/vnet/devices/virtio/virtio_pre_input.c b/src/vnet/devices/virtio/virtio_pre_input.c index eb208fd3a39..80cc8d6edb0 100644 --- a/src/vnet/devices/virtio/virtio_pre_input.c +++ b/src/vnet/devices/virtio/virtio_pre_input.c @@ -31,7 +31,7 @@ virtio_pre_input_inline (vlib_main_t *vm, vnet_virtio_vring_t *txq_vring, if (clib_spinlock_trylock (&txq_vring->lockp)) { if (virtio_txq_is_scheduled (txq_vring)) - return 0; + goto unlock; if (packet_coalesce) vnet_gro_flow_table_schedule_node_on_dispatcher ( vm, txq, txq_vring->flow_table); @@ -39,6 +39,7 @@ virtio_pre_input_inline (vlib_main_t *vm, vnet_virtio_vring_t *txq_vring, virtio_vring_buffering_schedule_node_on_dispatcher ( vm, txq, txq_vring->buffering); virtio_txq_set_scheduled (txq_vring); + unlock: clib_spinlock_unlock (&txq_vring->lockp); } } |