Re: [PATCH] power: add an API to log wakeup reasons

2014-03-11 Thread Ruchi Kandoi
This API would be called from the platform specific code, or the driver for the interrupt controller, when the system resumes from the suspend because of an IRQ. We track the reasons for which systems wake up from the low power suspend mode. This is especially important on battery-powered

Re: [PATCH] power: add an API to log wakeup reasons

2014-03-11 Thread Joe Perches
On Tue, 2014-03-11 at 17:02 -0700, Ruchi Kandoi wrote: > This API would be called from the platform specific code, [] > This is already in use on some Android devices. We are trying to make > this a generic API which could be called by other platforms as well, > standardizing the format in which

Re: [PATCH] power: add an API to log wakeup reasons

2014-03-11 Thread Rafael J. Wysocki
On Monday, March 10, 2014 07:02:02 PM Ruchi Kandoi wrote: > Add API log_wakeup_reason() and expose it to userspace via sysfs path > /sys/kernel/wakeup_reasons/last_resume_reason > This is useful for power management diagnostic purposes. What's the use case and how is it supposed to work? >

Re: [PATCH] power: add an API to log wakeup reasons

2014-03-11 Thread Rafael J. Wysocki
On Monday, March 10, 2014 07:02:02 PM Ruchi Kandoi wrote: Add API log_wakeup_reason() and expose it to userspace via sysfs path /sys/kernel/wakeup_reasons/last_resume_reason This is useful for power management diagnostic purposes. What's the use case and how is it supposed to work?

Re: [PATCH] power: add an API to log wakeup reasons

2014-03-11 Thread Ruchi Kandoi
This API would be called from the platform specific code, or the driver for the interrupt controller, when the system resumes from the suspend because of an IRQ. We track the reasons for which systems wake up from the low power suspend mode. This is especially important on battery-powered

Re: [PATCH] power: add an API to log wakeup reasons

2014-03-11 Thread Joe Perches
On Tue, 2014-03-11 at 17:02 -0700, Ruchi Kandoi wrote: This API would be called from the platform specific code, [] This is already in use on some Android devices. We are trying to make this a generic API which could be called by other platforms as well, standardizing the format in which the

[PATCH] power: add an API to log wakeup reasons

2014-03-10 Thread Ruchi Kandoi
Add API log_wakeup_reason() and expose it to userspace via sysfs path /sys/kernel/wakeup_reasons/last_resume_reason This is useful for power management diagnostic purposes. Signed-off-by: Ruchi Kandoi Signed-off-by: Greg Hackmann --- include/linux/wakeup_reason.h | 23 +++

[PATCH] power: add an API to log wakeup reasons

2014-03-10 Thread Ruchi Kandoi
Add API log_wakeup_reason() and expose it to userspace via sysfs path /sys/kernel/wakeup_reasons/last_resume_reason This is useful for power management diagnostic purposes. Signed-off-by: Ruchi Kandoi kandoiru...@google.com Signed-off-by: Greg Hackmann ghackm...@google.com ---