diff options
Diffstat (limited to 'arch/mips/kernel/setup.c')
-rw-r--r-- | arch/mips/kernel/setup.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/arch/mips/kernel/setup.c b/arch/mips/kernel/setup.c index faeed5f4cf26..a481be047696 100644 --- a/arch/mips/kernel/setup.c +++ b/arch/mips/kernel/setup.c | |||
@@ -419,17 +419,20 @@ static inline void bootmem_init(void) | |||
419 | #ifdef CONFIG_BLK_DEV_INITRD | 419 | #ifdef CONFIG_BLK_DEV_INITRD |
420 | initrd_below_start_ok = 1; | 420 | initrd_below_start_ok = 1; |
421 | if (initrd_start) { | 421 | if (initrd_start) { |
422 | unsigned long initrd_size = ((unsigned char *)initrd_end) - ((unsigned char *)initrd_start); | 422 | unsigned long initrd_size = ((unsigned char *)initrd_end) - |
423 | ((unsigned char *)initrd_start); | ||
424 | const int width = sizeof(long) * 2; | ||
425 | |||
423 | printk("Initial ramdisk at: 0x%p (%lu bytes)\n", | 426 | printk("Initial ramdisk at: 0x%p (%lu bytes)\n", |
424 | (void *)initrd_start, initrd_size); | 427 | (void *)initrd_start, initrd_size); |
425 | 428 | ||
426 | if (CPHYSADDR(initrd_end) > PFN_PHYS(max_low_pfn)) { | 429 | if (CPHYSADDR(initrd_end) > PFN_PHYS(max_low_pfn)) { |
427 | printk("initrd extends beyond end of memory " | 430 | printk("initrd extends beyond end of memory " |
428 | "(0x%0*Lx > 0x%0*Lx)\ndisabling initrd\n", | 431 | "(0x%0*Lx > 0x%0*Lx)\ndisabling initrd\n", |
429 | sizeof(long) * 2, | 432 | width, |
430 | (unsigned long long)CPHYSADDR(initrd_end), | 433 | (unsigned long long) CPHYSADDR(initrd_end), |
431 | sizeof(long) * 2, | 434 | width, |
432 | (unsigned long long)PFN_PHYS(max_low_pfn)); | 435 | (unsigned long long) PFN_PHYS(max_low_pfn)); |
433 | initrd_start = initrd_end = 0; | 436 | initrd_start = initrd_end = 0; |
434 | initrd_reserve_bootmem = 0; | 437 | initrd_reserve_bootmem = 0; |
435 | } | 438 | } |