[arm:cex7 68/68] drivers/bus/fsl-mc/fsl-mc-bus.c:163:42: error: 'struct iommu_fwspec' has no member named 'iommu_fwnode'

kernel test robot lkp at intel.com
Sun Jan 10 14:53:24 EST 2021


tree:   git://git.armlinux.org.uk/~rmk/linux-arm.git cex7
head:   1b61ddd350658ee9d202584c4c9b67bd2f34a452
commit: 1b61ddd350658ee9d202584c4c9b67bd2f34a452 [68/68] bus: fsl-mc: add custom .dma_configure implementation
config: arm-randconfig-r001-20210110 (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 9.3.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
        git remote add arm git://git.armlinux.org.uk/~rmk/linux-arm.git
        git fetch --no-tags arm cex7
        git checkout 1b61ddd350658ee9d202584c4c9b67bd2f34a452
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp at intel.com>

All errors (new ones prefixed by >>):

   drivers/bus/fsl-mc/fsl-mc-bus.c: In function 'fsl_mc_dma_configure':
>> drivers/bus/fsl-mc/fsl-mc-bus.c:163:42: error: 'struct iommu_fwspec' has no member named 'iommu_fwnode'
     163 |  iommu_ops = iommu_ops_from_fwnode(fwspec->iommu_fwnode);
         |                                          ^~
   drivers/bus/fsl-mc/fsl-mc-bus.c:167:37: error: 'struct iommu_fwspec' has no member named 'iommu_fwnode'
     167 |  ret = iommu_fwspec_init(dev, fwspec->iommu_fwnode, iommu_ops);
         |                                     ^~
>> drivers/bus/fsl-mc/fsl-mc-bus.c:178:9: error: implicit declaration of function 'iommu_probe_device'; did you mean 'iommu_detach_device'? [-Werror=implicit-function-declaration]
     178 |   ret = iommu_probe_device(dev);
         |         ^~~~~~~~~~~~~~~~~~
         |         iommu_detach_device
   cc1: some warnings being treated as errors


vim +163 drivers/bus/fsl-mc/fsl-mc-bus.c

   133	
   134	static int fsl_mc_dma_configure(struct device *dev)
   135	{
   136		struct device *dma_dev = dev;
   137		struct fsl_mc_device *mc_dev = to_fsl_mc_device(dev);
   138		u32 input_id = mc_dev->icid;
   139		struct iommu_fwspec *fwspec;
   140		const struct iommu_ops *iommu_ops;
   141		int ret;
   142	
   143		/* Skip DMA setup for devices that are not DMA masters */
   144		if (dev->type == &fsl_mc_bus_dpmcp_type ||
   145		    dev->type == &fsl_mc_bus_dpbp_type ||
   146		    dev->type == &fsl_mc_bus_dpcon_type ||
   147		    dev->type == &fsl_mc_bus_dpio_type)
   148			return 0;
   149	
   150		while (dev_is_fsl_mc(dma_dev))
   151			dma_dev = dma_dev->parent;
   152	
   153	
   154	#if 0
   155		if (dev_of_node(dma_dev))
   156			return of_dma_configure_id(dev, dma_dev->of_node, 0, &input_id);
   157	
   158		return acpi_dma_configure_id(dev, DEV_DMA_COHERENT, &input_id);
   159	#else
   160		fwspec = dev_iommu_fwspec_get(dma_dev);
   161		if (!fwspec)
   162			return -ENODEV;
 > 163		iommu_ops = iommu_ops_from_fwnode(fwspec->iommu_fwnode);
   164		if (!iommu_ops)
   165			return -ENODEV;
   166	
   167		ret = iommu_fwspec_init(dev, fwspec->iommu_fwnode, iommu_ops);
   168		if (ret)
   169			return ret;
   170	
   171		ret = iommu_fwspec_add_ids(dev, &input_id, 1);
   172		if (ret) {
   173			iommu_fwspec_free(dev);
   174			return ret;
   175		}
   176	
   177		if (!device_iommu_mapped(dev)) {
 > 178			ret = iommu_probe_device(dev);
   179			if (ret) {
   180				iommu_fwspec_free(dev);
   181				return ret;
   182			}
   183		}
   184	
   185		arch_setup_dma_ops(dev, 0, *dma_dev->dma_mask + 1, iommu_ops, true);
   186	
   187		return 0;
   188	#endif
   189	}
   190	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config.gz
Type: application/gzip
Size: 29831 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20210111/f7a34133/attachment-0001.gz>


More information about the linux-arm-kernel mailing list