* [PATCH] ARM: disable interrupt before spinning endlessly
@ 2012-07-09 9:09 Shawn Guo
2012-07-13 7:44 ` Shawn Guo
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Shawn Guo @ 2012-07-09 9:09 UTC (permalink / raw)
To: linux-arm-kernel
The CPU will endlessly spin at the end of machine_halt and
machine_restart calls. However, this will lead to a soft lockup
warning after about 20 seconds, if CONFIG_LOCKUP_DETECTOR is enabled,
as system timer is still alive.
Disable interrupt before going to spin endlessly, so that the lockup
warning will never be seen.
Reported-by: Marek Vasut <marex@denx.de>
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
---
arch/arm/kernel/process.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c
index 19c95ea..693b744 100644
--- a/arch/arm/kernel/process.c
+++ b/arch/arm/kernel/process.c
@@ -247,6 +247,7 @@ void machine_shutdown(void)
void machine_halt(void)
{
machine_shutdown();
+ local_irq_disable();
while (1);
}
@@ -268,6 +269,7 @@ void machine_restart(char *cmd)
/* Whoops - the platform was unable to reboot. Tell the user! */
printk("Reboot failed -- System halted\n");
+ local_irq_disable();
while (1);
}
--
1.7.5.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH] ARM: disable interrupt before spinning endlessly
2012-07-09 9:09 [PATCH] ARM: disable interrupt before spinning endlessly Shawn Guo
@ 2012-07-13 7:44 ` Shawn Guo
2012-07-13 17:32 ` Marek Vasut
2012-07-29 21:22 ` Russell King - ARM Linux
2 siblings, 0 replies; 5+ messages in thread
From: Shawn Guo @ 2012-07-13 7:44 UTC (permalink / raw)
To: linux-arm-kernel
Russell,
I took this patch as a trivial one and just put it into the patch
system as 7466/1, though I have got neither Reviewed-by nor Tested-by
with the patch on the list for several days.
Regards,
Shawn
On Mon, Jul 09, 2012 at 05:09:48PM +0800, Shawn Guo wrote:
> The CPU will endlessly spin at the end of machine_halt and
> machine_restart calls. However, this will lead to a soft lockup
> warning after about 20 seconds, if CONFIG_LOCKUP_DETECTOR is enabled,
> as system timer is still alive.
>
> Disable interrupt before going to spin endlessly, so that the lockup
> warning will never be seen.
>
> Reported-by: Marek Vasut <marex@denx.de>
> Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
> ---
> arch/arm/kernel/process.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c
> index 19c95ea..693b744 100644
> --- a/arch/arm/kernel/process.c
> +++ b/arch/arm/kernel/process.c
> @@ -247,6 +247,7 @@ void machine_shutdown(void)
> void machine_halt(void)
> {
> machine_shutdown();
> + local_irq_disable();
> while (1);
> }
>
> @@ -268,6 +269,7 @@ void machine_restart(char *cmd)
>
> /* Whoops - the platform was unable to reboot. Tell the user! */
> printk("Reboot failed -- System halted\n");
> + local_irq_disable();
> while (1);
> }
>
> --
> 1.7.5.4
>
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH] ARM: disable interrupt before spinning endlessly
2012-07-09 9:09 [PATCH] ARM: disable interrupt before spinning endlessly Shawn Guo
2012-07-13 7:44 ` Shawn Guo
@ 2012-07-13 17:32 ` Marek Vasut
2012-07-29 21:22 ` Russell King - ARM Linux
2 siblings, 0 replies; 5+ messages in thread
From: Marek Vasut @ 2012-07-13 17:32 UTC (permalink / raw)
To: linux-arm-kernel
Dear Shawn Guo,
> The CPU will endlessly spin at the end of machine_halt and
> machine_restart calls. However, this will lead to a soft lockup
> warning after about 20 seconds, if CONFIG_LOCKUP_DETECTOR is enabled,
> as system timer is still alive.
>
> Disable interrupt before going to spin endlessly, so that the lockup
> warning will never be seen.
>
> Reported-by: Marek Vasut <marex@denx.de>
> Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
> ---
> arch/arm/kernel/process.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
I just got back from a conference, I'd gladly test. But my mx28 doesn't boot at
all with latest -next. Any idea why?
Best regards,
Marek Vasut
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH] ARM: disable interrupt before spinning endlessly
2012-07-09 9:09 [PATCH] ARM: disable interrupt before spinning endlessly Shawn Guo
2012-07-13 7:44 ` Shawn Guo
2012-07-13 17:32 ` Marek Vasut
@ 2012-07-29 21:22 ` Russell King - ARM Linux
2012-07-30 0:30 ` Shawn Guo
2 siblings, 1 reply; 5+ messages in thread
From: Russell King - ARM Linux @ 2012-07-29 21:22 UTC (permalink / raw)
To: linux-arm-kernel
On Mon, Jul 09, 2012 at 05:09:48PM +0800, Shawn Guo wrote:
> The CPU will endlessly spin at the end of machine_halt and
> machine_restart calls. However, this will lead to a soft lockup
> warning after about 20 seconds, if CONFIG_LOCKUP_DETECTOR is enabled,
> as system timer is still alive.
>
> Disable interrupt before going to spin endlessly, so that the lockup
> warning will never be seen.
>
> Reported-by: Marek Vasut <marex@denx.de>
> Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
> ---
Should this also be Cc'd to stable when it's committed?
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH] ARM: disable interrupt before spinning endlessly
2012-07-29 21:22 ` Russell King - ARM Linux
@ 2012-07-30 0:30 ` Shawn Guo
0 siblings, 0 replies; 5+ messages in thread
From: Shawn Guo @ 2012-07-30 0:30 UTC (permalink / raw)
To: linux-arm-kernel
On Sun, Jul 29, 2012 at 10:22:16PM +0100, Russell King - ARM Linux wrote:
> On Mon, Jul 09, 2012 at 05:09:48PM +0800, Shawn Guo wrote:
> > The CPU will endlessly spin at the end of machine_halt and
> > machine_restart calls. However, this will lead to a soft lockup
> > warning after about 20 seconds, if CONFIG_LOCKUP_DETECTOR is enabled,
> > as system timer is still alive.
> >
> > Disable interrupt before going to spin endlessly, so that the lockup
> > warning will never be seen.
> >
> > Reported-by: Marek Vasut <marex@denx.de>
> > Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
> > ---
>
> Should this also be Cc'd to stable when it's committed?
Yes, I forgot it.
I assume you will take care of it when you commit it to your tree.
Otherwise, please let me know and I will resubmit the patch.
--
Regards,
Shawn
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-07-30 0:30 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-09 9:09 [PATCH] ARM: disable interrupt before spinning endlessly Shawn Guo
2012-07-13 7:44 ` Shawn Guo
2012-07-13 17:32 ` Marek Vasut
2012-07-29 21:22 ` Russell King - ARM Linux
2012-07-30 0:30 ` Shawn Guo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).