* [opencloudos:linux-5.4/lts/5.4.119-20.0009.spr 255/2444] drivers/iommu/tegra-smmu.c:793:17: error: implicit declaration of function 'iommu_group_get_for_dev'; did you mean 'iommu_group_get_by_id'?
@ 2024-09-27 11:57 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2024-09-27 11:57 UTC (permalink / raw)
To: kaixuxia, frankjpliu, kasong, sagazchen, kernelxing, aurelianliu,
deshengwu, flyingpeng, jason.zeng, wu.zheng, yingbao.jia,
pei.p.jia
Cc: oe-kbuild-all
tree: https://gitee.com/OpenCloudOS/OpenCloudOS-Kernel.git linux-5.4/lts/5.4.119-20.0009.spr
head: aabcc6dc6d7f9e12baf1f117341469c84afd545d
commit: 0ff8731c5eb159640fc8a8113f4dcd41809c7f47 [255/2444] iommu: Unexport iommu_group_get_for_dev()
config: arm64-allmodconfig (https://download.01.org/0day-ci/archive/20240927/202409271946.Jb5vJXLE-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 14.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240927/202409271946.Jb5vJXLE-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/202409271946.Jb5vJXLE-lkp@intel.com/
All errors (new ones prefixed by >>):
drivers/iommu/tegra-smmu.c: In function 'tegra_smmu_add_device':
>> drivers/iommu/tegra-smmu.c:793:17: error: implicit declaration of function 'iommu_group_get_for_dev'; did you mean 'iommu_group_get_by_id'? [-Werror=implicit-function-declaration]
793 | group = iommu_group_get_for_dev(dev);
| ^~~~~~~~~~~~~~~~~~~~~~~
| iommu_group_get_by_id
drivers/iommu/tegra-smmu.c:793:15: warning: assignment to 'struct iommu_group *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
793 | group = iommu_group_get_for_dev(dev);
| ^
drivers/iommu/tegra-smmu.c: At top level:
drivers/iommu/tegra-smmu.c:893:10: error: 'const struct iommu_ops' has no member named 'add_device'
893 | .add_device = tegra_smmu_add_device,
| ^~~~~~~~~~
drivers/iommu/tegra-smmu.c:893:23: error: initialization of 'int (*)(struct iommu_domain *, long unsigned int, phys_addr_t, size_t, int, gfp_t)' {aka 'int (*)(struct iommu_domain *, long unsigned int, long long unsigned int, long unsigned int, int, unsigned int)'} from incompatible pointer type 'int (*)(struct device *)' [-Werror=incompatible-pointer-types]
893 | .add_device = tegra_smmu_add_device,
| ^~~~~~~~~~~~~~~~~~~~~
drivers/iommu/tegra-smmu.c:893:23: note: (near initialization for 'tegra_smmu_ops.map')
drivers/iommu/tegra-smmu.c:894:10: error: 'const struct iommu_ops' has no member named 'remove_device'; did you mean 'probe_device'?
894 | .remove_device = tegra_smmu_remove_device,
| ^~~~~~~~~~~~~
| probe_device
drivers/iommu/tegra-smmu.c:894:26: error: initialization of 'size_t (*)(struct iommu_domain *, long unsigned int, size_t, struct iommu_iotlb_gather *)' {aka 'long unsigned int (*)(struct iommu_domain *, long unsigned int, long unsigned int, struct iommu_iotlb_gather *)'} from incompatible pointer type 'void (*)(struct device *)' [-Werror=incompatible-pointer-types]
894 | .remove_device = tegra_smmu_remove_device,
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/iommu/tegra-smmu.c:894:26: note: (near initialization for 'tegra_smmu_ops.unmap')
drivers/iommu/tegra-smmu.c:896:16: error: initialization of 'int (*)(struct iommu_domain *, long unsigned int, phys_addr_t, size_t, int, gfp_t)' {aka 'int (*)(struct iommu_domain *, long unsigned int, long long unsigned int, long unsigned int, int, unsigned int)'} from incompatible pointer type 'int (*)(struct iommu_domain *, long unsigned int, phys_addr_t, size_t, int)' {aka 'int (*)(struct iommu_domain *, long unsigned int, long long unsigned int, long unsigned int, int)'} [-Werror=incompatible-pointer-types]
896 | .map = tegra_smmu_map,
| ^~~~~~~~~~~~~~
drivers/iommu/tegra-smmu.c:896:16: note: (near initialization for 'tegra_smmu_ops.map')
drivers/iommu/tegra-smmu.c:896:16: warning: initialized field overwritten [-Woverride-init]
drivers/iommu/tegra-smmu.c:896:16: note: (near initialization for 'tegra_smmu_ops.map')
drivers/iommu/tegra-smmu.c:897:18: warning: initialized field overwritten [-Woverride-init]
897 | .unmap = tegra_smmu_unmap,
| ^~~~~~~~~~~~~~~~
drivers/iommu/tegra-smmu.c:897:18: note: (near initialization for 'tegra_smmu_ops.unmap')
cc1: some warnings being treated as errors
vim +793 drivers/iommu/tegra-smmu.c
7f4c9176f760f4 Thierry Reding 2017-10-12 754
89184651631713 Thierry Reding 2014-04-16 755 static int tegra_smmu_add_device(struct device *dev)
7a31f6f48bb6e3 Hiroshi DOYU 2011-11-17 756 {
89184651631713 Thierry Reding 2014-04-16 757 struct device_node *np = dev->of_node;
7f4c9176f760f4 Thierry Reding 2017-10-12 758 struct tegra_smmu *smmu = NULL;
d92e1f849830fc Robin Murphy 2017-07-21 759 struct iommu_group *group;
89184651631713 Thierry Reding 2014-04-16 760 struct of_phandle_args args;
89184651631713 Thierry Reding 2014-04-16 761 unsigned int index = 0;
7f4c9176f760f4 Thierry Reding 2017-10-12 762 int err;
7a31f6f48bb6e3 Hiroshi DOYU 2011-11-17 763
89184651631713 Thierry Reding 2014-04-16 764 while (of_parse_phandle_with_args(np, "iommus", "#iommu-cells", index,
89184651631713 Thierry Reding 2014-04-16 765 &args) == 0) {
89184651631713 Thierry Reding 2014-04-16 766 smmu = tegra_smmu_find(args.np);
89184651631713 Thierry Reding 2014-04-16 767 if (smmu) {
7f4c9176f760f4 Thierry Reding 2017-10-12 768 err = tegra_smmu_configure(smmu, dev, &args);
7f4c9176f760f4 Thierry Reding 2017-10-12 769 of_node_put(args.np);
7f4c9176f760f4 Thierry Reding 2017-10-12 770
7f4c9176f760f4 Thierry Reding 2017-10-12 771 if (err < 0)
7f4c9176f760f4 Thierry Reding 2017-10-12 772 return err;
7f4c9176f760f4 Thierry Reding 2017-10-12 773
89184651631713 Thierry Reding 2014-04-16 774 /*
89184651631713 Thierry Reding 2014-04-16 775 * Only a single IOMMU master interface is currently
89184651631713 Thierry Reding 2014-04-16 776 * supported by the Linux kernel, so abort after the
89184651631713 Thierry Reding 2014-04-16 777 * first match.
89184651631713 Thierry Reding 2014-04-16 778 */
89184651631713 Thierry Reding 2014-04-16 779 dev->archdata.iommu = smmu;
0b480e44700614 Joerg Roedel 2017-08-09 780
0b480e44700614 Joerg Roedel 2017-08-09 781 iommu_device_link(&smmu->iommu, dev);
0b480e44700614 Joerg Roedel 2017-08-09 782
89184651631713 Thierry Reding 2014-04-16 783 break;
7a31f6f48bb6e3 Hiroshi DOYU 2011-11-17 784 }
7a31f6f48bb6e3 Hiroshi DOYU 2011-11-17 785
7f4c9176f760f4 Thierry Reding 2017-10-12 786 of_node_put(args.np);
89184651631713 Thierry Reding 2014-04-16 787 index++;
89184651631713 Thierry Reding 2014-04-16 788 }
7a31f6f48bb6e3 Hiroshi DOYU 2011-11-17 789
7f4c9176f760f4 Thierry Reding 2017-10-12 790 if (!smmu)
7f4c9176f760f4 Thierry Reding 2017-10-12 791 return -ENODEV;
7f4c9176f760f4 Thierry Reding 2017-10-12 792
d92e1f849830fc Robin Murphy 2017-07-21 @793 group = iommu_group_get_for_dev(dev);
d92e1f849830fc Robin Murphy 2017-07-21 794 if (IS_ERR(group))
d92e1f849830fc Robin Murphy 2017-07-21 795 return PTR_ERR(group);
d92e1f849830fc Robin Murphy 2017-07-21 796
d92e1f849830fc Robin Murphy 2017-07-21 797 iommu_group_put(group);
d92e1f849830fc Robin Murphy 2017-07-21 798
89184651631713 Thierry Reding 2014-04-16 799 return 0;
7a31f6f48bb6e3 Hiroshi DOYU 2011-11-17 800 }
7a31f6f48bb6e3 Hiroshi DOYU 2011-11-17 801
:::::: The code at line 793 was first introduced by commit
:::::: d92e1f849830fc78c50a00b953361fc1449aa1e2 iommu/tegra-smmu: Add iommu_group support
:::::: TO: Robin Murphy <robin.murphy@arm.com>
:::::: CC: Joerg Roedel <jroedel@suse.de>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2024-09-27 11:58 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-27 11:57 [opencloudos:linux-5.4/lts/5.4.119-20.0009.spr 255/2444] drivers/iommu/tegra-smmu.c:793:17: error: implicit declaration of function 'iommu_group_get_for_dev'; did you mean 'iommu_group_get_by_id'? kernel test robot
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.