diff options
author | Naveen Manohar <naveen.m@intel.com> | 2018-05-10 08:54:14 +0530 |
---|---|---|
committer | Martin Roth <martinroth@google.com> | 2018-06-01 16:25:13 +0000 |
commit | e098c8a59346df4c7a17ec7aec04bcf4e3bf1f61 (patch) | |
tree | e4f426e83b83b03d59afdb9f06be840fdd1c4ce7 /src/mainboard/google/octopus/variants/baseboard | |
parent | 39130a4f1ee66fcb6c9acf4c3cf7488e50a2271c (diff) | |
download | coreboot-e098c8a59346df4c7a17ec7aec04bcf4e3bf1f61.tar.gz coreboot-e098c8a59346df4c7a17ec7aec04bcf4e3bf1f61.tar.bz2 coreboot-e098c8a59346df4c7a17ec7aec04bcf4e3bf1f61.zip |
mb/google/octopus: Enable RT5682 headset codec for BIP board
Patch adds required changes for RT5682 codec enablement for the BIP board.
And code clean-up nhlt blob selection method in config.
BUG=b:77892150
TEST=build and boot on a BIP PO board.
verify headset codec i2cdetects at address 1a.
Change-Id: Iee91518c03a0e9e6ed52bc54a60fc607730a0b7d
Signed-off-by: Naveen Manohar <naveen.m@intel.com>
Reviewed-on: https://review.coreboot.org/26211
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-by: Furquan Shaikh <furquan@google.com>
Diffstat (limited to 'src/mainboard/google/octopus/variants/baseboard')
-rw-r--r-- | src/mainboard/google/octopus/variants/baseboard/nhlt.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/mainboard/google/octopus/variants/baseboard/nhlt.c b/src/mainboard/google/octopus/variants/baseboard/nhlt.c index 94403a8c35b9..b71aadf9d03e 100644 --- a/src/mainboard/google/octopus/variants/baseboard/nhlt.c +++ b/src/mainboard/google/octopus/variants/baseboard/nhlt.c @@ -29,12 +29,21 @@ void __weak variant_nhlt_init(struct nhlt *nhlt) if (!nhlt_soc_add_dmic_array(nhlt, 4)) printk(BIOS_ERR, "Added 4CH DMIC arrays.\n"); - /* Dialog for Headset codec. + /* * Headset codec is bi-directional but uses the same configuration * settings for render and capture endpoints. */ - if (!nhlt_soc_add_da7219(nhlt, AUDIO_LINK_SSP2)) - printk(BIOS_ERR, "Added Dialog_7219 codec.\n"); + if (IS_ENABLED(CONFIG_NHLT_DA7219)) { + /* Dialog for Headset codec */ + if (!nhlt_soc_add_da7219(nhlt, AUDIO_LINK_SSP2)) + printk(BIOS_ERR, "Added Dialog_7219 codec.\n"); + } + + if (IS_ENABLED(CONFIG_NHLT_RT5682)) { + /* Realtek for Headset codec */ + if (!nhlt_soc_add_rt5682(nhlt, AUDIO_LINK_SSP2)) + printk(BIOS_ERR, "Added ALC5682 codec.\n"); + } /* MAXIM Smart Amps for left and right speakers. */ if (!nhlt_soc_add_max98357(nhlt, AUDIO_LINK_SSP1)) |