From: Michael Gernoth Date: Wed, 25 May 2011 08:18:10 +0000 (+0200) Subject: don't shut down devices, still doesn't work on MS2 even with more ATAGS X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/ms2-kexec/commitdiff_plain/76b7ce1b4f9828baf75c68eb54773b53825a4604?hp=37bd435c064ca052fbd3a5772e48f0126a1a5c7b don't shut down devices, still doesn't work on MS2 even with more ATAGS --- diff --git a/sys.c b/sys.c index e01c432..d637180 100644 --- a/sys.c +++ b/sys.c @@ -46,7 +46,7 @@ extern asmlinkage long (*original_reboot)(int magic1, int magic2, unsigned int cmd, void __user *arg); -#if 0 +#if 1 static struct notifier_block dummy_notifier_reboot = { .notifier_call = NULL, .next = NULL, @@ -59,11 +59,12 @@ BLOCKING_NOTIFIER_HEAD(notifier_head); void kernel_restart_prepare(char *cmd) { +#if 0 #warning assuming kernel_restart_prepare is at 0xc00779cc void (*original_kernel_restart_prepare)(char *) = (void (*)(char *))0xc00779cc; //void (*original_kernel_restart_prepare)(char *) = (void (*)(char *))KERNEL_RESTART_PREPARE; return original_kernel_restart_prepare(cmd); -#if 0 +#else register_reboot_notifier(&dummy_notifier_reboot); notifier_head.head=dummy_notifier_reboot.next; unregister_reboot_notifier(&dummy_notifier_reboot);