linux-uconsole/drivers/pci/controller/dwc
Niklas Cassel 186d51d4fa PCI: dwc: Fix find_next_bit() usage
commit 1137e61dcb upstream.

find_next_bit() takes a parameter of size long, and performs arithmetic
that assumes that the argument is of size long.

Therefore we cannot pass a u32, since this will cause find_next_bit()
to read outside the stack buffer and will produce the following print:
BUG: KASAN: stack-out-of-bounds in find_next_bit+0x38/0xb0

Fixes: 1b497e6493 ("PCI: dwc: Fix uninitialized variable in dw_handle_msi_irq()")
Tested-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Niklas Cassel <niklas.cassel@linaro.org>
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Reviewed-by: Andrew Murray <andrew.murray@arm.com>
Acked-by: Gustavo Pimentel <gustavo.pimentel@synopsys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-01-17 19:47:08 +01:00
..
Kconfig
Makefile
pci-dra7xx.c PCI: dwc: pci-dra7xx: Fix compilation when !CONFIG_GPIOLIB 2019-07-31 07:27:07 +02:00
pci-exynos.c PCI: exynos: Propagate errors for optional PHYs 2019-10-07 18:57:13 +02:00
pci-imx6.c PCI: imx6: Propagate errors for optional regulators 2019-10-07 18:57:13 +02:00
pci-keystone-dw.c
pci-keystone.c PCI: keystone: Use quirk to limit MRRS for K2G 2019-12-01 09:17:33 +01:00
pci-keystone.h
pci-layerscape.c PCI: layerscape: Fix wrong invocation of outbound window disable accessor 2018-12-05 19:32:07 +01:00
pcie-armada8k.c PCI: armada8k: Drop unnecessary root_bus_nr setting 2018-07-13 14:08:28 +01:00
pcie-artpec6.c PCI: Update xxx_pcie_ep_raise_irq() and pci_epc_raise_irq() signatures 2018-07-19 11:34:42 +01:00
pcie-designware-ep.c PCI: designware-ep: Use aligned ATU window for raising MSI interrupts 2019-06-15 11:54:06 +02:00
pcie-designware-host.c PCI: dwc: Fix find_next_bit() usage 2020-01-17 19:47:08 +01:00
pcie-designware-plat.c pci-epf-test/pci_endpoint_test: Add MSI-X support 2018-07-19 11:46:45 +01:00
pcie-designware.c PCI: dwc: Fix scheduling while atomic issues 2018-09-20 16:36:20 -05:00
pcie-designware.h PCI: dwc: Free MSI IRQ page in dw_pcie_free_msi() 2019-06-15 11:54:05 +02:00
pcie-hisi.c
pcie-histb.c PCI: histb: Propagate errors for optional regulators 2019-10-07 18:57:13 +02:00
pcie-kirin.c PCI: kirin: Fix section mismatch warning 2019-09-21 07:17:14 +02:00
pcie-qcom.c PCI: qcom: Don't deassert reset GPIO during probe 2019-09-16 08:22:08 +02:00
pcie-spear13xx.c PCI: spear13xx: Drop unnecessary root_bus_nr setting 2018-07-13 14:10:55 +01:00