From: kernel test robot <lkp@intel.com>
To: David Stevens <stevensd@chromium.org>,
Robin Murphy <robin.murphy@arm.com>
Cc: kbuild-all@lists.01.org, Christoph Hellwig <hch@lst.de>,
Joerg Roedel <joro@8bytes.org>, Will Deacon <will@kernel.org>,
Sergey Senozhatsky <senozhatsky@chromium.org>,
Lu Baolu <baolu.lu@linux.intel.com>,
iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org,
David Stevens <stevensd@chromium.org>
Subject: Re: [PATCH v2 2/9] dma-iommu: expose a few helper functions to module
Date: Sat, 7 Aug 2021 01:28:55 +0800 [thread overview]
Message-ID: <202108070153.LtYpODFT-lkp@intel.com> (raw)
In-Reply-To: <20210806103423.3341285-3-stevensd@google.com>
[-- Attachment #1: Type: text/plain, Size: 3631 bytes --]
Hi David,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on iommu/next]
[also build test ERROR on drm-intel/for-linux-next hch-configfs/for-next linus/master v5.14-rc4]
[cannot apply to next-20210805]
[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/David-Stevens/Add-dynamic-iommu-backed-bounce-buffers/20210806-183631
base: https://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git next
config: i386-randconfig-a011-20210804 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
# https://github.com/0day-ci/linux/commit/385dff3d789a97ef650912616e9d696fba96cb20
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review David-Stevens/Add-dynamic-iommu-backed-bounce-buffers/20210806-183631
git checkout 385dff3d789a97ef650912616e9d696fba96cb20
# save the attached .config to linux build tree
mkdir build_dir
make W=1 O=build_dir ARCH=i386 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
>> drivers/iommu/dma-iommu.c:415:12: error: conflicting types for '__iommu_dma_alloc_iova'
415 | dma_addr_t __iommu_dma_alloc_iova(struct iommu_domain *domain,
| ^~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/iommu/dma-iommu.c:14:
include/linux/dma-iommu.h:47:12: note: previous declaration of '__iommu_dma_alloc_iova' was here
47 | dma_addr_t __iommu_dma_alloc_iova(struct iommu_domain *domain,
| ^~~~~~~~~~~~~~~~~~~~~~
vim +/__iommu_dma_alloc_iova +415 drivers/iommu/dma-iommu.c
414
> 415 dma_addr_t __iommu_dma_alloc_iova(struct iommu_domain *domain,
416 size_t size, u64 dma_limit, struct device *dev)
417 {
418 struct iommu_dma_cookie *cookie = domain->iova_cookie;
419 struct iova_domain *iovad = &cookie->iovad;
420 unsigned long shift, iova_len, iova = 0;
421
422 if (cookie->type == IOMMU_DMA_MSI_COOKIE) {
423 cookie->msi_iova += size;
424 return cookie->msi_iova - size;
425 }
426
427 shift = iova_shift(iovad);
428 iova_len = size >> shift;
429 /*
430 * Freeing non-power-of-two-sized allocations back into the IOVA caches
431 * will come back to bite us badly, so we have to waste a bit of space
432 * rounding up anything cacheable to make sure that can't happen. The
433 * order of the unadjusted size will still match upon freeing.
434 */
435 if (iova_len < (1 << (IOVA_RANGE_CACHE_MAX_SIZE - 1)))
436 iova_len = roundup_pow_of_two(iova_len);
437
438 dma_limit = min_not_zero(dma_limit, dev->bus_dma_limit);
439
440 if (domain->geometry.force_aperture)
441 dma_limit = min(dma_limit, (u64)domain->geometry.aperture_end);
442
443 /* Try to get PCI devices a SAC address */
444 if (dma_limit > DMA_BIT_MASK(32) && !iommu_dma_forcedac && dev_is_pci(dev))
445 iova = alloc_iova_fast(iovad, iova_len,
446 DMA_BIT_MASK(32) >> shift, false);
447
448 if (!iova)
449 iova = alloc_iova_fast(iovad, iova_len, dma_limit >> shift,
450 true);
451
452 return (dma_addr_t)iova << shift;
453 }
454
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 39716 bytes --]
next prev parent reply other threads:[~2021-08-06 17:29 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-06 10:34 [PATCH v2 0/9] Add dynamic iommu backed bounce buffers David Stevens
2021-08-06 10:34 ` [PATCH v2 1/9] Revert "iommu: Allow the dma-iommu api to use bounce buffers" David Stevens
2021-08-06 10:34 ` [PATCH v2 2/9] dma-iommu: expose a few helper functions to module David Stevens
2021-08-06 17:28 ` kernel test robot [this message]
2021-08-06 10:34 ` [PATCH v2 3/9] dma-iommu: bounce buffers for untrusted devices David Stevens
2021-08-06 15:53 ` kernel test robot
2021-08-10 1:19 ` Mi, Dapeng1
2021-08-10 1:41 ` David Stevens
2021-08-06 10:34 ` [PATCH v2 4/9] dma-iommu: remove extra buffer search on unmap David Stevens
2021-08-06 10:34 ` [PATCH v2 5/9] dma-iommu: clear only necessary bytes David Stevens
2021-08-06 10:34 ` [PATCH v2 6/9] dma-iommu: add bounce buffer pools David Stevens
2021-08-06 10:34 ` [PATCH v2 7/9] dma-iommu: support iommu bounce buffer optimization David Stevens
2021-08-06 10:34 ` [PATCH v2 8/9] dma-mapping: add persistent streaming mapping flag David Stevens
2021-08-06 10:34 ` [PATCH v2 9/9] drm/i915: use DMA_ATTR_PERSISTENT_STREAMING flag David Stevens
2022-05-24 12:27 ` [PATCH v2 0/9] Add dynamic iommu backed bounce buffers Niklas Schnelle
2022-05-27 1:25 ` David Stevens
2022-06-03 14:53 ` Niklas Schnelle
2022-06-06 1:24 ` David Stevens
2022-07-01 9:23 ` Niklas Schnelle
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=202108070153.LtYpODFT-lkp@intel.com \
--to=lkp@intel.com \
--cc=baolu.lu@linux.intel.com \
--cc=hch@lst.de \
--cc=iommu@lists.linux-foundation.org \
--cc=joro@8bytes.org \
--cc=kbuild-all@lists.01.org \
--cc=linux-kernel@vger.kernel.org \
--cc=robin.murphy@arm.com \
--cc=senozhatsky@chromium.org \
--cc=stevensd@chromium.org \
--cc=will@kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox