Commit 292121dc authored by Felix Fietkau's avatar Felix Fietkau Committed by John W. Linville

ath9k: remove a bogus WARN_ON

On embedded hardware it's normal to not have a PCI device for the PCI
bridge that the wifi card is attached to. pdev->bus->self will be
NULL in that case. In that case, simply return without emitting an
useless kernel stack trace.
Signed-off-by: default avatarFelix Fietkau <nbd@openwrt.org>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent d069a46b
...@@ -126,7 +126,7 @@ static void ath_pci_aspm_init(struct ath_common *common) ...@@ -126,7 +126,7 @@ static void ath_pci_aspm_init(struct ath_common *common)
* Both upstream and downstream PCIe components should * Both upstream and downstream PCIe components should
* have the same ASPM settings. * have the same ASPM settings.
*/ */
if (WARN_ON(!parent)) if (!parent)
return; return;
pos = pci_pcie_cap(parent); pos = pci_pcie_cap(parent);
...@@ -137,7 +137,7 @@ static void ath_pci_aspm_init(struct ath_common *common) ...@@ -137,7 +137,7 @@ static void ath_pci_aspm_init(struct ath_common *common)
return; return;
} }
if (WARN_ON(!parent)) if (!parent)
return; return;
pos = pci_pcie_cap(parent); pos = pci_pcie_cap(parent);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment