summaryrefslogtreecommitdiff
path: root/src/mainboard/google
diff options
context:
space:
mode:
authorDaniel_Peng <Daniel_Peng@pegatron.corp-partner.google.com>2024-10-07 11:50:26 +0800
committerEric Lai <ericllai@google.com>2024-10-09 02:00:34 +0000
commit0c0f5499b30af1f2df05af0317247171b6893f4c (patch)
tree475f8d56935a1ea1bc4f4e3fb428e71853244036 /src/mainboard/google
parent073a713ace56a0b8ae09b223b74bbb8cdeaabfdd (diff)
mb/google/brya/var/glassway: Add WFC Function
1.Add WFC fw_config setting. 2.Used USB2 Port7 for WFC. BUG=b:365184481 BRANCH=firmware-nissa-15217.B TEST=emerge-nissa coreboot Change-Id: Ie5dcf5ed8f72a4bdf4c2c7fc63bf94dc7b869eef Signed-off-by: Daniel_Peng <Daniel_Peng@pegatron.corp-partner.google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/84685 Reviewed-by: Eric Lai <ericllai@google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Subrata Banik <subratabanik@google.com>
Diffstat (limited to 'src/mainboard/google')
-rw-r--r--src/mainboard/google/brya/variants/glassway/overridetree.cb11
-rw-r--r--src/mainboard/google/brya/variants/glassway/variant.c13
2 files changed, 22 insertions, 2 deletions
diff --git a/src/mainboard/google/brya/variants/glassway/overridetree.cb b/src/mainboard/google/brya/variants/glassway/overridetree.cb
index 69d4e89e9f..9e0f742f03 100644
--- a/src/mainboard/google/brya/variants/glassway/overridetree.cb
+++ b/src/mainboard/google/brya/variants/glassway/overridetree.cb
@@ -21,6 +21,10 @@ fw_config
option WIFI_SAR_ID_0 0
option WIFI_SAR_ID_1 1
end
+ field WFC 16 17
+ option WFC_ABSENT 0
+ option WFC_PRESENT 1
+ end
field TOUCHSCREEN_SOURCE 32 33
option TOUCHSCREEN_UNPROVISIONED 0
option TOUCHSCREEN_ELAN0001 1
@@ -88,6 +92,7 @@ chip soc/intel/alderlake
register "typec_aux_bias_pads[0]" = "{.pad_auxp_dc = GPP_E22, .pad_auxn_dc = GPP_E23}"
register "typec_aux_bias_pads[1]" = "{.pad_auxp_dc = GPP_A21, .pad_auxn_dc = GPP_A22}"
+ register "usb2_ports[6]" = "USB2_PORT_MID(OC_SKIP)" # WFC
register "usb2_ports[9]" = "USB2_PORT_MID(OC_SKIP)" # Bluetooth port for CNVi WLAN
# Configure external V1P05/Vnn/VnnSx Rails
@@ -541,9 +546,11 @@ chip soc/intel/alderlake
device ref usb2_port6 on end
end
chip drivers/usb/acpi
- register "desc" = ""USB2 Camera""
+ register "desc" = ""USB2 WFC""
register "type" = "UPC_TYPE_INTERNAL"
- device ref usb2_port7 on end
+ device ref usb2_port7 on
+ probe WFC WFC_PRESENT
+ end
end
chip drivers/usb/acpi
register "desc" = ""USB2 Bluetooth""
diff --git a/src/mainboard/google/brya/variants/glassway/variant.c b/src/mainboard/google/brya/variants/glassway/variant.c
index 906d9aa0e4..2a4d4f112a 100644
--- a/src/mainboard/google/brya/variants/glassway/variant.c
+++ b/src/mainboard/google/brya/variants/glassway/variant.c
@@ -9,3 +9,16 @@ const char *get_wifi_sar_cbfs_filename(void)
{
return get_wifi_sar_fw_config_filename(FW_CONFIG_FIELD(WIFI_SAR_ID));
}
+
+void variant_update_soc_chip_config(struct soc_intel_alderlake_config *config)
+{
+ if (!fw_config_probe(FW_CONFIG(WFC, WFC_PRESENT))) {
+ printk(BIOS_INFO, "Disable usb2_port7 of WFC.\n");
+ config->usb2_ports[6].enable = 0;
+ config->usb2_ports[6].ocpin = OC_SKIP;
+ config->usb2_ports[6].tx_bias = USB2_BIAS_0MV;
+ config->usb2_ports[6].tx_emp_enable = USB2_EMP_OFF;
+ config->usb2_ports[6].pre_emp_bias = USB2_BIAS_0MV;
+ config->usb2_ports[6].pre_emp_bit = USB2_HALF_BIT_PRE_EMP;
+ }
+}