PCI: Check for platform_get_irq() failure consistently
Get series with b4
b4 am [email protected]Versions newest first
- v2 Latest2 patches 7 repliesIn review
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | driver core: platform: Clarify that IRQ 0 is invaliddrivers/ | +25 | 5 replies | |
| 2/2 | PCI: Check for platform_get_irq() failure consistentlydrivers/ drivers/ drivers/ +4 more | +16 | 0 replies |
Reviews trailers per patch
1 of 2 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Greg Kroah-Hartman | Linus Walleij |
|---|---|---|
| Series | A-b | |
| 1/2 | A-b | |
| 2/2 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v2 0/2] PCI: Check for platform_get_irq() failure consistently
From: Bjorn Helgaas <[email protected]>
All callers of platform_get_irq() and related functions interpret a negative return value as an error. A few also interpret zero as an error.
platform_get_irq() should return either a negative error number or a valid non-zero IRQ, so there's no need to check for zero.
This series:
- Extends the platform_get_irq() function comment to say it returns a non-zero IRQ number or a negative error number.
- Adds a WARN() if platform_get_irq() ever *does* return zero (this would be a bug in the underlying arch code, and most callers are not prepared for this).
- Updates drivers/pci/ to check consistently using "irq < 0".
This is based on Aman's series [1]. I propose to merge this via the PCI tree, given acks from Greg and Thomas.
[1] https://lore.kernel.org/r/[email protected]
Aman Sharma (1):
PCI: Check for platform_get_irq() failure consistently
Bjorn Helgaas (1):
driver core: platform: Clarify that IRQ 0 is invalid
drivers/base/platform.c | 40 ++++++++++++------- drivers/pci/controller/dwc/pci-imx6.c | 4 +- drivers/pci/controller/dwc/pcie-tegra194.c | 4 +- .../controller/mobiveil/pcie-mobiveil-host.c | 4 +- drivers/pci/controller/pci-aardvark.c | 3 ++ drivers/pci/controller/pci-v3-semi.c | 4 +- drivers/pci/controller/pcie-mediatek.c | 3 ++ drivers/pci/controller/pcie-tango.c | 4 +- 8 files changed, 41 insertions(+), 25 deletions(-)
base-commit: 8f3d9f354286745c751374f5f1fcafee6b3f3136
Signature · 1 line
2.25.1