summaryrefslogtreecommitdiff
path: root/src/ec/lenovo
diff options
context:
space:
mode:
Diffstat (limited to 'src/ec/lenovo')
-rw-r--r--src/ec/lenovo/h8/h8.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/ec/lenovo/h8/h8.c b/src/ec/lenovo/h8/h8.c
index f20cd389dc..ecd34b2fe7 100644
--- a/src/ec/lenovo/h8/h8.c
+++ b/src/ec/lenovo/h8/h8.c
@@ -27,6 +27,14 @@
#include "chip.h"
#include <pc80/mc146818rtc.h>
+static void h8_bluetooth_enable(int on)
+{
+ if (on)
+ ec_set_bit(0x3a, 4);
+ else
+ ec_clr_bit(0x3a, 4);
+}
+
void h8_trackpoint_enable(int on)
{
ec_write(H8_TRACKPOINT_CTRL,
@@ -143,6 +151,9 @@ static void h8_enable(device_t dev)
ec_write(H8_VOLUME_CONTROL, val);
+ if (!get_option(&val, "bluetooth"))
+ h8_bluetooth_enable(val);
+
if (!get_option(&val, "first_battery")) {
tmp = ec_read(H8_CONFIG3);
tmp &= ~(1 << 4);