aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPekka Enberg <penberg@kernel.org>2013-06-06 21:35:04 +0300
committerPekka Enberg <penberg@kernel.org>2013-06-06 21:35:04 +0300
commitd494ba1ecd6286f7fa2102b0e99a308de839a84f (patch)
tree7e84869d92f33c8d5e474573017b51d7a6797055
parenta49d3cbbe251617942ed45d47a153ab156b6e488 (diff)
downloadjato-d494ba1ecd6286f7fa2102b0e99a308de839a84f.tar.gz
x86-64: Add stack alignment assert() to native_call_gp()
Signed-off-by: Pekka Enberg <penberg@kernel.org>
-rw-r--r--arch/x86/call.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/x86/call.c b/arch/x86/call.c
index 61c6914c..bc20d261 100644
--- a/arch/x86/call.c
+++ b/arch/x86/call.c
@@ -200,6 +200,8 @@ static unsigned long native_call_gp(struct vm_method *method,
stack_size = stack_count * sizeof(unsigned long);
+ assert((stack_size % X86_STACK_ALIGN) == 0);
+
__asm__ volatile (
/* Copy stack arguments onto the stack. */
" movq %[stack], %%rsi \n"