Hi Daniel,
[FYI, it's a private test report for your RFC patch.]
[auto build test WARNING on regulator/for-next]
[also build test WARNING on linux/master linus/master platform-drivers-x86/for-next
v5.14-rc7 next-20210824]
[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-Scally/Add-regulator_look...
base:
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next
config: riscv-randconfig-r013-20210824 (attached as .config)
compiler: clang version 14.0.0 (
https://github.com/llvm/llvm-project
d26000e4cc2bc65e207a84fa26cb6e374d60aa12)
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 riscv cross compiling tool for clang build
# apt-get install binutils-riscv64-linux-gnu
#
https://github.com/0day-ci/linux/commit/ccd472afd1dd7290ca3e48124903410b2...
git remote add linux-review
https://github.com/0day-ci/linux
git fetch --no-tags linux-review
Daniel-Scally/Add-regulator_lookup_list-and-API/20210825-070828
git checkout ccd472afd1dd7290ca3e48124903410b2f3edc12
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=riscv
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
> drivers/regulator/core.c:5346:1: warning: no previous prototype
for function 'regulator_lookup_init_data' [-Wmissing-prototypes]
regulator_lookup_init_data(const struct regulator_desc *desc,
^
drivers/regulator/core.c:5345:1: note: declare 'static' if the function is not
intended to be used outside of this translation unit
struct regulator_init_data *
^
static
1 warning generated.
vim +/regulator_lookup_init_data +5346 drivers/regulator/core.c
5334
5335 /**
5336 * regulator_lookup_init_data - Check regulator_lookup_list for matching entries
5337 * @desc: Regulator desc containing name of the regulator
5338 * @cfg: Regulator config containing pointer to the registering device
5339 *
5340 * Calling this function scans the regulator_lookup_list and checks each entry
5341 * to see if the .device_name and .regulator_name fields match the device name
5342 * and regulator name contained in @cfg and @desc. If so, a pointer to the
5343 * embedded &struct regulator_init_data is returned. No matches returns NULL.
5344 */
5345 struct regulator_init_data *
5346 regulator_lookup_init_data(const struct regulator_desc *desc,
5347 const struct regulator_config *cfg)
5348 {
5349 struct regulator_lookup *lookup;
5350
5351 if (!desc || !cfg || !cfg->dev)
5352 return NULL;
5353
5354 mutex_lock(®ulator_lookup_mutex);
5355
5356 list_for_each_entry(lookup, ®ulator_lookup_list, list) {
5357 /*
5358 * We need the lookup to have at least a device_name or there's
5359 * no guarantee of a match, and regulator_register() checks to
5360 * make sure that desc->name is not null, so any entry with
5361 * either field null is invalid.
5362 */
5363 if (!lookup->device_name || !lookup->regulator_name)
5364 continue;
5365
5366 if (strcmp(lookup->device_name, dev_name(cfg->dev)))
5367 continue;
5368
5369 if (strcmp(lookup->regulator_name, desc->name))
5370 continue;
5371
5372 goto found;
5373 }
5374
5375 lookup = NULL;
5376
5377 found:
5378 mutex_unlock(®ulator_lookup_mutex);
5379
5380 return lookup ? &lookup->init_data : NULL;
5381 }
5382
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org