summaryrefslogtreecommitdiff
path: root/src/mainboard/google
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainboard/google')
-rw-r--r--src/mainboard/google/dedede/variants/baseboard/devicetree.cb4
-rw-r--r--src/mainboard/google/dedede/variants/cret/gpio.c15
-rw-r--r--src/mainboard/google/dedede/variants/cret/overridetree.cb8
3 files changed, 25 insertions, 2 deletions
diff --git a/src/mainboard/google/dedede/variants/baseboard/devicetree.cb b/src/mainboard/google/dedede/variants/baseboard/devicetree.cb
index f33995c66b..954e573f85 100644
--- a/src/mainboard/google/dedede/variants/baseboard/devicetree.cb
+++ b/src/mainboard/google/dedede/variants/baseboard/devicetree.cb
@@ -17,6 +17,10 @@ fw_config
option RT1015_I2C 2
option RT1015P_AUTO 3
end
+ field LTE 11
+ option LTE_ABSENT 0
+ option LTE_PRESENT 1
+ end
end
chip soc/intel/jasperlake
diff --git a/src/mainboard/google/dedede/variants/cret/gpio.c b/src/mainboard/google/dedede/variants/cret/gpio.c
index 3dd15efaa8..5acef69648 100644
--- a/src/mainboard/google/dedede/variants/cret/gpio.c
+++ b/src/mainboard/google/dedede/variants/cret/gpio.c
@@ -2,6 +2,8 @@
#include <baseboard/gpio.h>
#include <baseboard/variants.h>
+#include <bootstate.h>
+#include <fw_config.h>
/* Pad configuration in ramstage */
static const struct pad_config override_gpio_table[] = {
@@ -59,8 +61,21 @@ static const struct pad_config override_gpio_table[] = {
PAD_NC(GPP_G7, NONE),
};
+static const struct pad_config lte_disable_pads[] = {
+ PAD_NC(GPP_A10, NONE),
+ PAD_NC(GPP_D0, NONE),
+ PAD_NC(GPP_H17, NONE),
+};
+
const struct pad_config *variant_override_gpio_table(size_t *num)
{
*num = ARRAY_SIZE(override_gpio_table);
return override_gpio_table;
}
+
+static void fw_config_handle(void *unused)
+{
+ if (!fw_config_probe(FW_CONFIG(LTE, LTE_PRESENT)))
+ gpio_configure_pads(lte_disable_pads, ARRAY_SIZE(lte_disable_pads));
+}
+BOOT_STATE_INIT_ENTRY(BS_DEV_ENABLE, BS_ON_ENTRY, fw_config_handle, NULL);
diff --git a/src/mainboard/google/dedede/variants/cret/overridetree.cb b/src/mainboard/google/dedede/variants/cret/overridetree.cb
index 512a956f59..258632204b 100644
--- a/src/mainboard/google/dedede/variants/cret/overridetree.cb
+++ b/src/mainboard/google/dedede/variants/cret/overridetree.cb
@@ -57,7 +57,9 @@ chip soc/intel/jasperlake
chip drivers/usb/acpi
register "desc" = ""LTE""
register "type" = "UPC_TYPE_INTERNAL"
- device usb 2.3 on end
+ device usb 2.3 on
+ probe LTE LTE_PRESENT
+ end
end
chip drivers/usb/acpi
register "desc" = ""Camera (UFC)""
@@ -82,7 +84,9 @@ chip soc/intel/jasperlake
register "enable_gpio" =
"ACPI_GPIO_OUTPUT_ACTIVE_HIGH(GPP_A10)"
register "enable_delay_ms" = "20"
- device usb 3.3 on end
+ device usb 3.3 on
+ probe LTE LTE_PRESENT
+ end
end
end
end