aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/platform/surface/aggregator/ssh_parser.c
diff options
context:
space:
mode:
authorOleksandr Tyshchenko <[email protected]>2022-10-05 17:48:23 +0000
committerJuergen Gross <[email protected]>2022-10-06 06:30:13 +0000
commit77be00f194b6e1647cddb644b7023b352c2c6ee8 (patch)
tree3237742d79ae30d18df367d2d3ce788c528f800c /drivers/platform/surface/aggregator/ssh_parser.c
parentxen/virtio: Fix n_pages calculation in xen_grant_dma_map(unmap)_page() (diff)
downloadkernel-77be00f194b6e1647cddb644b7023b352c2c6ee8.tar.gz
kernel-77be00f194b6e1647cddb644b7023b352c2c6ee8.zip
xen/virtio: Fix potential deadlock when accessing xen_grant_dma_devices
As find_xen_grant_dma_data() is called from both interrupt and process contexts, the access to xen_grant_dma_devices XArray must be protected by xa_lock_irqsave to avoid deadlock scenario. As XArray API doesn't provide xa_store_irqsave helper, call lockless __xa_store directly and guard it externally. Also move the storage of the XArray's entry to a separate helper. Fixes: d6aca3504c7d ("xen/grant-dma-ops: Add option to restrict memory access under Xen") Signed-off-by: Oleksandr Tyshchenko <[email protected]> Reviewed-by: Stefano Stabellini <[email protected]> Reviewed-by: Juergen Gross <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Juergen Gross <[email protected]>
Diffstat (limited to 'drivers/platform/surface/aggregator/ssh_parser.c')
0 files changed, 0 insertions, 0 deletions