CC: [email protected] In-Reply-To: <[email protected]> References: <[email protected]> TO: "Jean-Philippe Brucker" <[email protected]> TO: [email protected] TO: [email protected] TO: [email protected] TO: [email protected] CC: [email protected] CC: [email protected] CC: [email protected] CC: [email protected] CC: [email protected] CC: [email protected]
Hi Jean-Philippe, I love your patch! Perhaps something to improve: [auto build test WARNING on pci/next] [also build test WARNING on linus/master v5.9-rc2 next-20200827] [cannot apply to iommu/next vhost/linux-next] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Jean-Philippe-Brucker/Add-virtio-iommu-built-in-topology/20200821-211904 base: https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git next :::::: branch date: 7 days ago :::::: commit date: 7 days ago config: i386-randconfig-m021-20200828 (attached as .config) compiler: gcc-9 (Debian 9.3.0-15) 9.3.0 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <[email protected]> Reported-by: Dan Carpenter <[email protected]> smatch warnings: drivers/iommu/virtio/topology-helpers.c:142 virt_dma_configure() warn: passing zero to 'PTR_ERR' drivers/iommu/virtio/topology.c:70 viommu_parse_node() warn: passing zero to 'ERR_PTR' # https://github.com/0day-ci/linux/commit/2b45717082f8603e400de954e1a465dd508028af git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Jean-Philippe-Brucker/Add-virtio-iommu-built-in-topology/20200821-211904 git checkout 2b45717082f8603e400de954e1a465dd508028af vim +/PTR_ERR +142 drivers/iommu/virtio/topology-helpers.c fd1c41b616087e Jean-Philippe Brucker 2020-08-21 125 fd1c41b616087e Jean-Philippe Brucker 2020-08-21 126 /** fd1c41b616087e Jean-Philippe Brucker 2020-08-21 127 * virt_dma_configure - Configure DMA of virtualized devices fd1c41b616087e Jean-Philippe Brucker 2020-08-21 128 * @dev: the endpoint fd1c41b616087e Jean-Philippe Brucker 2020-08-21 129 * fd1c41b616087e Jean-Philippe Brucker 2020-08-21 130 * Setup the DMA and IOMMU ops of a virtual device, for platforms without DT or fd1c41b616087e Jean-Philippe Brucker 2020-08-21 131 * ACPI. fd1c41b616087e Jean-Philippe Brucker 2020-08-21 132 * fd1c41b616087e Jean-Philippe Brucker 2020-08-21 133 * Return: -EPROBE_DEFER if the device is managed by an IOMMU that hasn't been fd1c41b616087e Jean-Philippe Brucker 2020-08-21 134 * probed yet, 0 otherwise fd1c41b616087e Jean-Philippe Brucker 2020-08-21 135 */ fd1c41b616087e Jean-Philippe Brucker 2020-08-21 136 int virt_dma_configure(struct device *dev) fd1c41b616087e Jean-Philippe Brucker 2020-08-21 137 { fd1c41b616087e Jean-Philippe Brucker 2020-08-21 138 const struct iommu_ops *iommu_ops; fd1c41b616087e Jean-Philippe Brucker 2020-08-21 139 fd1c41b616087e Jean-Philippe Brucker 2020-08-21 140 iommu_ops = virt_iommu_setup(dev); fd1c41b616087e Jean-Philippe Brucker 2020-08-21 141 if (IS_ERR_OR_NULL(iommu_ops)) { fd1c41b616087e Jean-Philippe Brucker 2020-08-21 @142 int ret = PTR_ERR(iommu_ops); fd1c41b616087e Jean-Philippe Brucker 2020-08-21 143 fd1c41b616087e Jean-Philippe Brucker 2020-08-21 144 if (ret == -EPROBE_DEFER || ret == 0) fd1c41b616087e Jean-Philippe Brucker 2020-08-21 145 return ret; fd1c41b616087e Jean-Philippe Brucker 2020-08-21 146 dev_err(dev, "error %d while setting up virt IOMMU\n", ret); fd1c41b616087e Jean-Philippe Brucker 2020-08-21 147 return 0; fd1c41b616087e Jean-Philippe Brucker 2020-08-21 148 } fd1c41b616087e Jean-Philippe Brucker 2020-08-21 149 fd1c41b616087e Jean-Philippe Brucker 2020-08-21 150 /* fd1c41b616087e Jean-Philippe Brucker 2020-08-21 151 * If we have reason to believe the IOMMU driver missed the initial fd1c41b616087e Jean-Philippe Brucker 2020-08-21 152 * add_device callback for dev, replay it to get things in order. fd1c41b616087e Jean-Philippe Brucker 2020-08-21 153 */ fd1c41b616087e Jean-Philippe Brucker 2020-08-21 154 if (dev->bus && !device_iommu_mapped(dev)) fd1c41b616087e Jean-Philippe Brucker 2020-08-21 155 iommu_probe_device(dev); fd1c41b616087e Jean-Philippe Brucker 2020-08-21 156 fd1c41b616087e Jean-Philippe Brucker 2020-08-21 157 /* Assume coherent, as well as full 64-bit addresses. */ fd1c41b616087e Jean-Philippe Brucker 2020-08-21 158 #ifdef CONFIG_ARCH_HAS_SETUP_DMA_OPS fd1c41b616087e Jean-Philippe Brucker 2020-08-21 159 arch_setup_dma_ops(dev, 0, ~0ULL, iommu_ops, true); fd1c41b616087e Jean-Philippe Brucker 2020-08-21 160 #else fd1c41b616087e Jean-Philippe Brucker 2020-08-21 161 iommu_setup_dma_ops(dev, 0, ~0ULL); fd1c41b616087e Jean-Philippe Brucker 2020-08-21 162 #endif fd1c41b616087e Jean-Philippe Brucker 2020-08-21 163 return 0; fd1c41b616087e Jean-Philippe Brucker 2020-08-21 164 } fd1c41b616087e Jean-Philippe Brucker 2020-08-21 165 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/[email protected]
.config.gz
Description: application/gzip
_______________________________________________ kbuild mailing list -- [email protected] To unsubscribe send an email to [email protected]
