aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/controller/dwc/pcie-tegra194.c
diff options
context:
space:
mode:
authorMiklos Szeredi <mszeredi@redhat.com>2021-08-04 13:22:58 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-09-22 12:28:00 +0200
commitb7d4f310bb8f605cff7c4c70014a9e2b866625c4 (patch)
tree527a68dd27a3edd7badc61ea83dd7306132e130f /drivers/pci/controller/dwc/pcie-tegra194.c
parent03cc3a2923d62f847d148f545c711f73f79617f0 (diff)
downloadkernel_replicant_linux-b7d4f310bb8f605cff7c4c70014a9e2b866625c4.tar.gz
kernel_replicant_linux-b7d4f310bb8f605cff7c4c70014a9e2b866625c4.tar.bz2
kernel_replicant_linux-b7d4f310bb8f605cff7c4c70014a9e2b866625c4.zip
fuse: fix use after free in fuse_read_interrupt()
[ Upstream commit e1e71c168813564be0f6ea3d6740a059ca42d177 ] There is a potential race between fuse_read_interrupt() and fuse_request_end(). TASK1 in fuse_read_interrupt(): delete req->intr_entry (while holding fiq->lock) TASK2 in fuse_request_end(): req->intr_entry is empty -> skip fiq->lock wake up TASK3 TASK3 request is freed TASK1 in fuse_read_interrupt(): dereference req->in.h.unique ***BAM*** Fix by always grabbing fiq->lock if the request was ever interrupted (FR_INTERRUPTED set) thereby serializing with concurrent fuse_read_interrupt() calls. FR_INTERRUPTED is set before the request is queued on fiq->interrupts. Dequeing the request is done with list_del_init() but FR_INTERRUPTED is not cleared in this case. Reported-by: lijiazi <lijiazi@xiaomi.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/pci/controller/dwc/pcie-tegra194.c')
0 files changed, 0 insertions, 0 deletions