Skip to contentSkip to conversation

powerpc/eeh: Fix build failure with CONFIG_PROC_FS=n

PATCH Applied Michael Ellerman 2 participants 2 messages Mar 14, 2021 – Mar 31, 2021

Subsystems (2)
lore
Share & tools
lore

Michael Ellerman

author reviewer
#0 lore raw

PATCH 1/1 powerpc/eeh: Fix build failure with CONFIG_PROC_FS=n

The build fails with CONFIG_PROC_FS=n:

arch/powerpc/kernel/eeh.c:1571:12: error: ‘proc_eeh_show’ defined but not used
1571 | static int proc_eeh_show(struct seq_file *m, void *v)

Wrap proc_eeh_show() in an ifdef to avoid it.

---
 arch/powerpc/kernel/eeh.c | 2 ++
 1 file changed, 2 insertions(+)
arch/powerpc/kernel/eeh.c +2 -0
index cd60bc1c8701..01dbb44a0fe3 100644
@@ -1568,6 +1568,7 @@ int eeh_pe_inject_err(struct eeh_pe *pe, int type, int func,
 }
 EXPORT_SYMBOL_GPL(eeh_pe_inject_err);
 
+#ifdef CONFIG_PROC_FS
 static int proc_eeh_show(struct seq_file *m, void *v)
 {
 	if (!eeh_enabled()) {
@@ -1594,6 +1595,7 @@ static int proc_eeh_show(struct seq_file *m, void *v)
 
 	return 0;
 }
+#endif /* CONFIG_PROC_FS */
 
 #ifdef CONFIG_DEBUG_FS
 
Signature · 1 line
2.25.1