xen/scsiback: don't call scsiback_free_translation_entry() under lock
authorJuergen Gross <jgross@suse.com>
Tue, 28 Mar 2023 08:46:02 +0000 (10:46 +0200)
committerJuergen Gross <jgross@suse.com>
Mon, 24 Apr 2023 05:27:10 +0000 (07:27 +0200)
commitb2c042cc802fe96d431821bf1cf2f0f04a3eda7d
treeff10d4244ab77b74b3d4b56003a9e84202a550b0
parentfae65ef3a148079103ae935107c62f7830ab52c5
xen/scsiback: don't call scsiback_free_translation_entry() under lock

scsiback_free_translation_entry() shouldn't be called under spinlock,
as it can sleep.

This requires to split removing a translation entry from the v2p list
from actually calling kref_put() for the entry.

Reported-by: Dan Carpenter <error27@gmail.com>
Link: https://lore.kernel.org/lkml/Y+JUIl64UDmdkboh@kadam/
Signed-off-by: Juergen Gross <jgross@suse.com>
Reviewed-by: Oleksandr Tyshchenko <oleksandr_tyshchenko@epam.com>
Link: https://lore.kernel.org/r/20230328084602.20729-1-jgross@suse.com
Signed-off-by: Juergen Gross <jgross@suse.com>
drivers/xen/xen-scsiback.c