public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [Patch]Fix the compilation error of function addr_to_node on IA64
@ 2007-10-03  7:40 Cai Fei
  0 siblings, 0 replies; only message in thread
From: Cai Fei @ 2007-10-03  7:40 UTC (permalink / raw)
  To: systemtap

Hi, all

The function addr_to_node defined in memory.stp can not work properly on 
IA64,
because the function node_start_pfn is not defined on IA64.

I made a patch as below so the function can work on all archs.
If no objection, I will commit it.

diff -Nur systemtap-20070929.orig/tapset/memory.stp systemtap-20070929/tapset/memory.stp
--- systemtap-20070929.orig/tapset/memory.stp	2007-10-03 10:48:26.000000000 +0900
+++ systemtap-20070929/tapset/memory.stp	2007-10-03 10:49:12.000000000 +0900
@@ -51,8 +51,8 @@
         int nid;
         int pfn = __pa(THIS->addr) >> PAGE_SHIFT;
         for_each_online_node(nid)
-                if ( node_start_pfn(nid) <= pfn &&
-                        pfn < (node_start_pfn(nid) +
+                if ( NODE_DATA(nid)->node_start_pfn <= pfn &&
+                        pfn < (NODE_DATA(nid)->node_start_pfn +
                         NODE_DATA(nid)->node_spanned_pages) )
                 {
 			THIS->__retvalue = nid;



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2007-10-03  7:40 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-10-03  7:40 [Patch]Fix the compilation error of function addr_to_node on IA64 Cai Fei

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).