[PATCH] mm: Use macro to switch between section and pfn

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

 



Use macro section_nr_to_pfn and pfn_to_section_nr to switch between section
and pfn, instead of bit operations, no semantic changes.

Signed-off-by: Sheng Yong <shengyong1@xxxxxxxxxx>
---
 arch/ia64/mm/numa.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/ia64/mm/numa.c b/arch/ia64/mm/numa.c
index ea21d4c..40287c7 100644
--- a/arch/ia64/mm/numa.c
+++ b/arch/ia64/mm/numa.c
@@ -60,7 +60,7 @@ paddr_to_nid(unsigned long paddr)
  */
 int __meminit __early_pfn_to_nid(unsigned long pfn)
 {
-	int i, section = pfn >> PFN_SECTION_SHIFT, ssec, esec;
+	int i, section = pfn_to_section_nr(pfn), ssec, esec;
 	/*
 	 * NOTE: The following SMP-unsafe globals are only used early in boot
 	 * when the kernel is running single-threaded.
-- 
1.8.3.4

--
To unsubscribe from this list: send the line "unsubscribe linux-ia64" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel]     [Sparc Linux]     [DCCP]     [Linux ARM]     [Yosemite News]     [Linux SCSI]     [Linux x86_64]     [Linux for Ham Radio]

  Powered by Linux