All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Syed Saba Kareem <Syed.SabaKareem@amd.com>
Cc: oe-kbuild-all@lists.linux.dev, Mark Brown <broonie@kernel.org>
Subject: [broonie-sound:for-next 45/75] sound/soc/amd/acp/acp-legacy-common.c:392:17: warning: assignment to 'struct acpi_device *' from 'int' makes pointer from integer without a cast
Date: Fri, 27 Oct 2023 13:11:50 +0800	[thread overview]
Message-ID: <202310271326.7xKHbFDH-lkp@intel.com> (raw)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
head:   00236a89602f7b67016bd1d9bc63079f2c0f0a8d
commit: 3a94c8ad0aae2b14a55059869871ea2d199af489 [45/75] ASoC: amd: acp: add code for scanning acp pdm controller
config: i386-buildonly-randconfig-001-20231027 (https://download.01.org/0day-ci/archive/20231027/202310271326.7xKHbFDH-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/20231027/202310271326.7xKHbFDH-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/202310271326.7xKHbFDH-lkp@intel.com/

All warnings (new ones prefixed by >>):

   sound/soc/amd/acp/acp-legacy-common.c: In function 'check_acp_pdm':
   sound/soc/amd/acp/acp-legacy-common.c:392:19: error: implicit declaration of function 'acpi_find_child_device'; did you mean 'acpi_match_device'? [-Werror=implicit-function-declaration]
     392 |         pdm_dev = acpi_find_child_device(ACPI_COMPANION(&pci->dev), pdm_addr, 0);
         |                   ^~~~~~~~~~~~~~~~~~~~~~
         |                   acpi_match_device
>> sound/soc/amd/acp/acp-legacy-common.c:392:17: warning: assignment to 'struct acpi_device *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
     392 |         pdm_dev = acpi_find_child_device(ACPI_COMPANION(&pci->dev), pdm_addr, 0);
         |                 ^
   cc1: some warnings being treated as errors


vim +392 sound/soc/amd/acp/acp-legacy-common.c

   354	
   355	int check_acp_pdm(struct pci_dev *pci, struct acp_chip_info *chip)
   356	{
   357		struct acpi_device *pdm_dev;
   358		const union acpi_object *obj;
   359		u32 pdm_addr, val;
   360	
   361		val = readl(chip->base + ACP_PIN_CONFIG);
   362		switch (val) {
   363		case ACP_CONFIG_4:
   364		case ACP_CONFIG_5:
   365		case ACP_CONFIG_6:
   366		case ACP_CONFIG_7:
   367		case ACP_CONFIG_8:
   368		case ACP_CONFIG_10:
   369		case ACP_CONFIG_11:
   370		case ACP_CONFIG_12:
   371		case ACP_CONFIG_13:
   372		case ACP_CONFIG_14:
   373			break;
   374		default:
   375			return -EINVAL;
   376		}
   377	
   378		switch (chip->acp_rev) {
   379		case ACP3X_DEV:
   380			pdm_addr = ACP_RENOIR_PDM_ADDR;
   381			break;
   382		case ACP6X_DEV:
   383			pdm_addr = ACP_REMBRANDT_PDM_ADDR;
   384			break;
   385		case ACP63_DEV:
   386			pdm_addr = ACP63_PDM_ADDR;
   387			break;
   388		default:
   389			return -EINVAL;
   390		}
   391	
 > 392		pdm_dev = acpi_find_child_device(ACPI_COMPANION(&pci->dev), pdm_addr, 0);
   393		if (pdm_dev) {
   394			if (!acpi_dev_get_property(pdm_dev, "acp-audio-device-type",
   395						   ACPI_TYPE_INTEGER, &obj) &&
   396						   obj->integer.value == pdm_addr)
   397				return 0;
   398		}
   399		return -ENODEV;
   400	}
   401	EXPORT_SYMBOL_NS_GPL(check_acp_pdm, SND_SOC_ACP_COMMON);
   402	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

             reply	other threads:[~2023-10-27  5:12 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-27  5:11 kernel test robot [this message]
2023-10-27  6:18 ` [broonie-sound:for-next 45/75] sound/soc/amd/acp/acp-legacy-common.c:392:17: warning: assignment to 'struct acpi_device *' from 'int' makes pointer from integer without a cast syed saba kareem

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=202310271326.7xKHbFDH-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=Syed.SabaKareem@amd.com \
    --cc=broonie@kernel.org \
    --cc=oe-kbuild-all@lists.linux.dev \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.