drivers/soundwire/dmi-quirks.c

Source file repositories/reference/linux-study-clean/drivers/soundwire/dmi-quirks.c

File Facts

System
Linux kernel
Corpus path
drivers/soundwire/dmi-quirks.c
Extension
.c
Size
4013 bytes
Lines
191
Domain
Driver Families
Bucket
drivers/soundwire
Inferred role
Driver Families: implementation source
Status
source implementation candidate

Why This File Exists

Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.

Dependency Surface

Detected Declarations

Annotated Snippet

struct adr_remap {
	u64 adr;
	u64 remapped_adr;
};

/*
 * Some TigerLake devices based on an initial Intel BIOS do not expose
 * the correct _ADR in the DSDT.
 * Remap the bad _ADR values to the ones reported by hardware
 */
static const struct adr_remap intel_tgl_bios[] = {
	{
		0x000010025D070100ull,
		0x000020025D071100ull
	},
	{
		0x000110025d070100ull,
		0x000120025D130800ull
	},
	{}
};

/*
 * The initial version of the Dell SKU 0A3E did not expose the devices
 * on the correct links.
 */
static const struct adr_remap dell_sku_0A3E[] = {
	/* rt715 on link0 */
	{
		0x00020025d071100ull,
		0x00021025d071500ull
	},
	/* rt711 on link1 */
	{
		0x000120025d130800ull,
		0x000120025d071100ull,
	},
	/* rt1308 on link2 */
	{
		0x000220025d071500ull,
		0x000220025d130800ull
	},
	{}
};

/*
 * The HP Omen 16-k0005TX does not expose the correct version of RT711 on link0
 * and does not expose a RT1316 on link3
 */
static const struct adr_remap hp_omen_16[] = {
	/* rt711-sdca on link0 */
	{
		0x000020025d071100ull,
		0x000030025d071101ull
	},
	/* rt1316-sdca on link3 */
	{
		0x000120025d071100ull,
		0x000330025d131601ull
	},
	{}
};

/*
 * Intel NUC M15 LAPRC510 and LAPRC710
 */
static const struct adr_remap intel_rooks_county[] = {
	/* rt711-sdca on link0 */
	{
		0x000020025d071100ull,
		0x000030025d071101ull
	},
	/* rt1316-sdca on link2 */
	{
		0x000120025d071100ull,
		0x000230025d131601ull
	},
	{}
};

static const struct dmi_system_id adr_remap_quirk_table[] = {
	/* TGL devices */
	{
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "HP"),
			DMI_MATCH(DMI_PRODUCT_NAME, "HP Spectre x360 Conv"),
		},
		.driver_data = (void *)intel_tgl_bios,
	},
	{

Annotation

Implementation Notes