From: kernel test robot <lkp@intel.com>
To: Daniel Vetter <daniel.vetter@ffwll.ch>,
DRI Development <dri-devel@lists.freedesktop.org>
Cc: kbuild-all@lists.01.org, clang-built-linux@googlegroups.com,
"Daniel Vetter" <daniel.vetter@ffwll.ch>,
"Intel Graphics Development" <intel-gfx@lists.freedesktop.org>,
linaro-mm-sig@lists.linaro.org,
"Thomas Zimmermann" <tzimmermann@suse.de>,
"Christian König" <christian.koenig@amd.com>,
linux-media@vger.kernel.org
Subject: Re: [PATCH 3/4] dma-buf: begin/end_cpu might lock the dma_resv lock
Date: Sat, 12 Dec 2020 06:31:11 +0800 [thread overview]
Message-ID: <202012120607.1RLfy1Ex-lkp@intel.com> (raw)
In-Reply-To: <20201211155843.3348718-3-daniel.vetter@ffwll.ch>
[-- Attachment #1: Type: text/plain, Size: 4371 bytes --]
Hi Daniel,
I love your patch! Yet something to improve:
[auto build test ERROR on next-20201211]
[also build test ERROR on v5.10-rc7]
[cannot apply to tegra-drm/drm/tegra/for-next linus/master v5.10-rc7 v5.10-rc6 v5.10-rc5]
[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/Daniel-Vetter/dma-buf-Remove-kmap-kerneldoc-vestiges/20201212-000040
base: 3cc2bd440f2171f093b3a8480a4b54d8c270ed38
config: powerpc64-randconfig-r035-20201210 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 5ff35356f1af2bb92785b38c657463924d9ec386)
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
# install powerpc64 cross compiling tool for clang build
# apt-get install binutils-powerpc64-linux-gnu
# https://github.com/0day-ci/linux/commit/24d4fcf0e09c80974556c7639cb630f86a544378
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Daniel-Vetter/dma-buf-Remove-kmap-kerneldoc-vestiges/20201212-000040
git checkout 24d4fcf0e09c80974556c7639cb630f86a544378
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc64
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/dma-buf/dma-buf.c:1121:14: error: use of undeclared identifier 'dma_buf'
might_lock(&dma_buf->resv.lock);
^
>> drivers/dma-buf/dma-buf.c:1121:14: error: use of undeclared identifier 'dma_buf'
>> drivers/dma-buf/dma-buf.c:1121:14: error: use of undeclared identifier 'dma_buf'
drivers/dma-buf/dma-buf.c:1156:14: error: use of undeclared identifier 'dma_buf'
might_lock(&dma_buf->resv.lock);
^
drivers/dma-buf/dma-buf.c:1156:14: error: use of undeclared identifier 'dma_buf'
drivers/dma-buf/dma-buf.c:1156:14: error: use of undeclared identifier 'dma_buf'
6 errors generated.
vim +/dma_buf +1121 drivers/dma-buf/dma-buf.c
1093
1094 /**
1095 * dma_buf_begin_cpu_access - Must be called before accessing a dma_buf from the
1096 * cpu in the kernel context. Calls begin_cpu_access to allow exporter-specific
1097 * preparations. Coherency is only guaranteed in the specified range for the
1098 * specified access direction.
1099 * @dmabuf: [in] buffer to prepare cpu access for.
1100 * @direction: [in] length of range for cpu access.
1101 *
1102 * After the cpu access is complete the caller should call
1103 * dma_buf_end_cpu_access(). Only when cpu access is braketed by both calls is
1104 * it guaranteed to be coherent with other DMA access.
1105 *
1106 * This function will also wait for any DMA transactions tracked through
1107 * implicit synchronization in &dma_buf.resv. For DMA transactions with explicit
1108 * synchronization this function will only ensure cache coherency, callers must
1109 * ensure synchronization with such DMA transactions on their own.
1110 *
1111 * Can return negative error values, returns 0 on success.
1112 */
1113 int dma_buf_begin_cpu_access(struct dma_buf *dmabuf,
1114 enum dma_data_direction direction)
1115 {
1116 int ret = 0;
1117
1118 if (WARN_ON(!dmabuf))
1119 return -EINVAL;
1120
> 1121 might_lock(&dma_buf->resv.lock);
1122
1123 if (dmabuf->ops->begin_cpu_access)
1124 ret = dmabuf->ops->begin_cpu_access(dmabuf, direction);
1125
1126 /* Ensure that all fences are waited upon - but we first allow
1127 * the native handler the chance to do so more efficiently if it
1128 * chooses. A double invocation here will be reasonably cheap no-op.
1129 */
1130 if (ret == 0)
1131 ret = __dma_buf_begin_cpu_access(dmabuf, direction);
1132
1133 return ret;
1134 }
1135 EXPORT_SYMBOL_GPL(dma_buf_begin_cpu_access);
1136
---
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: 44099 bytes --]
next prev parent reply other threads:[~2020-12-11 23:25 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-11 15:58 [PATCH 1/4] dma-buf: Remove kmap kerneldoc vestiges Daniel Vetter
2020-12-11 15:58 ` [PATCH 2/4] dma-buf: some kerneldoc formatting fixes Daniel Vetter
2020-12-11 15:58 ` [PATCH 3/4] dma-buf: begin/end_cpu might lock the dma_resv lock Daniel Vetter
2020-12-11 22:31 ` kernel test robot [this message]
2020-12-14 10:33 ` Christian König
2020-12-14 17:16 ` [PATCH] " Daniel Vetter
2020-12-15 14:16 ` Christian König
2020-12-11 15:58 ` [PATCH 4/4] dma-buf: doc polish for pin/unpin Daniel Vetter
2020-12-14 10:33 ` [PATCH 1/4] dma-buf: Remove kmap kerneldoc vestiges Christian König
2020-12-14 16:01 ` Daniel Vetter
2020-12-15 14:18 ` Christian König
2020-12-16 10:29 ` Daniel Vetter
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=202012120607.1RLfy1Ex-lkp@intel.com \
--to=lkp@intel.com \
--cc=christian.koenig@amd.com \
--cc=clang-built-linux@googlegroups.com \
--cc=daniel.vetter@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=kbuild-all@lists.01.org \
--cc=linaro-mm-sig@lists.linaro.org \
--cc=linux-media@vger.kernel.org \
--cc=tzimmermann@suse.de \
/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