diff options
Diffstat (limited to 'kexec/arch/ppc/crashdump-powerpc.c')
-rw-r--r-- | kexec/arch/ppc/crashdump-powerpc.c | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/kexec/arch/ppc/crashdump-powerpc.c b/kexec/arch/ppc/crashdump-powerpc.c index 7c9dbff..1bef69b 100644 --- a/kexec/arch/ppc/crashdump-powerpc.c +++ b/kexec/arch/ppc/crashdump-powerpc.c @@ -226,15 +226,15 @@ static int get_crash_memory_ranges(struct memory_range **range, int *ranges) *range = crash_memory_range; *ranges = memory_ranges; -#if DEBUG + int j; - printf("CRASH MEMORY RANGES\n"); + dbgprintf("CRASH MEMORY RANGES\n"); for (j = 0; j < *ranges; j++) { start = crash_memory_range[j].start; end = crash_memory_range[j].end; - fprintf(stderr, "%016Lx-%016Lx\n", start, end); + dbgprintf("%016Lx-%016Lx\n", start, end); } -#endif + return 0; err: @@ -289,9 +289,9 @@ static int add_cmdline_param(char *cmdline, unsigned long long addr, if (cmdlen > (COMMAND_LINE_SIZE - 1)) die("Command line overflow\n"); strcat(cmdline, str); -#if DEBUG - fprintf(stderr, "Command line after adding elfcorehdr: %s\n", cmdline); -#endif + + dbgprintf("Command line after adding elfcorehdr: %s\n", cmdline); + return 0; } @@ -403,10 +403,8 @@ void add_usable_mem_rgns(unsigned long long base, unsigned long long size) usablemem_rgns.ranges[usablemem_rgns.size].start = base; usablemem_rgns.ranges[usablemem_rgns.size++].end = end; -#ifdef DEBUG - fprintf(stderr, "usable memory rgns size:%u base:%llx size:%llx\n", + dbgprintf("usable memory rgns size:%u base:%llx size:%llx\n", usablemem_rgns.size, base, size); -#endif } int is_crashkernel_mem_reserved(void) |