powerpc/eeh: Fix build with STACKTRACE=n
The build breaks when STACKTRACE=n, eg. skiroot_defconfig:
arch/powerpc/kernel/eeh_event.c:124:23: error: implicit declaration of function 'stack_trace_save'
Fix it with some ifdefs for now.
Fixes: 25baf3d816
("powerpc/eeh: Defer printing stack trace")
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
This commit is contained in:
@@ -117,12 +117,14 @@ int __eeh_send_failure_event(struct eeh_pe *pe)
|
||||
* while the PE is sitting in the event queue.
|
||||
*/
|
||||
if (pe) {
|
||||
#ifdef CONFIG_STACKTRACE
|
||||
/*
|
||||
* Save the current stack trace so we can dump it from the
|
||||
* event handler thread.
|
||||
*/
|
||||
pe->trace_entries = stack_trace_save(pe->stack_trace,
|
||||
ARRAY_SIZE(pe->stack_trace), 0);
|
||||
#endif /* CONFIG_STACKTRACE */
|
||||
|
||||
eeh_pe_state_mark(pe, EEH_PE_RECOVERING);
|
||||
}
|
||||
|
Reference in New Issue
Block a user