vduse: Fix race condition between resetting and irq injecting
authorXie Yongji <xieyongji@bytedance.com>
Wed, 29 Sep 2021 08:30:50 +0000 (16:30 +0800)
committerMichael S. Tsirkin <mst@redhat.com>
Fri, 22 Oct 2021 10:49:14 +0000 (06:49 -0400)
commit0943aacf5ae10471b68a702c022b42c89e91ba9e
tree4c49b7212b76402000db34aab1f296225fabd604
parent1394103fd72ce9c67d20f882a93d59403c8da057
vduse: Fix race condition between resetting and irq injecting

The interrupt might be triggered after a reset since there is
no synchronization between resetting and irq injecting. And it
might break something if the interrupt is delayed until a new
round of device initialization.

Fixes: c8a6153b6c59 ("vduse: Introduce VDUSE - vDPA Device in Userspace")
Signed-off-by: Xie Yongji <xieyongji@bytedance.com>
Link: https://lore.kernel.org/r/20210929083050.88-1-xieyongji@bytedance.com
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
drivers/vdpa/vdpa_user/vduse_dev.c