aboutsummaryrefslogtreecommitdiff
path: root/drivers/pci/controller/dwc/pci-meson.c
diff options
context:
space:
mode:
authorJon Hunter <[email protected]>2021-06-18 17:02:19 +0100
committerBjorn Helgaas <[email protected]>2021-06-28 18:26:46 -0500
commitf67092eff2bd40650aad54a1a1910160f41d864a (patch)
tree2191a3078e045f12416f30f3e87ef65938094572 /drivers/pci/controller/dwc/pci-meson.c
parentc4bf1f25c6c187864681d5ad4dd1fa92f62d5d32 (diff)
PCI: tegra194: Fix tegra_pcie_ep_raise_msi_irq() ill-defined shift
tegra_pcie_ep_raise_msi_irq() shifted a signed 32-bit value left by 31 bits. The behavior of this is implementation-defined. Replace the shift by BIT(), which is well-defined. Found by cppcheck: $ cppcheck --enable=all drivers/pci/controller/dwc/pcie-tegra194.c Checking drivers/pci/controller/dwc/pcie-tegra194.c ... drivers/pci/controller/dwc/pcie-tegra194.c:1829:23: portability: Shifting signed 32-bit value by 31 bits is implementation-defined behaviour. See condition at line 1826. [shiftTooManyBitsSigned] appl_writel(pcie, (1 << irq), APPL_MSI_CTRL_1); ^ [bhelgaas: commit log] Link: https://lore.kernel.org/r/[email protected] Fixes: c57247f940e8 ("PCI: tegra: Add support for PCIe endpoint mode in Tegra194") Signed-off-by: Jon Hunter <[email protected]> Signed-off-by: Lorenzo Pieralisi <[email protected]> Signed-off-by: Bjorn Helgaas <[email protected]>
Diffstat (limited to 'drivers/pci/controller/dwc/pci-meson.c')
0 files changed, 0 insertions, 0 deletions