diff options
author | Tri Vo <trong@android.com> | 2019-08-07 03:48:46 +0200 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2019-08-21 00:20:40 +0200 |
commit | c8377adfa78103be5380200eb9dab764d7ca890e (patch) | |
tree | 8d880a753b6a4ba98521dc5477229e18925195f5 /kernel/power/wakelock.c | |
parent | PM / wakeup: Use wakeup_source_register() in wakelock.c (diff) | |
download | linux-c8377adfa78103be5380200eb9dab764d7ca890e.tar.xz linux-c8377adfa78103be5380200eb9dab764d7ca890e.zip |
PM / wakeup: Show wakeup sources stats in sysfs
Add an ID and a device pointer to 'struct wakeup_source'. Use them to to
expose wakeup sources statistics in sysfs under
/sys/class/wakeup/wakeup<ID>/*.
Co-developed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Co-developed-by: Stephen Boyd <swboyd@chromium.org>
Signed-off-by: Stephen Boyd <swboyd@chromium.org>
Signed-off-by: Tri Vo <trong@android.com>
Tested-by: Kalesh Singh <kaleshsingh@google.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'kernel/power/wakelock.c')
-rw-r--r-- | kernel/power/wakelock.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/power/wakelock.c b/kernel/power/wakelock.c index d1eb7fd98b64..105df4dfc783 100644 --- a/kernel/power/wakelock.c +++ b/kernel/power/wakelock.c @@ -188,7 +188,7 @@ static struct wakelock *wakelock_lookup_add(const char *name, size_t len, return ERR_PTR(-ENOMEM); } - wl->ws = wakeup_source_register(wl->name); + wl->ws = wakeup_source_register(NULL, wl->name); if (!wl->ws) { kfree(wl->name); kfree(wl); |