diff options
Diffstat (limited to 'src/mainboard')
-rw-r--r-- | src/mainboard/google/rex/variants/rex0/overridetree.cb | 2 | ||||
-rw-r--r-- | src/mainboard/google/rex/variants/rex0/variant.c | 15 |
2 files changed, 17 insertions, 0 deletions
diff --git a/src/mainboard/google/rex/variants/rex0/overridetree.cb b/src/mainboard/google/rex/variants/rex0/overridetree.cb index bad123be54..d35eb36656 100644 --- a/src/mainboard/google/rex/variants/rex0/overridetree.cb +++ b/src/mainboard/google/rex/variants/rex0/overridetree.cb @@ -194,6 +194,8 @@ chip soc/intel/meteorlake chip drivers/usb/acpi register "desc" = ""USB2 Camera"" register "type" = "UPC_TYPE_INTERNAL" + register "has_power_resource" = "1" + register "enable_gpio" = "ACPI_GPIO_OUTPUT_ACTIVE_HIGH(GPP_B09)" device ref usb2_port6 on probe UFC UFC_USB end diff --git a/src/mainboard/google/rex/variants/rex0/variant.c b/src/mainboard/google/rex/variants/rex0/variant.c index 6a79780f6e..3aec24b165 100644 --- a/src/mainboard/google/rex/variants/rex0/variant.c +++ b/src/mainboard/google/rex/variants/rex0/variant.c @@ -1,8 +1,23 @@ /* SPDX-License-Identifier: GPL-2.0-only */ +#include <acpi/acpigen.h> +#include <baseboard/variants.h> +#include <fw_config.h> #include <sar.h> +#include <variant/gpio.h> const char *get_wifi_sar_cbfs_filename(void) { return "wifi_sar_0.hex"; } + +void variant_generate_s0ix_hook(enum s0ix_entry entry) +{ + if (entry == S0IX_ENTRY) { + if (fw_config_probe(FW_CONFIG(UFC, UFC_USB))) + acpigen_soc_clear_tx_gpio(GPP_B09); + } else if (entry == S0IX_EXIT) { + if (fw_config_probe(FW_CONFIG(UFC, UFC_USB))) + acpigen_soc_set_tx_gpio(GPP_B09); + } +} |