summaryrefslogtreecommitdiff
path: root/src/ec
diff options
context:
space:
mode:
Diffstat (limited to 'src/ec')
-rw-r--r--src/ec/lenovo/h8/h8.c6
-rw-r--r--src/ec/lenovo/pmh7/pmh7.c2
2 files changed, 4 insertions, 4 deletions
diff --git a/src/ec/lenovo/h8/h8.c b/src/ec/lenovo/h8/h8.c
index 0d1a32dce4..5f7060dcd6 100644
--- a/src/ec/lenovo/h8/h8.c
+++ b/src/ec/lenovo/h8/h8.c
@@ -172,14 +172,14 @@ static void h8_enable(device_t dev)
h8_trackpoint_enable(conf->trackpoint_enable);
h8_usb_power_enable(1);
- if (!get_option(&val, "volume"))
+ if (get_option(&val, "volume") == CB_SUCCESS)
ec_write(H8_VOLUME_CONTROL, val);
- if (!get_option(&val, "bluetooth"))
+ if (get_option(&val, "bluetooth") == CB_SUCCESS)
h8_bluetooth_enable(val);
- if (!get_option(&val, "first_battery")) {
+ if (get_option(&val, "first_battery") == CB_SUCCESS) {
tmp = ec_read(H8_CONFIG3);
tmp &= ~(1 << 4);
tmp |= (val & 1)<< 4;
diff --git a/src/ec/lenovo/pmh7/pmh7.c b/src/ec/lenovo/pmh7/pmh7.c
index 7bbe471979..b02b52aa8e 100644
--- a/src/ec/lenovo/pmh7/pmh7.c
+++ b/src/ec/lenovo/pmh7/pmh7.c
@@ -113,7 +113,7 @@ static void enable_dev(device_t dev)
pmh7_backlight_enable(conf->backlight_enable);
pmh7_dock_event_enable(conf->dock_event_enable);
- if (!get_option(&val, "touchpad"))
+ if (get_option(&val, "touchpad") == CB_SUCCESS)
pmh7_touchpad_enable(val);
}