Skip to contentSkip to conversation

: sparc64: Define WANT_PAGE_VIRTUAL

PATCH New David Miller 1 participant 1 message Sep 12, 2008 SPARC + UltraSPARC (sparc/sparc64)

lore
Share & tools
lore

David Miller

author maintainer
#0 lore raw

PATCH 5/16 : sparc64: Define WANT_PAGE_VIRTUAL

sparc64: Define WANT_PAGE_VIRTUAL

As sparse warns, without this struct page pointer subtraction is extremely expensive, and this is a pretty common operation in fast paths.

With this define struct page becomes 64 bytes which makes for a simple subtract and shift, instead of a costly divide or reciprocol multiply.

---
 arch/sparc/include/asm/page_64.h |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
arch/sparc/include/asm/page_64.h +2 -0
index b579b91..4274ed1 100644
@@ -38,6 +38,8 @@
 
 #ifndef __ASSEMBLY__
 
+#define WANT_PAGE_VIRTUAL
+
 extern void _clear_page(void *page);
 #define clear_page(X)	_clear_page((void *)(X))
 struct page;
Signature · 1 line
1.5.6.5.GIT