Message ID | 20250213103652.1082203-1-Vijendar.Mukunda@amd.com (mailing list archive) |
---|---|
State | Accepted |
Commit | 828c0aa63706410503526d0ee522b9ac3232c86b |
Headers | show |
Series | ASoC: amd: ps: use switch statements for acp pci revision id check | expand |
On Thu, 13 Feb 2025 16:06:52 +0530, Vijendar Mukunda wrote: > Use switch statements for acp pci revision id check in SoundWire > dma irq handling. > > Applied to https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next Thanks! [1/1] ASoC: amd: ps: use switch statements for acp pci revision id check commit: 828c0aa63706410503526d0ee522b9ac3232c86b All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark
diff --git a/sound/soc/amd/ps/pci-ps.c b/sound/soc/amd/ps/pci-ps.c index 220dca8cba85..2ff8e67c19bd 100644 --- a/sound/soc/amd/ps/pci-ps.c +++ b/sound/soc/amd/ps/pci-ps.c @@ -111,16 +111,21 @@ static short int check_and_handle_sdw_dma_irq(struct acp63_dev_data *adata, u32 stream_id = ACP63_SDW0_AUDIO2_RX; break; } - if (adata->acp_rev >= ACP70_PCI_REV) - adata->acp70_sdw0_dma_intr_stat[stream_id] = 1; - else + switch (adata->acp_rev) { + case ACP63_PCI_REV: adata->acp63_sdw0_dma_intr_stat[stream_id] = 1; - + break; + case ACP70_PCI_REV: + case ACP71_PCI_REV: + adata->acp70_sdw0_dma_intr_stat[stream_id] = 1; + break; + } sdw_dma_irq_flag = 1; } } } - if (adata->acp_rev == ACP63_PCI_REV) { + switch (adata->acp_rev) { + case ACP63_PCI_REV: if (ext_intr_stat1 & ACP63_P1_AUDIO1_RX_THRESHOLD) { writel(ACP63_P1_AUDIO1_RX_THRESHOLD, adata->acp63_base + ACP_EXTERNAL_INTR_STAT1); @@ -133,7 +138,9 @@ static short int check_and_handle_sdw_dma_irq(struct acp63_dev_data *adata, u32 adata->acp63_sdw1_dma_intr_stat[ACP63_SDW1_AUDIO1_TX] = 1; sdw_dma_irq_flag = 1; } - } else { + break; + case ACP70_PCI_REV: + case ACP71_PCI_REV: if (ext_intr_stat1 & ACP70_P1_SDW_DMA_IRQ_MASK) { for (index = ACP70_P1_AUDIO2_RX_THRESHOLD; index <= ACP70_P1_AUDIO0_TX_THRESHOLD; index++) { @@ -166,6 +173,7 @@ static short int check_and_handle_sdw_dma_irq(struct acp63_dev_data *adata, u32 } } } + break; } return sdw_dma_irq_flag; }
Use switch statements for acp pci revision id check in SoundWire dma irq handling. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> --- sound/soc/amd/ps/pci-ps.c | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-)