projects
/
linux-2.6-microblaze.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
um: fix stub location calculation
[linux-2.6-microblaze.git]
/
arch
/
x86
/
um
/
shared
/
sysdep
/
stub_32.h
diff --git
a/arch/x86/um/shared/sysdep/stub_32.h
b/arch/x86/um/shared/sysdep/stub_32.h
index
b95db9d
..
4c6c2be
100644
(file)
--- a/
arch/x86/um/shared/sysdep/stub_32.h
+++ b/
arch/x86/um/shared/sysdep/stub_32.h
@@
-101,4
+101,16
@@
static inline void remap_stack_and_trap(void)
"memory");
}
+static __always_inline void *get_stub_page(void)
+{
+ unsigned long ret;
+
+ asm volatile (
+ "movl %%esp,%0 ;"
+ "andl %1,%0"
+ : "=a" (ret)
+ : "g" (~(UM_KERN_PAGE_SIZE - 1)));
+
+ return (void *)ret;
+}
#endif