]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
ASoC: amd: ps: Propagate the PCI subsystem Vendor and Device IDs
authorSimon Trimmer <simont@opensource.cirrus.com>
Thu, 16 Oct 2025 15:06:48 +0000 (15:06 +0000)
committerMark Brown <broonie@kernel.org>
Mon, 20 Oct 2025 01:39:23 +0000 (02:39 +0100)
Extend the ACP machine driver to propagate the PCI subsystem Vendor and
Device IDs so that they may be subsequently used as an SSID.

Signed-off-by: Simon Trimmer <simont@opensource.cirrus.com>
Link: https://patch.msgid.link/20251016150649.320277-2-simont@opensource.cirrus.com
Reviewed-by: Mario Limonciello (AMD) <superm1@kernel.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/amd/ps/acp63.h
sound/soc/amd/ps/pci-ps.c

index 90fc016dac0b9821ad58c407637ba56703abbdaa..62cb6bef17ab98b2dd512b13f38056d19eb32740 100644 (file)
@@ -370,6 +370,8 @@ struct acp63_dev_data {
        u32 addr;
        u32 reg_range;
        u32 acp_rev;
+       u32 subsystem_vendor;
+       u32 subsystem_device;
        u32 acp_sw_pad_keeper_en;
        u32 acp_pad_pulldown_ctrl;
        u16 acp63_sdw0_dma_intr_stat[ACP63_SDW0_DMA_MAX_STREAMS];
index c62299b292041727f8eb19a58886bd7cc9581571..3a20cc10d61f503b5f529fd3dbdea6e3a343c627 100644 (file)
@@ -335,6 +335,12 @@ static struct snd_soc_acpi_mach *acp63_sdw_machine_select(struct device *dev)
                        mach->mach_params.links = mach->links;
                        mach->mach_params.link_mask = mach->link_mask;
                        mach->mach_params.subsystem_rev = acp_data->acp_rev;
+                       mach->mach_params.subsystem_vendor = acp_data->subsystem_vendor;
+                       mach->mach_params.subsystem_device = acp_data->subsystem_device;
+                       mach->mach_params.subsystem_id_set = true;
+
+                       dev_dbg(dev, "SSID %x%x\n", mach->mach_params.subsystem_vendor,
+                               mach->mach_params.subsystem_device);
                        return mach;
                }
        }
@@ -617,6 +623,9 @@ static int snd_acp63_probe(struct pci_dev *pci,
        adata->addr = addr;
        adata->reg_range = ACP63_REG_END - ACP63_REG_START;
        adata->acp_rev = pci->revision;
+       adata->subsystem_vendor = pci->subsystem_vendor;
+       adata->subsystem_device = pci->subsystem_device;
+
        pci_set_master(pci);
        pci_set_drvdata(pci, adata);
        mutex_init(&adata->acp_lock);