lenovo/h8: Support uwb radio.
It's the third minipcie slot in x200. Change-Id: Ibfa8d787698cd23b4abcffe5cff2d62039cf0f86 Signed-off-by: Vladimir Serbinenko <phcoder@gmail.com> Reviewed-on: http://review.coreboot.org/6641 Tested-by: build bot (Jenkins) Reviewed-by: Edward O'Callaghan <eocallaghan@alterapraxis.com> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
This commit is contained in:
parent
020dc0e13c
commit
883e7acc65
|
@ -49,6 +49,7 @@ struct ec_lenovo_h8_config {
|
|||
|
||||
u8 has_keyboard_backlight;
|
||||
u8 has_power_management_beeps;
|
||||
u8 has_uwb;
|
||||
};
|
||||
|
||||
#endif /* EC_LENOVO_H8EC_CHIP_H */
|
||||
|
|
|
@ -63,6 +63,15 @@ static void h8_wwan_enable(int on)
|
|||
ec_clr_bit(0x3a, 6);
|
||||
}
|
||||
|
||||
/* Controls radio-off pin in UWB MiniPCIe slot. */
|
||||
static void h8_uwb_enable(int on)
|
||||
{
|
||||
if (on)
|
||||
ec_set_bit(0x31, 2);
|
||||
else
|
||||
ec_clr_bit(0x31, 2);
|
||||
}
|
||||
|
||||
static void h8_fn_ctrl_swap(int on)
|
||||
{
|
||||
if (on)
|
||||
|
@ -239,6 +248,13 @@ static void h8_enable(device_t dev)
|
|||
|
||||
h8_wwan_enable(val);
|
||||
|
||||
if (conf->has_uwb) {
|
||||
if (get_option(&val, "uwb") != CB_SUCCESS)
|
||||
val = 1;
|
||||
|
||||
h8_uwb_enable(val);
|
||||
}
|
||||
|
||||
if (get_option(&val, "fn_ctrl_swap") != CB_SUCCESS)
|
||||
val = 0;
|
||||
h8_fn_ctrl_swap(val);
|
||||
|
|
Loading…
Reference in New Issue