Re: [PATCH 3/4] ASoC: SOF: amd: guard SDW IRQ work scheduling with interrupt_enabled flag

From: Mukunda,Vijendar

Date: Sat Nov 07 2026 - 23:11:09 EST


On 08/11/26 06:55, kernel test robot wrote:
> Hi Vijendar,
>
> kernel test robot noticed the following build errors:
>
> [auto build test ERROR on broonie-sound/for-next]
> [also build test ERROR on vkoul-dmaengine/next linus/master v7.4-rc1 next-20261105]
> [If your patch is applied to the wrong git tree, kindly drop us a note.
> And when submitting patch, we suggest to use '--base' as documented in
> https://git-scm.com/docs/git-format-patch#_base_tree_information]
>
> url: https://github.com/intel-lab-lkp/linux/commits/Vijendar-Mukunda/ASoC-amd-ps-guard-adata-sdw-dereferences-with-NULL-check-in-IRQ-handler/20261107-232226
> base: https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
> patch link: https://lore.kernel.org/r/20261107175339.3547918-4-Vijendar.Mukunda%40amd.com
> patch subject: [PATCH 3/4] ASoC: SOF: amd: guard SDW IRQ work scheduling with interrupt_enabled flag
> config: x86_64-rhel-9.4-ltp (https://download.01.org/0day-ci/archive/20261108/202611080910.HG54RIuC-lkp@xxxxxxxxx/config)
> compiler: gcc-14 (Debian 14.2.0-19) 14.2.0
> reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20261108/202611080910.HG54RIuC-lkp@xxxxxxxxx/reproduce)
>
> If you fix the issue in a separate patch/commit (i.e. not just a new version of
> the same patch/commit), kindly add following tags
> | Reported-by: kernel test robot <lkp@xxxxxxxxx>
> | Closes: https://lore.kernel.org/oe-kbuild-all/202611080910.HG54RIuC-lkp@xxxxxxxxx/
>
> All errors (new ones prefixed by >>):
>
> sound/soc/sof/amd/acp.c: In function 'acp_irq_handler':
>>> sound/soc/sof/amd/acp.c:589:55: error: 'struct amd_sdw_manager' has no member named 'interrupt_enabled'
As mentioned in cover letter, Patch 3/4 & 4/4 has dependency on below
patch which introduces the interrupt_enabled field in the AMD SoundWire manager:

https://lore.kernel.org/linux-sound/20261107154659.3358223-18-Vijendar.Mukunda@xxxxxxx/


> 589 | if (amd_manager && amd_manager->interrupt_enabled)
> | ^~
> sound/soc/sof/amd/acp.c:621:63: error: 'struct amd_sdw_manager' has no member named 'interrupt_enabled'
> 621 | if (amd_manager && amd_manager->interrupt_enabled)
> | ^~
>
>
> vim +589 sound/soc/sof/amd/acp.c
>
> 566
> 567 static irqreturn_t acp_irq_handler(int irq, void *dev_id)
> 568 {
> 569 struct amd_sdw_manager *amd_manager;
> 570 struct snd_sof_dev *sdev = dev_id;
> 571 const struct sof_amd_acp_desc *desc = get_chip_info(sdev->pdata);
> 572 struct acp_dev_data *adata = sdev->pdata->hw_pdata;
> 573 unsigned int base = desc->dsp_intr_base;
> 574 unsigned int val;
> 575 int irq_flag = 0, wake_irq_flag = 0;
> 576
> 577 val = snd_sof_dsp_read(sdev, ACP_DSP_BAR, base + DSP_SW_INTR_STAT_OFFSET);
> 578 if (val & ACP_DSP_TO_HOST_IRQ) {
> 579 snd_sof_dsp_write(sdev, ACP_DSP_BAR, base + DSP_SW_INTR_STAT_OFFSET,
> 580 ACP_DSP_TO_HOST_IRQ);
> 581 return IRQ_WAKE_THREAD;
> 582 }
> 583
> 584 val = snd_sof_dsp_read(sdev, ACP_DSP_BAR, desc->ext_intr_stat);
> 585 if (val & ACP_SDW0_IRQ_MASK) {
> 586 snd_sof_dsp_write(sdev, ACP_DSP_BAR, desc->ext_intr_stat, ACP_SDW0_IRQ_MASK);
> 587 if (adata->sdw) {
> 588 amd_manager = dev_get_drvdata(&adata->sdw->pdev[0]->dev);
> > 589 if (amd_manager && amd_manager->interrupt_enabled)
> 590 schedule_work(&amd_manager->amd_sdw_irq_thread);
> 591 }
> 592 irq_flag = 1;
> 593 }
> 594
> 595 if (val & ACP_ERROR_IRQ_MASK) {
> 596 snd_sof_dsp_write(sdev, ACP_DSP_BAR, desc->ext_intr_stat, ACP_ERROR_IRQ_MASK);
> 597 snd_sof_dsp_write(sdev, ACP_DSP_BAR, desc->acp_sw0_i2s_err_reason, 0);
> 598 /* ACP_SW1_I2S_ERROR_REASON is newly added register from rmb platform onwards */
> 599 switch (adata->pci_rev) {
> 600 case ACP_RMB_PCI_ID:
> 601 case ACP63_PCI_ID:
> 602 case ACP70_PCI_ID:
> 603 case ACP71_PCI_ID:
> 604 case ACP72_PCI_ID:
> 605 snd_sof_dsp_write(sdev, ACP_DSP_BAR, ACP_SW1_I2S_ERROR_REASON, 0);
> 606 break;
> 607 default:
> 608 break;
> 609 }
> 610 snd_sof_dsp_write(sdev, ACP_DSP_BAR, desc->acp_error_stat, 0);
> 611 irq_flag = 1;
> 612 }
> 613
> 614 if (desc->ext_intr_stat1) {
> 615 val = snd_sof_dsp_read(sdev, ACP_DSP_BAR, desc->ext_intr_stat1);
> 616 if (val & ACP_SDW1_IRQ_MASK) {
> 617 snd_sof_dsp_write(sdev, ACP_DSP_BAR, desc->ext_intr_stat1,
> 618 ACP_SDW1_IRQ_MASK);
> 619 if (adata->sdw) {
> 620 amd_manager = dev_get_drvdata(&adata->sdw->pdev[1]->dev);
> 621 if (amd_manager && amd_manager->interrupt_enabled)
> 622 schedule_work(&amd_manager->amd_sdw_irq_thread);
> 623 }
> 624 irq_flag = 1;
> 625 }
> 626 switch (adata->pci_rev) {
> 627 case ACP70_PCI_ID:
> 628 case ACP71_PCI_ID:
> 629 case ACP72_PCI_ID:
> 630 wake_irq_flag = amd_sof_check_and_handle_acp70_sdw_wake_irq(sdev);
> 631 break;
> 632 }
> 633 }
> 634 if (irq_flag || wake_irq_flag)
> 635 return IRQ_HANDLED;
> 636 else
> 637 return IRQ_NONE;
> 638 }
> 639
>
> --
> 0-DAY CI Kernel Test Service
> https://github.com/intel/lkp-tests/wiki