diff options
author | Vladimir Serbinenko <phcoder@gmail.com> | 2014-01-11 04:22:35 +0100 |
---|---|---|
committer | Vladimir Serbinenko <phcoder@gmail.com> | 2014-01-12 18:04:15 +0100 |
commit | eada34faaa19766ed9e1584130b1a99491f47487 (patch) | |
tree | 11c3105349822c6e8189d27cca409cccab5e0c1e /src/ec/lenovo/pmh7 | |
parent | 1eda31c0a754aa2973104f25a7f3c2a2b897b90a (diff) |
ec/lenovo/h8: Make trackpoint enable a CMOS option.
To be consistent with touchpad counterpart.
Change-Id: I72d09b41b964f80a81fbf409ef69dd368834a3e2
Signed-off-by: Vladimir Serbinenko <phcoder@gmail.com>
Reviewed-on: http://review.coreboot.org/4654
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
Diffstat (limited to 'src/ec/lenovo/pmh7')
-rw-r--r-- | src/ec/lenovo/pmh7/pmh7.c | 12 | ||||
-rw-r--r-- | src/ec/lenovo/pmh7/pmh7.h | 1 |
2 files changed, 13 insertions, 0 deletions
diff --git a/src/ec/lenovo/pmh7/pmh7.c b/src/ec/lenovo/pmh7/pmh7.c index 9607c83e52..a4d0ccc466 100644 --- a/src/ec/lenovo/pmh7/pmh7.c +++ b/src/ec/lenovo/pmh7/pmh7.c @@ -55,6 +55,14 @@ void pmh7_touchpad_enable(int onoff) pmh7_register_set_bit(0x51, 2); } +void pmh7_trackpoint_enable(int onoff) +{ + if (onoff) + pmh7_register_clear_bit(0x51, 0); + else + pmh7_register_set_bit(0x51, 0); +} + void pmh7_ultrabay_power_enable(int onoff) { if (onoff) @@ -116,6 +124,10 @@ static void enable_dev(device_t dev) if (get_option(&val, "touchpad") != CB_SUCCESS) val = 1; pmh7_touchpad_enable(val); + + if (get_option(&val, "trackpoint") != CB_SUCCESS) + val = 1; + pmh7_trackpoint_enable(val); } struct chip_operations ec_lenovo_pmh7_ops = { diff --git a/src/ec/lenovo/pmh7/pmh7.h b/src/ec/lenovo/pmh7/pmh7.h index 6e13b17965..4cd9535b7b 100644 --- a/src/ec/lenovo/pmh7/pmh7.h +++ b/src/ec/lenovo/pmh7/pmh7.h @@ -35,4 +35,5 @@ void pmh7_backlight_enable(int onoff); void pmh7_dock_event_enable(int onoff); void pmh7_touchpad_enable(int onoff); void pmh7_ultrabay_power_enable(int onoff); +void pmh7_trackpoint_enable(int onoff); #endif |