[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202508152116.hQq8Sw2Y-lkp@intel.com>
Date: Fri, 15 Aug 2025 21:37:23 +0800
From: kernel test robot <lkp@...el.com>
To: Tzung-Bi Shih <tzungbi@...nel.org>, bleung@...omium.org
Cc: oe-kbuild-all@...ts.linux.dev, tzungbi@...nel.org, dawidn@...gle.com,
chrome-platform@...ts.linux.dev, akpm@...ux-foundation.org,
gregkh@...uxfoundation.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/3] platform/chrome: Protect cros_ec_device lifecycle
with ref_proxy
Hi Tzung-Bi,
kernel test robot noticed the following build warnings:
[auto build test WARNING on chrome-platform/for-next]
[also build test WARNING on chrome-platform/for-firmware-next akpm-mm/mm-nonmm-unstable akpm-mm/mm-everything linus/master v6.17-rc1 next-20250815]
[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/Tzung-Bi-Shih/lib-Add-ref_proxy-module/20250814-172126
base: https://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linux.git for-next
patch link: https://lore.kernel.org/r/20250814091020.1302888-3-tzungbi%40kernel.org
patch subject: [PATCH 2/3] platform/chrome: Protect cros_ec_device lifecycle with ref_proxy
config: sparc64-randconfig-r113-20250815 (https://download.01.org/0day-ci/archive/20250815/202508152116.hQq8Sw2Y-lkp@intel.com/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 93d24b6b7b148c47a2fa228a4ef31524fa1d9f3f)
reproduce: (https://download.01.org/0day-ci/archive/20250815/202508152116.hQq8Sw2Y-lkp@intel.com/reproduce)
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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202508152116.hQq8Sw2Y-lkp@intel.com/
sparse warnings: (new ones prefixed by >>)
>> lib/ref_proxy.c:167:16: sparse: sparse: incorrect type in return expression (different address spaces) @@ expected void [noderef] __rcu * @@ got void * @@
lib/ref_proxy.c:167:16: sparse: expected void [noderef] __rcu *
lib/ref_proxy.c:167:16: sparse: got void *
lib/ref_proxy.c: note: in included file (through include/linux/notifier.h, include/linux/memory_hotplug.h, include/linux/mmzone.h, ...):
include/linux/srcu.h:373:9: sparse: sparse: context imbalance in 'ref_proxy_put' - unexpected unlock
vim +167 lib/ref_proxy.c
f2304a9508b177 Tzung-Bi Shih 2025-08-14 152
f2304a9508b177 Tzung-Bi Shih 2025-08-14 153 /**
f2304a9508b177 Tzung-Bi Shih 2025-08-14 154 * ref_proxy_get() - Get the resource.
f2304a9508b177 Tzung-Bi Shih 2025-08-14 155 * @proxy: The pointer of struct ref_proxy.
f2304a9508b177 Tzung-Bi Shih 2025-08-14 156 *
f2304a9508b177 Tzung-Bi Shih 2025-08-14 157 * This tries to de-reference to the resource and enters a RCU critical
f2304a9508b177 Tzung-Bi Shih 2025-08-14 158 * section.
f2304a9508b177 Tzung-Bi Shih 2025-08-14 159 *
f2304a9508b177 Tzung-Bi Shih 2025-08-14 160 * Return: The pointer to the resource. NULL if the resource has gone.
f2304a9508b177 Tzung-Bi Shih 2025-08-14 161 */
f2304a9508b177 Tzung-Bi Shih 2025-08-14 162 void __rcu *ref_proxy_get(struct ref_proxy *proxy)
f2304a9508b177 Tzung-Bi Shih 2025-08-14 163 {
f2304a9508b177 Tzung-Bi Shih 2025-08-14 164 struct ref_proxy_provider *rpp = proxy->rpp;
f2304a9508b177 Tzung-Bi Shih 2025-08-14 165
f2304a9508b177 Tzung-Bi Shih 2025-08-14 166 proxy->idx = srcu_read_lock(&rpp->srcu);
f2304a9508b177 Tzung-Bi Shih 2025-08-14 @167 return rcu_dereference(rpp->ref);
f2304a9508b177 Tzung-Bi Shih 2025-08-14 168 }
f2304a9508b177 Tzung-Bi Shih 2025-08-14 169 EXPORT_SYMBOL(ref_proxy_get);
f2304a9508b177 Tzung-Bi Shih 2025-08-14 170
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists