kexec on mips

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello all,

I'm running both openwrt and debian on a mips-based wndr3800 netgear router/ap and I'm using kexec to arrange kind of dual-boot in a safe and comfortable manner.

Now, I've found that the following is critical for kexec to actually work:
--- arch/mips/kernel/machine_kexec.c.orig 2012-02-08 01:58:13.000000000 +0300
+++ arch/mips/kernel/machine_kexec.c    2012-02-20 22:19:11.000000000 +0300
@@ -52,7 +52,7 @@
        reboot_code_buffer =
          (unsigned long)page_address(image->control_code_page);

-       kexec_start_address = image->start;
+       kexec_start_address = (unsigned long) phys_to_virt(image->start);
        kexec_indirection_page =
                (unsigned long) phys_to_virt(image->head & PAGE_MASK);

I've found that in openwrt repository this change was present (among others) in a big patchset targeted for kernel 2.6.30 and now it is still present as a small separate patch for 2.6.38 (target/linux/generic/patches-2.6.38/303-mips_fix_kexec.patch) and maybe others. Meanwhile, the latest _stable_ openwrt for the moment (backfire 10.03.1) was released with kernel 2.6.32 without this patch so I had to dig through some forums to find the reason of kexec not working out-of-the-box. I've just now checked and the latest kernel.org's stable kernel (3.2.6) does not seem to include this either. Ok, since I know the secret already I'll fix it for myself anytime, but maybe some kind soul could just submit this _one_ line upstream? I'd say this feature is really handy in some cases.

Thank you.

(Please CC me, I'm not subscribed to linux-mips)

Nikolai



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux