diff options
author | Leo Yan <leo.yan@linaro.org> | 2017-12-14 11:24:02 +0800 |
---|---|---|
committer | Leo Yan <leo.yan@linaro.org> | 2017-12-15 01:55:25 +0000 |
commit | 0bf3fb265c00a4defc632dc8c1c3951fb0bcd2c4 (patch) | |
tree | 03145ddb9819e2f7870e2c4eb03af83234e6aa7a | |
parent | 488123633fa6d1c0074459d6c80943ecca7e7257 (diff) | |
download | hikey-0bf3fb265c00a4defc632dc8c1c3951fb0bcd2c4.tar.gz |
powerHAL: Hikey: Fix compilation warning
It's reporting the compilation warning as below:
device/linaro/hikey/power/power_hikey.c:447:32: warning: unused variable 'hikey' [-Wunused-variable]
struct hikey_power_module *hikey = container_of(module,
This commit removes unused variable 'hikey' and add mark '__unused' for
parameter 'module'to dismiss the compilation warning.
Change-Id: I86ca979278dde7c959e9dc398def5078c8a59c5c
Signed-off-by: Leo Yan <leo.yan@linaro.org>
-rw-r--r-- | power/power_hikey.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/power/power_hikey.c b/power/power_hikey.c index 2bcd2963..34264d8a 100644 --- a/power/power_hikey.c +++ b/power/power_hikey.c @@ -442,10 +442,9 @@ static void hikey_power_hint(struct power_module *module, power_hint_t hint, pthread_mutex_unlock(&hikey->lock); } -static void set_feature(struct power_module *module, feature_t feature, int state) +static void set_feature(struct power_module __unused *module, + feature_t feature, int state) { - struct hikey_power_module *hikey = container_of(module, - struct hikey_power_module, base); switch (feature) { default: ALOGW("Error setting the feature %d and state %d, it doesn't exist\n", |