drivers/soundwire/alc1308 : Add ALC1308 soundwire device

This patch adds new soundwire device ALC1308

The codec properties are filled out as best as possible
with the datasheet as a reference.

The ACPI address for the codec is calculated with the information in
the codec driver combined with the devicetree.cb hierarchy where the
link and unique IDs are extracted from the device path.

The unique ID is calculated from schematics by referring to ASEL[1:0]
strap settings. Datasheet of ALC1308 provides info about the mapping of
ASEL strap settings to unique ID

For example this device is connected to master link ID 1 and has strap
settings configuring it for unique ID 2.

chip drivers/soundwire/alc1308
  register "desc" = ""Left Speaker""
  device generic 1.2 on end
  end

Bug=None
Test=Build and boot on TGLRVP.Extract SSDT and confirm that the entries for
PCI0.HDAS.SNDW are present for ALC1308
Test speaker out functionality

Signed-off-by: Anil Kumar <anil.kumar.k@intel.com>
Change-Id: Ibf3f1d5c6881cbd106e96ad1ff17ca216aa272ac
Reviewed-on: https://review.coreboot.org/c/coreboot/+/51042
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
Reviewed-by: Sathyanarayana Nujella
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
Anil Kumar
2020-09-18 15:30:56 -07:00
committed by Patrick Georgi
parent 5f5ea02b3d
commit d7c31d1dbe
5 changed files with 166 additions and 0 deletions

View File

@@ -21,6 +21,7 @@
#define MIPI_MFG_ID_REALTEK 0x025d
#define MIPI_DEV_ID_REALTEK_ALC5682 0x5682
#define MIPI_DEV_ID_REALTEK_ALC711 0x0711
#define MIPI_DEV_ID_REALTEK_ALC1308 0x1308
#define MIPI_MFG_ID_MAXIM 0x019f
#define MIPI_DEV_ID_MAXIM_MAX98373 0x8373