Ummm .... mmzone.h:
#ifdef CONFIG_DISCONTIGMEM
....
#define page_to_pfn(page) ((page - page_zone(page)->zone_mem_map) +
page_zone(page)->zone_start_pfn)
....
#endif /* CONFIG_DISCONTIGMEM */
page.h:
#ifndef CONFIG_DISCONTIGMEM
#define page_to_pfn(page) ((unsigned long)((page) - mem_map))
#endif /* !CONFIG_DISCONTIGMEM */
I'll admit the file obfuscation hides this from being easy to read, but
i'm not stupid enough to screw things up *that* badly. Well, not most
of the time ;-) Want me to reshuffle things around so that the same defines
end up in the same file, and people have a hope in hell of reading it?
If I do that, it'll probably be based on the struct page breakout patch,
and making these things all static inlines, so people stop blowing their
own feet off.
M.
PS. cscope is cool ;-)
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/