[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202111281517.uhxzSCMA-lkp@intel.com>
Date: Sun, 28 Nov 2021 15:23:21 +0800
From: kernel test robot <lkp@...el.com>
To: Thomas Gleixner <tglx@...utronix.de>
Cc: kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org
Subject: [tglx-devel:msi 46/100]
arch/powerpc/platforms/cell/axon_msi.c:212:44: error: passing argument 1 of
'msi_device_has_property' from incompatible pointer type
tree: https://git.kernel.org/pub/scm/linux/kernel/git/tglx/devel.git msi
head: 76af424949030bcbbe874fc272e3cd7e388a6c7f
commit: fce5ea72265d4fc76cfc10c819c3482d20b12fef [46/100] powerpc/cell/axon_msi: Use MSI device properties
config: powerpc64-randconfig-r021-20211128 (https://download.01.org/0day-ci/archive/20211128/202111281517.uhxzSCMA-lkp@intel.com/config)
compiler: powerpc64-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/tglx/devel.git/commit/?id=fce5ea72265d4fc76cfc10c819c3482d20b12fef
git remote add tglx-devel https://git.kernel.org/pub/scm/linux/kernel/git/tglx/devel.git
git fetch --no-tags tglx-devel msi
git checkout fce5ea72265d4fc76cfc10c819c3482d20b12fef
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=powerpc SHELL=/bin/bash arch/powerpc/platforms/cell/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
All errors (new ones prefixed by >>):
arch/powerpc/platforms/cell/axon_msi.c: In function 'setup_msi_msg_address':
>> arch/powerpc/platforms/cell/axon_msi.c:212:44: error: passing argument 1 of 'msi_device_has_property' from incompatible pointer type [-Werror=incompatible-pointer-types]
212 | is_64bit = msi_device_has_property(dev, MSI_PROP_64BIT);
| ^~~
| |
| struct pci_dev *
In file included from arch/powerpc/platforms/cell/axon_msi.c:11:
include/linux/msi.h:164:45: note: expected 'struct device *' but argument is of type 'struct pci_dev *'
164 | bool msi_device_has_property(struct device *dev, unsigned long prop);
| ~~~~~~~~~~~~~~~^~~
cc1: some warnings being treated as errors
vim +/msi_device_has_property +212 arch/powerpc/platforms/cell/axon_msi.c
198
199 static int setup_msi_msg_address(struct pci_dev *dev, struct msi_msg *msg)
200 {
201 struct device_node *dn;
202 bool is_64bit;
203 int len;
204 const u32 *prop;
205
206 dn = of_node_get(pci_device_to_OF_node(dev));
207 if (!dn) {
208 dev_dbg(&dev->dev, "axon_msi: no pci_dn found\n");
209 return -ENODEV;
210 }
211
> 212 is_64bit = msi_device_has_property(dev, MSI_PROP_64BIT);
213
214 for (; dn; dn = of_get_next_parent(dn)) {
215 if (is_64bit) {
216 prop = of_get_property(dn, "msi-address-64", &len);
217 if (prop)
218 break;
219 }
220
221 prop = of_get_property(dn, "msi-address-32", &len);
222 if (prop)
223 break;
224 }
225
226 if (!prop) {
227 dev_dbg(&dev->dev,
228 "axon_msi: no msi-address-(32|64) properties found\n");
229 return -ENOENT;
230 }
231
232 switch (len) {
233 case 8:
234 msg->address_hi = prop[0];
235 msg->address_lo = prop[1];
236 break;
237 case 4:
238 msg->address_hi = 0;
239 msg->address_lo = prop[0];
240 break;
241 default:
242 dev_dbg(&dev->dev,
243 "axon_msi: malformed msi-address-(32|64) property\n");
244 of_node_put(dn);
245 return -EINVAL;
246 }
247
248 of_node_put(dn);
249
250 return 0;
251 }
252
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
Powered by blists - more mailing lists