diff options
| author | Evan Wilson <evan@oliodevices.com> | 2016-04-04 21:25:52 -0700 |
|---|---|---|
| committer | Evan Wilson <evan@oliodevices.com> | 2016-04-04 21:25:52 -0700 |
| commit | 7622c71e8e291035b8be881889a3abeab7719fa7 (patch) | |
| tree | 4e58b5b817fd6cd2ed30ec8e32414d7df96fca87 | |
| parent | 8058cdb0df30c4dddfcfadc6516e87e4f9170626 (diff) | |
| download | olio-linux-3.10-7622c71e8e291035b8be881889a3abeab7719fa7.tar.xz olio-linux-3.10-7622c71e8e291035b8be881889a3abeab7719fa7.zip | |
Deny permission for the "bluetooth_timer" wake lock.
This wake lock is abused by our Bluetooth stack, so we don't want to allow it
Change-Id: Ia6d315ba877131f3323eb5ee615450397b057f2d
| -rw-r--r-- | kernel/power/wakelock.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/kernel/power/wakelock.c b/kernel/power/wakelock.c index ee83a3c5047..4fd55503e00 100644 --- a/kernel/power/wakelock.c +++ b/kernel/power/wakelock.c @@ -18,8 +18,11 @@ #include <linux/rbtree.h> #include <linux/slab.h> +#define BAD_WAKELOCK "bluetooth_timer" + static DEFINE_MUTEX(wakelocks_lock); + struct wakelock { char *name; struct rb_node node; @@ -194,6 +197,11 @@ int pm_wake_lock(const char *buf) printk ("OLIO %s error return 1, lock %s\n", __FUNCTION__, buf); return -EPERM; } +#elif 1 /* OLIO The bluetooth stack abuses this wake lock, so don't allow it to lock */ + if (strncmp(buf, BAD_WAKELOCK, strlen(BAD_WAKELOCK)) == 0) { + printk ("OLIO %s error return 1, lock %s\n", __FUNCTION__, buf); + return -EPERM; + } #endif while (*str && !isspace(*str)) |