* BUG at cpuidle_play_dead
@ 2012-04-05 21:03 Jiri Slaby
2012-04-05 21:11 ` Boris Ostrovsky
0 siblings, 1 reply; 2+ messages in thread
From: Jiri Slaby @ 2012-04-05 21:03 UTC (permalink / raw)
To: Boris Ostrovsky; +Cc: Len Brown, LKML, the arch/x86 maintainers, Jiri Slaby
Hi,
I'm hitting this BUG as the last thing during shutdown:
BUG: unable to handle kernel NULL pointer dereference at 00000000000002d8
IP: [<ffffffff814ab60d>] cpuidle_play_dead+0x1d/0xb0
It's because drv is NULL. The problem is gone if I do this:
--- a/drivers/cpuidle/cpuidle.c
+++ b/drivers/cpuidle/cpuidle.c
@@ -83,6 +83,11 @@ int cpuidle_play_dead(void)
int i, dead_state = -1;
int power_usage = -1;
+ if (!drv) {
+ printk("DRIVER IS NULL\n");
+ return -ENODEV;
+ }
+
/* Find lowest-power state that supports long-term idle */
for (i = CPUIDLE_DRIVER_STATE_START; i < drv->state_count; i++) {
struct cpuidle_state *s = &drv->states[i];
thanks,
--
js
suse labs
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: BUG at cpuidle_play_dead
2012-04-05 21:03 BUG at cpuidle_play_dead Jiri Slaby
@ 2012-04-05 21:11 ` Boris Ostrovsky
0 siblings, 0 replies; 2+ messages in thread
From: Boris Ostrovsky @ 2012-04-05 21:11 UTC (permalink / raw)
To: Jiri Slaby, Len Brown
Cc: LKML, the arch/x86 maintainers, Jiri Slaby, Toshi Kani
On 04/05/12 17:03, Jiri Slaby wrote:
> Hi,
>
> I'm hitting this BUG as the last thing during shutdown:
> BUG: unable to handle kernel NULL pointer dereference at 00000000000002d8
> IP: [<ffffffff814ab60d>] cpuidle_play_dead+0x1d/0xb0
>
>
> It's because drv is NULL. The problem is gone if I do this:
> --- a/drivers/cpuidle/cpuidle.c
> +++ b/drivers/cpuidle/cpuidle.c
> @@ -83,6 +83,11 @@ int cpuidle_play_dead(void)
> int i, dead_state = -1;
> int power_usage = -1;
>
> + if (!drv) {
> + printk("DRIVER IS NULL\n");
> + return -ENODEV;
> + }
> +
> /* Find lowest-power state that supports long-term idle */
> for (i = CPUIDLE_DRIVER_STATE_START; i< drv->state_count; i++) {
> struct cpuidle_state *s =&drv->states[i];
>
> thanks,
This was already fixed in https://lkml.org/lkml/2012/3/31/249.
Len, please apply that patch.
Thanks.
-boris
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2012-04-05 21:11 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-04-05 21:03 BUG at cpuidle_play_dead Jiri Slaby
2012-04-05 21:11 ` Boris Ostrovsky
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox