public inbox for kexec@lists.infradead.org
 help / color / mirror / Atom feed
* Re: [KEXEC] [ARM]
       [not found] <9b8644470804102121k43362a86i92d4d80275569dc4@mail.gmail.com>
@ 2008-04-11  7:48 ` Eric W. Biederman
  2008-04-28 18:48   ` [ARM] SUNDEEP BORRA
  2011-04-19 12:18   ` [KEXEC] [ARM] zhangchenyu
  0 siblings, 2 replies; 4+ messages in thread
From: Eric W. Biederman @ 2008-04-11  7:48 UTC (permalink / raw)
  To: Sundeep Borra, kexec

I've added the kexec list as there may be other people that can help
out.

On Fri, 2008-04-11 at 09:51 +0530, Sundeep Borra wrote:
> Dear Eric,
> 
> I am working on KEXEC tool for ARM platform with linux-2.6.22.6.
> I have problem loading and running the zImage that is compiled with
> kexec_syscall support.
> 
> I found no code related to ARM architecture either in pugatory or in
> other branch of Kexec-tools source tree.

Have you looked at the kexec-tools-testing repository.  That is where
the work has been happening lately.

> I searched for Corresponding Patches on Net and those patches had
> nothign significant about ARM support on Purgatory,
> 
> Where to start from, inorder to get ARm specific purgatory code.

Well we compile purgatory as a relocatable object file and then 
process the relocations so we can put it in memory wherever we want
so there is relocation support.

Beyond that for purgatory it should just be a handful of stubs from
assembly to C that should be straight forward to write if you know
the architecture.

> I would like to donate ARM specific code if one doesn't exist

Well.  I don't know a lot about the ARM architecture but I can give some
general guidance.

As I recall ARM has the option to disable the MMU like x86 and the
kernel starts in that mode by default which makes things straight 
forward.

The biggest part is to figure out the format that the ARM kernel
accepts arguments in and generate those arguments when you load
an ARM kernel.  Basically that the kexec code really does collect
up the information a boot loader would pass and it passes it to the
kernel.


> -----------------------------------------------------------------------------------------------------
> KEXEC-tools Version: 1.101
> ----------------------------------------
> 
> PLATFORM: ARM926
> --------------------------------
> 
> COMMAND:
> ------------------
> ./kexec -l vmlinux
> 
> 
> ERROR:
> ------------
> 
> kernel: 0x4012c008 kernel_size: 191e72
> kexec_load: entry = 0xa0008000 flags = 280000
> nr_segments = 1
> segment[0].buf   = 0x4012c008
> segment[0].bufsz = 191e72
> segment[0].mem   = 0xa0008000
> segment[0].memsz = 192000
> kexec_load failed: Function not implemented
-ENOSYS?

Is the kernel portion of kexec implemented on ARM?

> entry       = 0xa0008000 flags = 280000
> nr_segments = 1
> segment[0].buf   = 0x4012c008
> segment[0].bufsz = 191e72
> segment[0].mem   = 0xa0008000
> segment[0].memsz = 192000
> 
> 
> CAUSE: syscall is failing in file kexec/kexec.c
> 
> -----------------------------------------------------------------------------------------------------
> Please help me in this regard,
> 
> Thanks in advance.

Hope this helps some.

Eric



_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [ARM]
  2008-04-11  7:48 ` [KEXEC] [ARM] Eric W. Biederman
@ 2008-04-28 18:48   ` SUNDEEP BORRA
  2011-04-19 12:18   ` [KEXEC] [ARM] zhangchenyu
  1 sibling, 0 replies; 4+ messages in thread
From: SUNDEEP BORRA @ 2008-04-28 18:48 UTC (permalink / raw)
  To: kexec



Dear Eric,

I got the Apt sources for ARM-KEXEC from Simon Horman. As I claimed before, 
neither the purgatory nor the testing code of the repository till date has got 
only dummy functions and no ARM specific code is ready. The one I got from 
Simon Horman, maintaining it with all updates to all architectures, is working 
fine.

It is at ftp://ftp.kernel.org/pub/linux/kernel/people/horms/kexec-tools/

Thanks for your response,

Regards,
Sundeep Borra



_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [KEXEC] [ARM]
  2008-04-11  7:48 ` [KEXEC] [ARM] Eric W. Biederman
  2008-04-28 18:48   ` [ARM] SUNDEEP BORRA
@ 2011-04-19 12:18   ` zhangchenyu
  2011-04-20  7:19     ` zhangchenyu
  1 sibling, 1 reply; 4+ messages in thread
From: zhangchenyu @ 2011-04-19 12:18 UTC (permalink / raw)
  To: kexec

hi:
I have compiled kexe-tools-2.0.2 for arm,

LDFLAGS=-static TARGET_CC=/opt/arm-eabi-4.4.0/bin/arm-eabi-gcc 
./configure arm --build=arm-none-linux-gnueabi 
--target=arm-none-linux-gnueabi --host=i686-pc-linux-gnu

and generated kexec and kdump in kexec-tools-2.0.2/build/sbin/. Then I 
used "adb push" command to download kexec and kdump in /data which is an 
android directory, and made "chmod 755 /data/kexec". But when I did 
"/data/kexec", I got the result as follow:

# /data/kexec
/data/kexec
重櫶\x19?戝鄉%\x10s鄉%嗔B\x10鄉%?C\x18鄉%怋C: not found
\x7fELF\x02\x01\x01\x03\x02: not found
/data/kexec: 2: Syntax error: word unexpected (expecting ")")

I do not why. Can some one tell me?

Thank you very much.


_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [KEXEC] [ARM]
  2011-04-19 12:18   ` [KEXEC] [ARM] zhangchenyu
@ 2011-04-20  7:19     ` zhangchenyu
  0 siblings, 0 replies; 4+ messages in thread
From: zhangchenyu @ 2011-04-20  7:19 UTC (permalink / raw)
  To: kexec

hi:
I used standard arm-linux-gcc, and configured as follow:

LDFLAGS=-static 
TARGET_CC=/opt/usr/local/arm/4.3.2/bin/arm-none-linux-gnueabi-gcc 
TARGET_LD=/opt/usr/local/arm/4.3.2/bin/arm-none-linux-gnueabi-ld 
./configure arm --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu 
--target=arm-none-linux-gnueabi

and when I execute on android as follow:
# /data/kexec
/data/kexec
/data/kexec: 6: Syntax error: end of file unexpected (expecting ")")

and I found that "/build/sbin/kexec" I compiled is for x86_64:
root@zcy618-OptiPlex-380:/zcy_workspace/zcy_linux_accumulation/kdump+kexec/kexec-tools-2.0.2# 
file build/sbin/kexec
build/sbin/kexec: ELF 64-bit LSB executable, x86-64, version 1 
(GNU/Linux), statically linked, for GNU/Linux 2.6.15, not stripped

root@zcy618-OptiPlex-380:/zcy_workspace/zcy_linux_accumulation/kdump+kexec/kexec-tools-2.0.2# 
file build/sbin/kdump
build/sbin/kdump: ELF 32-bit LSB executable, ARM, version 1 (SYSV), 
dynamically linked (uses shared libs), for GNU/Linux 2.6.14, not stripped

and I want to know how to compile it for arm, because I thought that I 
have made makefile for arm but it is not.

Could somebody help me? I would very appreciate it.

Thank you very much.

On 2011年04月19日 20:18, zhangchenyu wrote:
> hi:
> I have compiled kexe-tools-2.0.2 for arm,
>
> LDFLAGS=-static TARGET_CC=/opt/arm-eabi-4.4.0/bin/arm-eabi-gcc 
> ./configure arm --build=arm-none-linux-gnueabi 
> --target=arm-none-linux-gnueabi --host=i686-pc-linux-gnu
>
> and generated kexec and kdump in kexec-tools-2.0.2/build/sbin/. Then I 
> used "adb push" command to download kexec and kdump in /data which is 
> an android directory, and made "chmod 755 /data/kexec". But when I did 
> "/data/kexec", I got the result as follow:
>
> # /data/kexec
> /data/kexec
> 重櫶\x19?戝鄉%\x10s鄉%嗔B\x10鄉%?C\x18鄉%怋C: not found
> \x7fELF\x02\x01\x01\x03\x02: not found
> /data/kexec: 2: Syntax error: word unexpected (expecting ")")
>
> I do not why. Can some one tell me?
>
> Thank you very much.
>


_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-04-20  7:19 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <9b8644470804102121k43362a86i92d4d80275569dc4@mail.gmail.com>
2008-04-11  7:48 ` [KEXEC] [ARM] Eric W. Biederman
2008-04-28 18:48   ` [ARM] SUNDEEP BORRA
2011-04-19 12:18   ` [KEXEC] [ARM] zhangchenyu
2011-04-20  7:19     ` zhangchenyu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox