Re: [PATCH v5 1/7] pinctrl: introduce pinctrl_gpio_get_config()

kernel test robot
2026-03-22T07:09:24Z

Hi Dan,

kernel test robot noticed the following build errors:

[auto build test ERROR on linusw-pinctrl/devel]
[also build test ERROR on linusw-pinctrl/for-next brgl/gpio/for-next linus/master v7.0-rc4 next-20260320]
[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/Dan-Carpenter/pinctrl-introduce-pinctrl_gpio_get_config/20260321-225727
base: https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl.git devel
patch link: https://lore.kernel.org/r/f7a41ed017fba4a0986ffe72e06933cc1bba2406.1774087290.git.dan.carpenter%40linaro.org
patch subject: [PATCH v5 1/7] pinctrl: introduce pinctrl_gpio_get_config()
config: loongarch-loongson32_defconfig (https://download.01.org/0day-ci/archive/20260322/202603221553.6g9sSgFm-lkp@intel.com/config)
compiler: clang version 23.0.0git (https://github.com/llvm/llvm-project 4abb927bacf37f18f6359a41639a6d1b3bffffb5)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260322/202603221553.6g9sSgFm-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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202603221553.6g9sSgFm-lkp@intel.com/

All errors (new ones prefixed by >>):

>> drivers/pinctrl/core.c:961:8: error: call to undeclared function 'pin_config_get_for_pin'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
961 | ret = pin_config_get_for_pin(pctldev, pin, config);
| ^
1 error generated.

vim +/pin_config_get_for_pin +961 drivers/pinctrl/core.c

941
942 /**
943 * pinctrl_gpio_get_config() - Get the config for a given GPIO pin
944 * @gc: GPIO chip structure from the GPIO subsystem
945 * @offset: hardware offset of the GPIO relative to the controller
946 * @config: the configuration to query. On success it holds the result
947 * Return: 0 on success, negative errno otherwise
948 */
949 int pinctrl_gpio_get_config(struct gpio_chip *gc, unsigned int offset, unsigned long *config)
950 {
951 struct pinctrl_gpio_range *range;
952 struct pinctrl_dev *pctldev;
953 int ret, pin;
954
955 ret = pinctrl_get_device_gpio_range(gc, offset, &pctldev, &range);
956 if (ret)
957 return ret;
958
959 mutex_lock(&pctldev->mutex);
960 pin = gpio_to_pin(range, gc, offset);
> 961 ret = pin_config_get_for_pin(pctldev, pin, config);
962 mutex_unlock(&pctldev->mutex);
963
964 if (ret)
965 return ret;
966
967 *config = pinconf_to_config_argument(*config);
968 return 0;
969 }
970 EXPORT_SYMBOL_GPL(pinctrl_gpio_get_config);
971

--
0-DAY CI Kernel Test Service