Skip to contentSkip to conversation

x86, numa: Use __pa_nodebug instead

PATCH In review Borislav Petkov 3 participants 4 messages Jan 27, 2013 – Jan 31, 2013

Subsystems (2)
lore
Share & tools
lore

Borislav Petkov

author maintainer
#0 lore raw

PATCH 1/1 x86, numa: Use __pa_nodebug instead

From: Borislav Petkov <[email protected]>

... and fix the following warning:

arch/x86/mm/numa.c: In function ‘setup_node_data’:
arch/x86/mm/numa.c:222:3: warning: passing argument 1 of ‘__phys_addr_nodebug’ makes integer from pointer without a cast [enabled by default] In file included from /home/boris/w/kernel/linux-2.6/arch/x86/include/asm/page.h:11:0,

                 from /home/boris/w/kernel/linux-2.6/arch/x86/include/asm/thread_info.h:11,
                 from include/linux/thread_info.h:54,
                 from include/linux/preempt.h:9,
                 from include/linux/spinlock.h:50,
                 from include/linux/mmzone.h:7,
                 from include/linux/gfp.h:4,
                 from include/linux/mm.h:8,
                 from arch/x86/mm/numa.c:3:

/home/boris/w/kernel/linux-2.6/arch/x86/include/asm/page_64.h:12:29: note: expected ‘long unsigned int’ but argument is of type ‘void *’

---
 arch/x86/mm/numa.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/mm/numa.c +1 -1
index 76604eb9e4b0..b2313c6739f5 100644
@@ -219,7 +219,7 @@ static void __init setup_node_data(int nid, u64 start, u64 end)
 	 */
 	nd = alloc_remap(nid, nd_size);
 	if (nd) {
-		nd_pa = __phys_addr_nodebug(nd);
+		nd_pa = __pa_nodebug(nd);
 		remapped = true;
 	} else {
 		nd_pa = memblock_alloc_nid(nd_size, SMP_CACHE_BYTES, nid);
Signature · 1 line
1.8.1.rc3
Acked-by on v1 1/1
#1 lore raw
Quoted 15 lines · Borislav Petkov

From: Borislav Petkov <[email protected]>

... and fix the following warning:

arch/x86/mm/numa.c: In function ‘setup_node_data’:
arch/x86/mm/numa.c:222:3: warning: passing argument 1 of ‘__phys_addr_nodebug’ makes integer from pointer without a cast [enabled by default] In file included from /home/boris/w/kernel/linux-2.6/arch/x86/include/asm/page.h:11:0,

                 from /home/boris/w/kernel/linux-2.6/arch/x86/include/asm/thread_info.h:11,
                 from include/linux/thread_info.h:54,
                 from include/linux/preempt.h:9,
                 from include/linux/spinlock.h:50,
                 from include/linux/mmzone.h:7,
                 from include/linux/gfp.h:4,
                 from include/linux/mm.h:8,
                 from arch/x86/mm/numa.c:3:
Quoted 4 lines

/home/boris/w/kernel/linux-2.6/arch/x86/include/asm/page_64.h:12:29: note: expected ‘long unsigned int’ but argument is of type ‘void *’

I was just about to send out a patch for it and came up with the same fix.

author maintainer
#2 lore raw
Quoted 18 lines · Dave Hansen
Quoted 17 lines · Borislav Petkov

From: Borislav Petkov <[email protected]>

... and fix the following warning:

arch/x86/mm/numa.c: In function ‘setup_node_data’:
arch/x86/mm/numa.c:222:3: warning: passing argument 1 of ‘__phys_addr_nodebug’ makes integer from pointer without a cast [enabled by default] In file included from /home/boris/w/kernel/linux-2.6/arch/x86/include/asm/page.h:11:0,

                 from /home/boris/w/kernel/linux-2.6/arch/x86/include/asm/thread_info.h:11,
                 from include/linux/thread_info.h:54,
                 from include/linux/preempt.h:9,
                 from include/linux/spinlock.h:50,
                 from include/linux/mmzone.h:7,
                 from include/linux/gfp.h:4,
                 from include/linux/mm.h:8,
                 from arch/x86/mm/numa.c:3:

/home/boris/w/kernel/linux-2.6/arch/x86/include/asm/page_64.h:12:29: note: expected ‘long unsigned int’ but argument is of type ‘void *’

Quoted 6 lines
Quoted 2 lines

I was just about to send out a patch for it and came up with the same fix.

This still triggers on tip:x86/mm.

Signature · 5 lines
Regards/Gruss,
    Boris.

Sent from a fat crate under my desk. Formatting is fine.
--
#3 lore raw

[tip:x86/mm] x86/numa: Use __pa_nodebug() instead

In reply to Borislav Petkov
Commit-ID:  1e9209edc71b851d81f0316ca03a0e6335c0ef9a
Gitweb:     http://git.kernel.org/tip/1e9209edc71b851d81f0316ca03a0e6335c0ef9a
Author:     Borislav Petkov <[email protected]>
AuthorDate: Sun, 27 Jan 2013 01:18:21 +0100
Committer:  Ingo Molnar <[email protected]>
CommitDate: Thu, 31 Jan 2013 11:40:55 +0100

x86/numa: Use __pa_nodebug() instead

... and fix the following warning:

arch/x86/mm/numa.c: In function ‘setup_node_data’:
arch/x86/mm/numa.c:222:3: warning: passing argument 1 of ‘__phys_addr_nodebug’ makes integer from pointer without a cast

---
 arch/x86/mm/numa.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/mm/numa.c +1 -1
index 76604eb..b2313c6 100644
@@ -219,7 +219,7 @@ static void __init setup_node_data(int nid, u64 start, u64 end)
 	 */
 	nd = alloc_remap(nid, nd_size);
 	if (nd) {
-		nd_pa = __phys_addr_nodebug(nd);
+		nd_pa = __pa_nodebug(nd);
 		remapped = true;
 	} else {
 		nd_pa = memblock_alloc_nid(nd_size, SMP_CACHE_BYTES, nid);