Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ALSA: hda: cs35l41: Save Subsystem ID inside CS35L41 Driver

The Subsystem ID is read from the HDA driver, and will
be used by the CS35L41 driver to be able to uniquely
identify the laptop, which is required to be able to
define firmware to be used by specific models.

Signed-off-by: Stefan Binding <sbinding@opensource.cirrus.com>
Signed-off-by: Vitaly Rodionov <vitalyr@opensource.cirrus.com>
Link: https://lore.kernel.org/r/20220630002335.366545-6-vitalyr@opensource.cirrus.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>

authored by

Stefan Binding and committed by
Takashi Iwai
e99f3c7e 2e81e1ff

+4
+3
sound/pci/hda/cs35l41_hda.c
··· 355 355 return -EBUSY; 356 356 357 357 comps->dev = dev; 358 + if (!cs35l41->acpi_subsystem_id) 359 + cs35l41->acpi_subsystem_id = devm_kasprintf(dev, GFP_KERNEL, "%.8x", 360 + comps->codec->core.subsystem_id); 358 361 cs35l41->codec = comps->codec; 359 362 strscpy(comps->name, dev_name(dev), sizeof(comps->name)); 360 363 comps->playback_hook = cs35l41_hda_playback_hook;
+1
sound/pci/hda/cs35l41_hda.h
··· 42 42 int channel_index; 43 43 unsigned volatile long irq_errors; 44 44 const char *amp_name; 45 + const char *acpi_subsystem_id; 45 46 struct mutex fw_mutex; 46 47 struct regmap_irq_chip_data *irq_data; 47 48 bool firmware_running;