Re: [patch 1/2] tick/broadcast: Prevent deep idle states if no broadcast device available

From: Sudeep Holla
Date: Tue Jul 07 2015 - 07:25:59 EST


Hi Thomas,

On 07/07/15 08:31, Thomas Gleixner wrote:
On Mon, 6 Jul 2015, Thomas Gleixner wrote:

On Mon, 6 Jul 2015, Sudeep Holla wrote:
This triggered the below crash on boot, looks like it's accessing
hrtimer->function which is null in periodic mode IIUC

Regards,
Sudeep

Gah. I have no idea how that gets queued. /me goes off to tweak x86 to
emulate that crap.

So with a less heat damaged brain, I think I was able to decode the
twisted logic behind all this.

Can you test the patch below please?



Yes I tested this patch for all the combinations I had mentioned in my
earlier email. Everything works as expected. Thanks a lot for the
patience. Please feel free to add:

Tested-by: Sudeep Holla <sudeep.holla@xxxxxxx>

{
Index: tip/kernel/time/tick-broadcast.c
===================================================================
--- tip.orig/kernel/time/tick-broadcast.c
+++ tip/kernel/time/tick-broadcast.c

@@ -938,6 +972,16 @@ bool tick_broadcast_oneshot_available(vo
return bc ? bc->features & CLOCK_EVT_FEAT_ONESHOT : false;
}

+#else
+int __tick_broadcast_oneshot_control(enum tick_broadcast_state state)
+{
+ struct clock_event_device *bc = tick_broadcast_device.evtdev;
+
+ if (!bc || (bc->features & CLOCK_EVT_FEAT_HRTIMER)

missing ')' at the end in the above statement

Regards,
Sudeep
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/