Linux Media Controller development
 help / color / mirror / Atom feed
From: kbuild test robot <lkp@intel.com>
To: "Christian König" <ckoenig.leichtzumerken@gmail.com>
Cc: kbuild-all@01.org, xen-devel@lists.xenproject.org,
	devel@driverdev.osuosl.org, linux-tegra@vger.kernel.org,
	intel-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org,
	dri-devel@lists.freedesktop.org, linux-media@vger.kernel.org,
	sstabellini@kernel.org, jgross@suse.com,
	boris.ostrovsky@oracle.com, digetx@gmail.com,
	gregkh@linuxfoundation.org, arnd@arndb.de, mchehab@kernel.org,
	kyungmin.park@samsung.com, m.szyprowski@samsung.com,
	pawel@osciak.com, jonathanh@nvidia.com, thierry.reding@gmail.com,
	tomi.valkeinen@ti.com, rodrigo.vivi@intel.com,
	joonas.lahtinen@linux.intel.com, jani.nikula@linux.intel.com,
	sean@poorly.run, maxime.ripard@bootlin.com,
	maarten.lankhorst@linux.intel.com, linux@armlinux.org.uk,
	sumit.semwal@linaro.org
Subject: Re: [Intel-gfx] [PATCH] dma-buf: add struct dma_buf_attach_info v2
Date: Tue, 30 Apr 2019 23:23:56 +0800	[thread overview]
Message-ID: <201904302331.zaHkGaBL%lkp@intel.com> (raw)
In-Reply-To: <20190430111002.106168-1-christian.koenig@amd.com>

[-- Attachment #1: Type: text/plain, Size: 3743 bytes --]

Hi "Christian,

I love your patch! Yet something to improve:

[auto build test ERROR on linus/master]
[also build test ERROR on v5.1-rc7 next-20190429]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Christian-K-nig/dma-buf-add-struct-dma_buf_attach_info-v2/20190430-221017
config: xtensa-allyesconfig (attached as .config)
compiler: xtensa-linux-gcc (GCC) 8.1.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        GCC_VERSION=8.1.0 make.cross ARCH=xtensa 

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

   drivers/staging/media/tegra-vde/tegra-vde.c: In function 'tegra_vde_attach_dmabuf':
>> drivers/staging/media/tegra-vde/tegra-vde.c:573:13: error: 'dmabuf' undeclared (first use in this function); did you mean 'dma_buf'?
      .dmabuf = dmabuf
                ^~~~~~
                dma_buf
   drivers/staging/media/tegra-vde/tegra-vde.c:573:13: note: each undeclared identifier is reported only once for each function it appears in

vim +573 drivers/staging/media/tegra-vde/tegra-vde.c

   559	
   560	static int tegra_vde_attach_dmabuf(struct device *dev,
   561					   int fd,
   562					   unsigned long offset,
   563					   size_t min_size,
   564					   size_t align_size,
   565					   struct dma_buf_attachment **a,
   566					   dma_addr_t *addr,
   567					   struct sg_table **s,
   568					   size_t *size,
   569					   enum dma_data_direction dma_dir)
   570	{
   571		struct dma_buf_attach_info attach_info = {
   572			.dev = dev,
 > 573			.dmabuf = dmabuf
   574		};
   575		struct dma_buf_attachment *attachment;
   576		struct dma_buf *dmabuf;
   577		struct sg_table *sgt;
   578		int err;
   579	
   580		dmabuf = dma_buf_get(fd);
   581		if (IS_ERR(dmabuf)) {
   582			dev_err(dev, "Invalid dmabuf FD\n");
   583			return PTR_ERR(dmabuf);
   584		}
   585	
   586		if (dmabuf->size & (align_size - 1)) {
   587			dev_err(dev, "Unaligned dmabuf 0x%zX, should be aligned to 0x%zX\n",
   588				dmabuf->size, align_size);
   589			return -EINVAL;
   590		}
   591	
   592		if ((u64)offset + min_size > dmabuf->size) {
   593			dev_err(dev, "Too small dmabuf size %zu @0x%lX, should be at least %zu\n",
   594				dmabuf->size, offset, min_size);
   595			return -EINVAL;
   596		}
   597	
   598		attachment = dma_buf_attach(&attach_info);
   599		if (IS_ERR(attachment)) {
   600			dev_err(dev, "Failed to attach dmabuf\n");
   601			err = PTR_ERR(attachment);
   602			goto err_put;
   603		}
   604	
   605		sgt = dma_buf_map_attachment(attachment, dma_dir);
   606		if (IS_ERR(sgt)) {
   607			dev_err(dev, "Failed to get dmabufs sg_table\n");
   608			err = PTR_ERR(sgt);
   609			goto err_detach;
   610		}
   611	
   612		if (sgt->nents != 1) {
   613			dev_err(dev, "Sparse DMA region is unsupported\n");
   614			err = -EINVAL;
   615			goto err_unmap;
   616		}
   617	
   618		*addr = sg_dma_address(sgt->sgl) + offset;
   619		*a = attachment;
   620		*s = sgt;
   621	
   622		if (size)
   623			*size = dmabuf->size - offset;
   624	
   625		return 0;
   626	
   627	err_unmap:
   628		dma_buf_unmap_attachment(attachment, sgt, dma_dir);
   629	err_detach:
   630		dma_buf_detach(dmabuf, attachment);
   631	err_put:
   632		dma_buf_put(dmabuf);
   633	
   634		return err;
   635	}
   636	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 56166 bytes --]

  reply	other threads:[~2019-04-30 15:25 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-30 11:10 [PATCH] dma-buf: add struct dma_buf_attach_info v2 Christian König
2019-04-30 15:23 ` kbuild test robot [this message]
2019-04-30 16:59 ` Boris Ostrovsky
2019-04-30 17:31 ` Russell King - ARM Linux admin
2019-05-03 12:05   ` Christian König
2019-05-03 12:09     ` [Intel-gfx] " Daniel Vetter
2019-05-03 12:15       ` Koenig, Christian

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=201904302331.zaHkGaBL%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=arnd@arndb.de \
    --cc=boris.ostrovsky@oracle.com \
    --cc=ckoenig.leichtzumerken@gmail.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=digetx@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jani.nikula@linux.intel.com \
    --cc=jgross@suse.com \
    --cc=jonathanh@nvidia.com \
    --cc=joonas.lahtinen@linux.intel.com \
    --cc=kbuild-all@01.org \
    --cc=kyungmin.park@samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=m.szyprowski@samsung.com \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=maxime.ripard@bootlin.com \
    --cc=mchehab@kernel.org \
    --cc=pawel@osciak.com \
    --cc=rodrigo.vivi@intel.com \
    --cc=sean@poorly.run \
    --cc=sstabellini@kernel.org \
    --cc=sumit.semwal@linaro.org \
    --cc=thierry.reding@gmail.com \
    --cc=tomi.valkeinen@ti.com \
    --cc=xen-devel@lists.xenproject.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