]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
vduse: Use proper spinlock for IRQ injection
authorMaxime Coquelin <maxime.coquelin@redhat.com>
Wed, 5 Jul 2023 11:45:05 +0000 (13:45 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 26 Aug 2023 12:23:30 +0000 (14:23 +0200)
commita5ae5a81bc191d82d27bafff554560f7fd8d8c4d
tree32f79c3ce60fc54a0a86c56679bb4789746a8ce3
parent5b7d5c2dd664eb8b9a06ecbc06e28d39359c422e
vduse: Use proper spinlock for IRQ injection

[ Upstream commit 7ca26efb09a1543fddb29308ea3b63b66cb5d3ee ]

The IRQ injection work used spin_lock_irq() to protect the
scheduling of the softirq, but spin_lock_bh() should be
used.

With spin_lock_irq(), we noticed delay of more than 6
seconds between the time a NAPI polling work is scheduled
and the time it is executed.

Fixes: c8a6153b6c59 ("vduse: Introduce VDUSE - vDPA Device in Userspace")
Cc: xieyongji@bytedance.com
Suggested-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Message-Id: <20230705114505.63274-1-maxime.coquelin@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Reviewed-by: Xie Yongji <xieyongji@bytedance.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/vdpa/vdpa_user/vduse_dev.c