i modified both kexec-tools and module in kernel to ingnore some validity checking. but when the code in kernel is going to copy the new kernel to old kernel, a pagefault exception is receive like this: ~ # kexec -e Starting new kernel Unhandled kernel unaligned access[#1]: Cpu 1 $ 0 : 0000000000000000 0000000000000001 a80000002331fbb0 ffffffffffffffff $ 4 : ffffffff8113981c ffffffff8113cf18 ffffffff8113cf14 ffffffff01100000 $ 8 : 000000000000ffff a80000002331fb90 000000000000000a ffffffff813d85d8 $12 : 0000000010008ce1 000000001000001e ffffffff81169a90 00000001200049d0 $16 : a80000002331fb90 fffffffffc440000 ffffffff83fe0000 ffffff0000000000 $20 : ffffffff81140000 a8000000231c5800 a800000021b17000 0000000000000008 $24 : 0000000000000079 0000000000000000 $28 : a80000002331c000 a80000002331fb60 000000ffffe0ca40 ffffffff81132544 Hi : 0000000009600000 Lo : 0000000005a0d200 epc : ffffffff81139840 do_ade+0x2e0/0x470 Not tainted ra : ffffffff81132544 ret_from_exception+0x0/0x10 Status: 10008ce3 KX SX UX KERNEL EXL IE Cause : 00800014 BadVA : ffffffff01100000 PrId : 000d0401 (Cavium Octeon) Modules linked in: Process kexec (pid: 827, threadinfo=a80000002331c000, task=a80000000bec4040, tls=000000555557eb20) Stack : ffffffff83fdc1b7 0000000000000000 0000000000000000 ffffffff83fe0000 000000000000001e ffffffff81132544 0000000000000000 0000000000000001 ffffffff01100000 ffffffff81430000 ffffffffffffffff 0000000000000001 ffffffffffffffff 00000000000017d5 000000000000ffff ffffffff83fcc190 000000000000000a ffffffff813d85d8 0000000000000020 ffffffff8127fd4c ffffffff81169a90 00000001200049d0 0000000000000000 0000000000000000 ffffffff83fe0000 000000000000001e ffffffff81140000 a8000000231c5800 a800000021b17000 0000000000000008 0000000000000079 0000000000000000 ffffffff81140000 a8000000231c5800 a80000002331c000 a80000002331fcf0 000000ffffe0ca40 ffffffff8113cf04 0000000010008ce3 0000000009600000 ... Call Trace: [<ffffffff81139840>] do_ade+0x2e0/0x470 [<ffffffff81132544>] ret_from_exception+0x0/0x10 [<ffffffff8113cf14>] machine_kexec+0xd4/0x1d0 [<ffffffff81182c64>] kernel_kexec+0x84/0x90 [<ffffffff81169c6c>] sys_reboot+0x1dc/0x210 [<ffffffff8113bdfc>] handle_sys+0xfc/0x118 Code: 000210f8 0202102d dc430000 <b0e30000> b4e30007 24030000 1460ffd8 00000000 8e020124 Segmentation fault i do some test, that i copy something to user space .text segment before also receive a segementation fault. This means the readonly .text cannot be written. How to avoid this in the context of KEXEC? PS: my kernel version is 2.6.27 ------------------ ???? ------------------ >From: Simon Horman <horms at verge.net.au> >Reply-To: >To: ???<06120216 at bjtu.edu.cn> >Subject: Re: help for install kexec-tools >Date: Fri, 13 Nov 2009 13:44:01 +1100 > >On Thu, Nov 12, 2009 at 04:18:11PM +0800, ??? wrote: >> Currently, i'm trying to install kexec-tools on a box which have a octeon mips cpu with a gcc compiler tuned by cavium. unfortunately, some compiler error happens. >> Is it possible to run your tools on such a environment? if possible, i will spend more time to fix the error. > >Hi, > >I expect that it is possible to get things working. >Perhaps posting the errors to the kexec mailing list >would help? > >