From e750b7ef67f033fbf19fbcabd7dbe441f5fb501b Mon Sep 17 00:00:00 2001 From: Michael Gernoth Date: Sun, 22 May 2011 12:43:48 +0200 Subject: [PATCH] hardcode location of ms2 syscall_table --- kexec.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/kexec.c b/kexec.c index 8a437da..7989634 100644 --- a/kexec.c +++ b/kexec.c @@ -1459,13 +1459,17 @@ unsigned long **find_sys_call_table(void) { static int __init kexec_module_init(void) { -// sys_call_table=(void **)find_sys_call_table(); -// if(sys_call_table==NULL) { -// printk(KERN_ERR "Cannot find the system call address\n"); -// return -1; // do not load -// } + sys_call_table=(void **)find_sys_call_table(); + if(sys_call_table==NULL) { + printk(KERN_ERR "Cannot find the system call address\n"); + return -1; // do not load + } + + printk(KERN_INFO "kexec: Found sys_call_table at: %p\n", sys_call_table); - sys_call_table=(void **)0xc003d004; + //sys_call_table=(void **)0xc003d004; + sys_call_table=(void **)0xc00350c4; + printk(KERN_INFO "kexec: Force sys_call_table at: %p\n", sys_call_table); /* Set kexec_load() syscall. */ sys_call_table[__NR_kexec_load]=kexec_load; -- 2.39.5