The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Rosen Penev <rosenp@gmail.com>
To: linux-sound@vger.kernel.org
Cc: Vijendar Mukunda <Vijendar.Mukunda@amd.com>,
	Venkata Prasad Potturu <venkataprasad.potturu@amd.com>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>, Jaroslav Kysela <perex@perex.cz>,
	Takashi Iwai <tiwai@suse.com>,
	linux-kernel@vger.kernel.org (open list)
Subject: [PATCH] ASoC: amd: acp: pass audio_drv_data to dma_irq_handler
Date: Mon, 10 Aug 2026 21:19:25 -0700	[thread overview]
Message-ID: <20260811041925.25016-1-rosenp@gmail.com> (raw)

The IRQ handler only needs the audio_drv_data, so pass it directly
as the request_irq argument instead of the device pointer and a
dev_get_drvdata() lookup.

Assisted-by: opencode:deepseek-v4-flash-free
Signed-off-by: Rosen Penev <rosenp@gmail.com>
---
 sound/soc/amd/acp-pcm-dma.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/sound/soc/amd/acp-pcm-dma.c b/sound/soc/amd/acp-pcm-dma.c
index e99588458ed8..60d5799c26f0 100644
--- a/sound/soc/amd/acp-pcm-dma.c
+++ b/sound/soc/amd/acp-pcm-dma.c
@@ -692,12 +692,10 @@ static irqreturn_t dma_irq_handler(int irq, void *arg)
 {
 	u16 dscr_idx;
 	u32 intr_flag, ext_intr_status;
-	struct audio_drv_data *irq_data;
+	struct audio_drv_data *irq_data = arg;
 	void __iomem *acp_mmio;
-	struct device *dev = arg;
 	bool valid_irq = false;
 
-	irq_data = dev_get_drvdata(dev);
 	acp_mmio = irq_data->acp_mmio;
 
 	ext_intr_status = acp_reg_read(acp_mmio, mmACP_EXTERNAL_INTR_STAT);
@@ -1295,7 +1293,7 @@ static int acp_audio_probe(struct platform_device *pdev)
 		return irq;
 
 	status = devm_request_irq(&pdev->dev, irq, dma_irq_handler,
-				  0, "ACP_IRQ", &pdev->dev);
+				  0, "ACP_IRQ", audio_drv_data);
 	if (status) {
 		dev_err(&pdev->dev, "ACP IRQ request failed\n");
 		return status;
-- 
2.55.0


                 reply	other threads:[~2026-08-11  4:19 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260811041925.25016-1-rosenp@gmail.com \
    --to=rosenp@gmail.com \
    --cc=Vijendar.Mukunda@amd.com \
    --cc=broonie@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=tiwai@suse.com \
    --cc=venkataprasad.potturu@amd.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox