From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com, Dan Carpenter <error27@gmail.com>
Subject: Re: [PATCH 3/3] drm/syncobj: Add a fast path to drm_syncobj_array_find
Date: Mon, 10 Nov 2025 23:11:29 +0800 [thread overview]
Message-ID: <202511102233.GPoKgaPv-lkp@intel.com> (raw)
BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
In-Reply-To: <20251106132645.28208-4-tvrtko.ursulin@igalia.com>
References: <20251106132645.28208-4-tvrtko.ursulin@igalia.com>
TO: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>
TO: dri-devel@lists.freedesktop.org
CC: kernel-dev@igalia.com
CC: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>
CC: "Maíra Canal" <mcanal@igalia.com>
Hi Tvrtko,
kernel test robot noticed the following build warnings:
[auto build test WARNING on drm/drm-next]
[also build test WARNING on drm-exynos/exynos-drm-next drm-intel/for-linux-next drm-intel/for-linux-next-fixes drm-misc/drm-misc-next drm-tip/drm-tip linus/master v6.18-rc5 next-20251110]
[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#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Tvrtko-Ursulin/drm-syncobj-Use-vmemdup_array_user-in-drm_syncobj_array_find/20251106-212904
base: git://anongit.freedesktop.org/drm/drm drm-next
patch link: https://lore.kernel.org/r/20251106132645.28208-4-tvrtko.ursulin%40igalia.com
patch subject: [PATCH 3/3] drm/syncobj: Add a fast path to drm_syncobj_array_find
:::::: branch date: 4 days ago
:::::: commit date: 4 days ago
config: i386-randconfig-141-20251110 (https://download.01.org/0day-ci/archive/20251110/202511102233.GPoKgaPv-lkp@intel.com/config)
compiler: clang version 20.1.8 (https://github.com/llvm/llvm-project 87f0227cb60147a26a1eeb4fb06e3b505e9c7261)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Reported-by: Dan Carpenter <error27@gmail.com>
| Closes: https://lore.kernel.org/r/202511102233.GPoKgaPv-lkp@intel.com/
smatch warnings:
drivers/gpu/drm/drm_syncobj.c:1339 drm_syncobj_array_find() warn: missing unwind goto?
vim +1339 drivers/gpu/drm/drm_syncobj.c
5e60a10eaebab9 Dave Airlie 2017-08-25 1309
3e6fb72d6cef6a Faith Ekstrand 2017-08-25 1310 static int drm_syncobj_array_find(struct drm_file *file_private,
9e5544627339ec Ville Syrjälä 2017-09-01 1311 void __user *user_handles,
9e5544627339ec Ville Syrjälä 2017-09-01 1312 uint32_t count_handles,
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1313 uint32_t *stack_handles,
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1314 struct drm_syncobj **stack_syncobjs,
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1315 u32 stack_count,
3e6fb72d6cef6a Faith Ekstrand 2017-08-25 1316 struct drm_syncobj ***syncobjs_out)
5e60a10eaebab9 Dave Airlie 2017-08-25 1317 {
3e6fb72d6cef6a Faith Ekstrand 2017-08-25 1318 uint32_t i, *handles;
e7aca5031a2fb5 Faith Ekstrand 2017-08-25 1319 struct drm_syncobj **syncobjs;
3e6fb72d6cef6a Faith Ekstrand 2017-08-25 1320 int ret;
5e60a10eaebab9 Dave Airlie 2017-08-25 1321
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1322 if (count_handles > stack_count) {
b4ebe6f6bf86ff Tvrtko Ursulin 2025-11-06 1323 handles = memdup_array_user(user_handles, count_handles,
b4ebe6f6bf86ff Tvrtko Ursulin 2025-11-06 1324 sizeof(*handles));
b4ebe6f6bf86ff Tvrtko Ursulin 2025-11-06 1325 if (IS_ERR(handles))
b4ebe6f6bf86ff Tvrtko Ursulin 2025-11-06 1326 return PTR_ERR(handles);
5e60a10eaebab9 Dave Airlie 2017-08-25 1327
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1328 syncobjs = kmalloc_array(count_handles, sizeof(*syncobjs),
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1329 GFP_KERNEL);
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1330 if (!syncobjs) {
5e60a10eaebab9 Dave Airlie 2017-08-25 1331 ret = -ENOMEM;
5e60a10eaebab9 Dave Airlie 2017-08-25 1332 goto err_free_handles;
5e60a10eaebab9 Dave Airlie 2017-08-25 1333 }
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1334 } else {
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1335 handles = stack_handles;
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1336 syncobjs = stack_syncobjs;
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1337 if (copy_from_user(handles, user_handles,
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1338 count_handles * sizeof(*handles)))
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 @1339 return -EFAULT;
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1340 }
5e60a10eaebab9 Dave Airlie 2017-08-25 1341
3e6fb72d6cef6a Faith Ekstrand 2017-08-25 1342 for (i = 0; i < count_handles; i++) {
e7aca5031a2fb5 Faith Ekstrand 2017-08-25 1343 syncobjs[i] = drm_syncobj_find(file_private, handles[i]);
e7aca5031a2fb5 Faith Ekstrand 2017-08-25 1344 if (!syncobjs[i]) {
e7aca5031a2fb5 Faith Ekstrand 2017-08-25 1345 ret = -ENOENT;
3e6fb72d6cef6a Faith Ekstrand 2017-08-25 1346 goto err_put_syncobjs;
5e60a10eaebab9 Dave Airlie 2017-08-25 1347 }
e7aca5031a2fb5 Faith Ekstrand 2017-08-25 1348 }
5e60a10eaebab9 Dave Airlie 2017-08-25 1349
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1350 if (handles != stack_handles)
3e6fb72d6cef6a Faith Ekstrand 2017-08-25 1351 kfree(handles);
3e6fb72d6cef6a Faith Ekstrand 2017-08-25 1352 *syncobjs_out = syncobjs;
3e6fb72d6cef6a Faith Ekstrand 2017-08-25 1353 return 0;
5e60a10eaebab9 Dave Airlie 2017-08-25 1354
3e6fb72d6cef6a Faith Ekstrand 2017-08-25 1355 err_put_syncobjs:
e7aca5031a2fb5 Faith Ekstrand 2017-08-25 1356 while (i-- > 0)
e7aca5031a2fb5 Faith Ekstrand 2017-08-25 1357 drm_syncobj_put(syncobjs[i]);
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1358 if (syncobjs != stack_syncobjs)
e7aca5031a2fb5 Faith Ekstrand 2017-08-25 1359 kfree(syncobjs);
5e60a10eaebab9 Dave Airlie 2017-08-25 1360 err_free_handles:
6cbb5aa2c8c162 Tvrtko Ursulin 2025-11-06 1361 if (handles != stack_handles)
5e60a10eaebab9 Dave Airlie 2017-08-25 1362 kfree(handles);
5e60a10eaebab9 Dave Airlie 2017-08-25 1363
5e60a10eaebab9 Dave Airlie 2017-08-25 1364 return ret;
5e60a10eaebab9 Dave Airlie 2017-08-25 1365 }
3e6fb72d6cef6a Faith Ekstrand 2017-08-25 1366
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next reply other threads:[~2025-11-10 15:12 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-10 15:11 kernel test robot [this message]
-- strict thread matches above, loose matches on Subject: below --
2026-11-17 10:39 [PATCH 0/3] drm/syncobj: Allocation avoiding fast path Tvrtko Ursulin
2026-11-17 10:39 ` [PATCH 3/3] drm/syncobj: Add a fast path to drm_syncobj_array_find Tvrtko Ursulin
2025-11-06 13:26 [PATCH 0/3] DRM syncobj wait fast path Tvrtko Ursulin
2025-11-06 13:26 ` [PATCH 3/3] drm/syncobj: Add a fast path to drm_syncobj_array_find Tvrtko Ursulin
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=202511102233.GPoKgaPv-lkp@intel.com \
--to=lkp@intel.com \
--cc=error27@gmail.com \
--cc=oe-kbuild@lists.linux.dev \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.