All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] powerpc/powernv/pci: remove dead code from !CONFIG_EEH
@ 2021-04-22 19:54 ` Nick Desaulniers
  0 siblings, 0 replies; 16+ messages in thread
From: Nick Desaulniers @ 2021-04-22 19:54 UTC (permalink / raw)
  To: Michael Ellerman
  Cc: Nick Desaulniers, Nathan Chancellor, Joe Perches,
	Benjamin Herrenschmidt, Paul Mackerras, Oliver O'Halloran,
	Alexey Kardashevskiy, linuxppc-dev, linux-kernel

While looking at -Wundef warnings, the #if CONFIG_EEH stood out as a
possible candidate to convert to #ifdef CONFIG_EEH, but it seems that
based on Kconfig dependencies it's not possible to build this file
without CONFIG_EEH enabled.

Suggested-by: Nathan Chancellor <nathan@kernel.org>
Suggested-by: Joe Perches <joe@perches.com>
Link: https://github.com/ClangBuiltLinux/linux/issues/570
Link: https://lore.kernel.org/lkml/67f6cd269684c9aa8463ff4812c3b4605e6739c3.camel@perches.com/
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
---
 arch/powerpc/platforms/powernv/pci.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/arch/powerpc/platforms/powernv/pci.c b/arch/powerpc/platforms/powernv/pci.c
index 9b9bca169275..591480a37b05 100644
--- a/arch/powerpc/platforms/powernv/pci.c
+++ b/arch/powerpc/platforms/powernv/pci.c
@@ -711,7 +711,6 @@ int pnv_pci_cfg_write(struct pci_dn *pdn,
 	return PCIBIOS_SUCCESSFUL;
 }
 
-#if CONFIG_EEH
 static bool pnv_pci_cfg_check(struct pci_dn *pdn)
 {
 	struct eeh_dev *edev = NULL;
@@ -734,12 +733,6 @@ static bool pnv_pci_cfg_check(struct pci_dn *pdn)
 
 	return true;
 }
-#else
-static inline pnv_pci_cfg_check(struct pci_dn *pdn)
-{
-	return true;
-}
-#endif /* CONFIG_EEH */
 
 static int pnv_pci_read_config(struct pci_bus *bus,
 			       unsigned int devfn,

base-commit: 16fc44d6387e260f4932e9248b985837324705d8
prerequisite-patch-id: 950233069fb22099a8ff8990f620f5c3586a3cbd
-- 
2.31.1.498.g6c1eba8ee3d-goog


^ permalink raw reply related	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2021-06-06 12:18 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-22 19:54 [PATCH] powerpc/powernv/pci: remove dead code from !CONFIG_EEH Nick Desaulniers
2021-04-22 19:54 ` Nick Desaulniers
2021-04-22 23:09 ` Daniel Axtens
2021-04-22 23:09   ` Daniel Axtens
2021-04-23  1:13   ` Oliver O'Halloran
2021-04-23  1:13     ` Oliver O'Halloran
2021-05-18  0:16     ` Nick Desaulniers
2021-05-18  0:16       ` Nick Desaulniers
2021-05-18  6:13       ` Michael Ellerman
2021-05-18  6:13         ` Michael Ellerman
2021-05-18 20:40         ` [PATCH v2] powerpc/powernv/pci: fix header guard Nick Desaulniers
2021-05-18 20:40           ` Nick Desaulniers
2021-05-18 20:41           ` Nathan Chancellor
2021-05-18 20:41             ` Nathan Chancellor
2021-06-06 12:08           ` Michael Ellerman
2021-06-06 12:08             ` Michael Ellerman

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.