* [PATCH] mpc8540 : Fix restart
@ 2008-04-09 22:12 Philippe De Muyter
2008-04-09 22:51 ` Kumar Gala
0 siblings, 1 reply; 4+ messages in thread
From: Philippe De Muyter @ 2008-04-09 22:12 UTC (permalink / raw)
To: linuxppc-dev
Hi everybody,
Previously, with the arch/ppc tree, mpc8540 boards could reboot.
Now with the arch/powerpc tree, they can not anymore.
Fix that.
Signed-off-by: Philippe De Muyter <phdm@macqel.be>
--- a/arch/powerpc/sysdev/fsl_soc.c 2008-03-21 14:53:41.000000000 +0000
+++ b/arch/powerpc/sysdev/fsl_soc.c 2008-03-26 12:08:25.000000000 +0000
@@ -1428,13 +1433,17 @@
arch_initcall(setup_rstcr);
+extern void abort(void);
+
void fsl_rstcr_restart(char *cmd)
{
local_irq_disable();
if (rstcr)
/* set reset control register */
out_be32(rstcr, 0x2); /* HRESET_REQ */
-
+ else
+ abort();
while (1) ;
+
}
#endif
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH] mpc8540 : Fix restart
2008-04-09 22:12 [PATCH] mpc8540 : Fix restart Philippe De Muyter
@ 2008-04-09 22:51 ` Kumar Gala
2008-04-09 23:06 ` Philippe De Muyter
0 siblings, 1 reply; 4+ messages in thread
From: Kumar Gala @ 2008-04-09 22:51 UTC (permalink / raw)
To: Philippe De Muyter; +Cc: linuxppc-dev
On Apr 9, 2008, at 5:12 PM, Philippe De Muyter wrote:
> Hi everybody,
>
> Previously, with the arch/ppc tree, mpc8540 boards could reboot.
> Now with the arch/powerpc tree, they can not anymore.
> Fix that.
>
> Signed-off-by: Philippe De Muyter <phdm@macqel.be>
>
> --- a/arch/powerpc/sysdev/fsl_soc.c 2008-03-21 14:53:41.000000000
> +0000
> +++ b/arch/powerpc/sysdev/fsl_soc.c 2008-03-26 12:08:25.000000000
> +0000
> @@ -1428,13 +1433,17 @@
>
> arch_initcall(setup_rstcr);
>
> +extern void abort(void);
> +
> void fsl_rstcr_restart(char *cmd)
> {
> local_irq_disable();
> if (rstcr)
> /* set reset control register */
> out_be32(rstcr, 0x2); /* HRESET_REQ */
> -
> + else
> + abort();
> while (1) ;
> +
> }
This was on purpose. abort() doesn't really do a restart and thus I
didn't want it to be used that way.
- k
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH] mpc8540 : Fix restart
2008-04-09 22:51 ` Kumar Gala
@ 2008-04-09 23:06 ` Philippe De Muyter
2008-04-14 15:20 ` Kumar Gala
0 siblings, 1 reply; 4+ messages in thread
From: Philippe De Muyter @ 2008-04-09 23:06 UTC (permalink / raw)
To: Kumar Gala; +Cc: linuxppc-dev
On Wed, Apr 09, 2008 at 05:51:40PM -0500, Kumar Gala wrote:
>
> On Apr 9, 2008, at 5:12 PM, Philippe De Muyter wrote:
>> Hi everybody,
>>
>> Previously, with the arch/ppc tree, mpc8540 boards could reboot.
>> Now with the arch/powerpc tree, they can not anymore.
>> Fix that.
>>
>> Signed-off-by: Philippe De Muyter <phdm@macqel.be>
>>
>> --- a/arch/powerpc/sysdev/fsl_soc.c 2008-03-21 14:53:41.000000000 +0000
>> +++ b/arch/powerpc/sysdev/fsl_soc.c 2008-03-26 12:08:25.000000000 +0000
>> @@ -1428,13 +1433,17 @@
>>
>> arch_initcall(setup_rstcr);
>>
>> +extern void abort(void);
>> +
>> void fsl_rstcr_restart(char *cmd)
>> {
>> local_irq_disable();
>> if (rstcr)
>> /* set reset control register */
>> out_be32(rstcr, 0x2); /* HRESET_REQ */
>> -
>> + else
>> + abort();
>> while (1) ;
>> +
>> }
>
> This was on purpose. abort() doesn't really do a restart and thus I didn't
> want it to be used that way.
>
What do you propose then ? The ability to reboot without power-off is
really needed for embedded targets. And abort() from head_fsl.S seems
really close to reboot.
Philippe
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2008-04-14 15:20 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-04-09 22:12 [PATCH] mpc8540 : Fix restart Philippe De Muyter
2008-04-09 22:51 ` Kumar Gala
2008-04-09 23:06 ` Philippe De Muyter
2008-04-14 15:20 ` Kumar Gala
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox