On Fri, Jun 3, 2016 at 11:32 AM, Ulf Hansson <ulf.hansson@xxxxxxxxxx> wrote: > I believe most other led-trigger types that should also be "suspended" > in the similar fashion as the heartbeat. Perhaps not all, but least > some more (timer, cpu, etc). I'm uncertain about those ... I guess they need separate patches at least. > Okay, my point is, perhaps we should do this in a more generic manner > and manage the suspend/resume of triggers in > drivers/leds/led-triggers.c? That must be done by someone familar with that code I'm afraid. I'm not sure, the other triggers have their own special hooks (like the CPU trigger hooking into the CPU suspend/resume ops) so I'm worried about breaking them. >> + switch (pm_event) { >> + case PM_SUSPEND_PREPARE: > > I think you should add: > case PM_HIBERNATION_PREPARE: > case PM_RESTORE_PREPARE: > >> + led_trigger_unregister(&heartbeat_led_trigger); >> + break; >> + case PM_POST_SUSPEND: > > I think you should add: > case PM_POST_HIBERNATION: > case PM_POST_RESTORE: Fixing this and resending. Yours, Linus Walleij -- To unsubscribe from this list: send the line "unsubscribe linux-leds" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html