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

Re: [microblaze-uclinux] Reboot Command



Hi Torin,

On Sat, Oct 10, 2009 at 4:58 AM, Torin Ford <torin@xxxxxxxxxxxx> wrote:
Hey All.  I'm using petalinux-0.40-rc4.  Whenever I try to use the
reboot command, I get the following output:

Restarting system.
Machine restart...

<stack trace dumped here>

Any ideas why it dumps and doesn't just reset?  

MicroBlaze lacks a in-built soft-reset capability, so it's not possible for the kernel to implement a generic reset.  Instead, the MicroBlaze kernel hook for it (down in arch/microblaze/kernel/setup.c, machine_restart()) defaults to a stack dump and then spins forever.

One approach is to add a GPIO with its output connected to the AUX input of the proc_sys_reset instance in the system.  Then, in the machine_restart() function simply toggle that GPIO bit to achieve a reset.


If I boot into u-boot
and issue the reset command, it properly resets the FPGA.

From memory u-boot simply jumps to the reset vector to achieve reset.  Works OK for u-boot but not sufficiently safe for the Linux kernel, you really need a hardware reset to make sure all peripherals are reset, the CPU state cleaned etc.

Regards,

John
--
John Williams, PhD, B.Eng, B.IT
PetaLogix - Linux Solutions for a Reconfigurable World
w: www.petalogix.com  p: +61-7-30090663  f: +61-7-30090663