Re: [PATCH RESEND 2/6] MIPS: pfn_valid() is broken on low memory HIGHMEM systems

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 01/05/2011 11:31 PM, Kevin Cernekee wrote:
[...]
diff --git a/arch/mips/mm/init.c b/arch/mips/mm/init.c
index 2efcbd2..18183a4 100644
--- a/arch/mips/mm/init.c
+++ b/arch/mips/mm/init.c
@@ -370,7 +370,7 @@ void __init mem_init(void)
  #ifdef CONFIG_DISCONTIGMEM
  #error "CONFIG_HIGHMEM and CONFIG_DISCONTIGMEM dont work together yet"
  #endif
-	max_mapnr = highend_pfn;
+	max_mapnr = highend_pfn ? : max_low_pfn;

That is not standard C.

How about: max_mapnr = highend_pfn ? highend_pfn : max_low_pfn;

David Daney



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux