summaryrefslogtreecommitdiff
path: root/src/mainboard/google
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainboard/google')
-rw-r--r--src/mainboard/google/brya/Kconfig2
-rw-r--r--src/mainboard/google/brya/variants/brya0/fw_config.c16
-rw-r--r--src/mainboard/google/brya/variants/brya0/overridetree.cb30
3 files changed, 45 insertions, 3 deletions
diff --git a/src/mainboard/google/brya/Kconfig b/src/mainboard/google/brya/Kconfig
index ee1c9b3d4c..946dad34a5 100644
--- a/src/mainboard/google/brya/Kconfig
+++ b/src/mainboard/google/brya/Kconfig
@@ -11,9 +11,11 @@ if BOARD_GOOGLE_BASEBOARD_BRYA || BOARD_GOOGLE_BASEBOARD_BRASK
config BOARD_GOOGLE_BRYA_COMMON
def_bool y
select BOARD_ROMSIZE_KB_32768
+ select DRIVERS_GENERIC_ALC1015
select DRIVERS_GENERIC_MAX98357A
select DRIVERS_I2C_GENERIC
select DRIVERS_I2C_HID
+ select DRIVERS_I2C_NAU8825
select DRIVERS_I2C_SX9324
select DRIVERS_INTEL_DPTF
select DRIVERS_INTEL_PMC
diff --git a/src/mainboard/google/brya/variants/brya0/fw_config.c b/src/mainboard/google/brya/variants/brya0/fw_config.c
index 11cd684c2e..97b460f6a7 100644
--- a/src/mainboard/google/brya/variants/brya0/fw_config.c
+++ b/src/mainboard/google/brya/variants/brya0/fw_config.c
@@ -77,6 +77,13 @@ static const struct pad_config bt_i2s_disable_pads[] = {
PAD_NC(GPP_VGPIO_37, NONE),
};
+static void enable_i2s(void)
+{
+ gpio_configure_pads(dmic_enable_pads, ARRAY_SIZE(dmic_enable_pads));
+ gpio_configure_pads(i2s_enable_pads, ARRAY_SIZE(i2s_enable_pads));
+ gpio_configure_pads(sndw_disable_pads, ARRAY_SIZE(sndw_disable_pads));
+}
+
static void fw_config_handle(void *unused)
{
if (!fw_config_is_provisioned() || fw_config_probe(FW_CONFIG(AUDIO, AUDIO_UNKNOWN))) {
@@ -102,9 +109,12 @@ static void fw_config_handle(void *unused)
if (fw_config_probe(FW_CONFIG(AUDIO, MAX98357_ALC5682I_I2S))) {
printk(BIOS_INFO, "Configure audio over I2S with MAX98357 ALC5682I.\n");
- gpio_configure_pads(dmic_enable_pads, ARRAY_SIZE(dmic_enable_pads));
- gpio_configure_pads(i2s_enable_pads, ARRAY_SIZE(i2s_enable_pads));
- gpio_configure_pads(sndw_disable_pads, ARRAY_SIZE(sndw_disable_pads));
+ enable_i2s();
+ }
+
+ if (fw_config_probe(FW_CONFIG(AUDIO, ALC1019_NAU88L25B_I2S))) {
+ printk(BIOS_INFO, "Configure audio over I2S with ALC1019 NAU88L25B.\n");
+ enable_i2s();
}
}
BOOT_STATE_INIT_ENTRY(BS_DEV_ENABLE, BS_ON_ENTRY, fw_config_handle, NULL);
diff --git a/src/mainboard/google/brya/variants/brya0/overridetree.cb b/src/mainboard/google/brya/variants/brya0/overridetree.cb
index 1f78b38267..f053eb6a70 100644
--- a/src/mainboard/google/brya/variants/brya0/overridetree.cb
+++ b/src/mainboard/google/brya/variants/brya0/overridetree.cb
@@ -200,6 +200,36 @@ chip soc/intel/alderlake
probe AUDIO MAX98357_ALC5682I_I2S
end
end
+ chip drivers/i2c/nau8825
+ register "irq_gpio" = "ACPI_GPIO_IRQ_LEVEL_LOW(GPP_A23)"
+ register "jkdet_enable" = "1"
+ register "jkdet_pull_enable" = "0"
+ register "jkdet_polarity" = "1" # ActiveLow
+ register "vref_impedance" = "2" # 125kOhm
+ register "micbias_voltage" = "6" # 2.754
+ register "sar_threshold_num" = "4"
+ register "sar_threshold[0]" = "0x0c"
+ register "sar_threshold[1]" = "0x1c"
+ register "sar_threshold[2]" = "0x38"
+ register "sar_threshold[3]" = "0x60"
+ register "sar_hysteresis" = "1"
+ register "sar_voltage" = "0" # VDDA
+ register "sar_compare_time" = "0" # 500ns
+ register "sar_sampling_time" = "0" # 2us
+ register "short_key_debounce" = "2" # 100ms
+ register "jack_insert_debounce" = "7" # 512ms
+ register "jack_eject_debounce" = "7" # 512ms
+ device i2c 1a on
+ probe AUDIO ALC1019_NAU88L25B_I2S
+ end
+ end
+ chip drivers/generic/alc1015
+ register "hid" = ""RTL1019""
+ register "sdb" = "ACPI_GPIO_OUTPUT_ACTIVE_HIGH(GPP_A11)"
+ device generic 1 on
+ probe AUDIO ALC1019_NAU88L25B_I2S
+ end
+ end
chip drivers/intel/mipi_camera
register "acpi_hid" = ""OVTI8856""
register "acpi_uid" = "0"