sound/soc/amd/yc/acp6x-mach.c:573:15: error: implicit declaration of function 'acpi_evaluate_integer'; did you mean 'acpi_evaluate_object'?

kernel test robot
2025-01-08T19:36:29Z

Hi Venkata,

FYI, the error/warning still remains.

tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 09a0fa92e5b45e99cf435b2fbf5ebcf889cf8780
commit: 4095cf872084ecfdfdb0e681f3e9ff9745acfa75 ASoC: amd: yc: Fix for enabling DMIC on acp6x via _DSD entry
date: 6 weeks ago
config: x86_64-buildonly-randconfig-006-20250109 (https://download.01.org/0day-ci/archive/20250109/202501090345.pBIDRTym-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250109/202501090345.pBIDRTym-lkp@intel.com/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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202501090345.pBIDRTym-lkp@intel.com/

All errors (new ones prefixed by >>):

sound/soc/amd/yc/acp6x-mach.c: In function 'acp6x_probe':
>> sound/soc/amd/yc/acp6x-mach.c:573:15: error: implicit declaration of function 'acpi_evaluate_integer'; did you mean 'acpi_evaluate_object'? [-Werror=implicit-function-declaration]
573 | ret = acpi_evaluate_integer(handle, "_WOV", NULL, &dmic_status);
| ^~~~~~~~~~~~~~~~~~~~~
| acpi_evaluate_object
cc1: some warnings being treated as errors

vim +573 sound/soc/amd/yc/acp6x-mach.c

547
548 static int acp6x_probe(struct platform_device *pdev)
549 {
550 const struct dmi_system_id *dmi_id;
551 struct acp6x_pdm *machine = NULL;
552 struct snd_soc_card *card;
553 struct acpi_device *adev;
554 acpi_handle handle;
555 acpi_integer dmic_status;
556 int ret;
557 bool is_dmic_enable, wov_en;
558
559 /* IF WOV entry not found, enable dmic based on AcpDmicConnected entry*/
560 is_dmic_enable = false;
561 wov_en = true;
562 /* check the parent device's firmware node has _DSD or not */
563 adev = ACPI_COMPANION(pdev->dev.parent);
564 if (adev) {
565 const union acpi_object *obj;
566
567 if (!acpi_dev_get_property(adev, "AcpDmicConnected", ACPI_TYPE_INTEGER, &obj) &&
568 obj->integer.value == 1)
569 is_dmic_enable = true;
570 }
571
572 handle = ACPI_HANDLE(pdev->dev.parent);
> 573 ret = acpi_evaluate_integer(handle, "_WOV", NULL, &dmic_status);
574 if (!ACPI_FAILURE(ret))
575 wov_en = dmic_status;
576
577 if (is_dmic_enable && wov_en)
578 platform_set_drvdata(pdev, &acp6x_card);
579 else
580 return 0;
581
582 /* check for any DMI overrides */
583 dmi_id = dmi_first_match(yc_acp_quirk_table);
584 if (dmi_id)
585 platform_set_drvdata(pdev, dmi_id->driver_data);
586
587 card = platform_get_drvdata(pdev);
588 if (!card)
589 return -ENODEV;
590 dev_info(&pdev->dev, "Enabling ACP DMIC support via %s", dmi_id ? "DMI" : "ACPI");
591 acp6x_card.dev = &pdev->dev;
592
593 snd_soc_card_set_drvdata(card, machine);
594 ret = devm_snd_soc_register_card(&pdev->dev, card);
595 if (ret) {
596 return dev_err_probe(&pdev->dev, ret,
597 "snd_soc_register_card(%s) failed\n",
598 card->name);
599 }
600 return 0;
601 }
602

--
0-DAY CI Kernel Test Service