mb/google/nissa/var/uldren: Add fw_config probe for lte

Use fw_config to probe lte.

BUG=b:283199751
BRANCH=firmware-nissa-15217.B
TEST=emerge-nissa coreboot chromeos-bootimage

Change-Id: I5596f3536b0a21453f89e67615acabbbf6a8409b
Signed-off-by: Dtrain Hsu <dtrain_hsu@compal.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/75337
Reviewed-by: Derek Huang <derekhuang@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
Dtrain Hsu 2023-05-18 17:34:56 +08:00 committed by Felix Held
parent 9be583e65d
commit 764167b8ca
2 changed files with 24 additions and 2 deletions

View File

@ -1,4 +1,8 @@
fw_config
field DB_LTE 1 1
option LTE_ABSENT 0
option LTE_PRESENT 1
end
field TOUCHPAD 8 9
option TOUCHPAD_UNKNOWN 0
option TOUCHPAD_EKT3744 1
@ -377,7 +381,9 @@ chip soc/intel/alderlake
chip drivers/usb/acpi
register "desc" = ""USB2 WWAN""
register "type" = "UPC_TYPE_INTERNAL"
device ref usb2_port4 on end
device ref usb2_port4 on
probe DB_LTE LTE_PRESENT
end
end
chip drivers/usb/acpi
register "desc" = ""USB2 User Facing Camera""
@ -405,7 +411,9 @@ chip soc/intel/alderlake
chip drivers/usb/acpi
register "desc" = ""USB3 WWAN""
register "type" = "UPC_TYPE_INTERNAL"
device ref usb3_port2 on end
device ref usb3_port2 on
probe DB_LTE LTE_PRESENT
end
end
end
end

View File

@ -16,6 +16,15 @@ static const struct pad_config touchscreen_disable_pads[] = {
PAD_NC(GPP_H7, NONE),
};
static const struct pad_config lte_disable_pads[] = {
/* A8 : WWAN_RF_DISABLE_ODL */
PAD_NC(GPP_A8, NONE),
/* D6 : SRCCLKREQ1# ==> WWAN_EN */
PAD_NC(GPP_D6, NONE),
/* F12 : WWAN_RST_L */
PAD_NC_LOCK(GPP_F12, NONE, LOCK_CONFIG),
};
const char *get_wifi_sar_cbfs_filename(void)
{
return "wifi_sar_0.hex";
@ -28,4 +37,9 @@ void fw_config_gpio_padbased_override(struct pad_config *padbased_table)
gpio_padbased_override(padbased_table, touchscreen_disable_pads,
ARRAY_SIZE(touchscreen_disable_pads));
}
if (fw_config_probe(FW_CONFIG(DB_LTE, LTE_ABSENT))) {
printk(BIOS_INFO, "Disable LTE GPIO pins.\n");
gpio_padbased_override(padbased_table, lte_disable_pads,
ARRAY_SIZE(lte_disable_pads));
}
}