From: Bartosz Golaszewski Date: Wed, 7 May 2025 14:35:51 +0000 (+0200) Subject: pinctrl: add stubs for OF-specific pinconf functions X-Git-Tag: v6.16-rc1~113^2~10 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=3b38cce83fa97348e7a926dd90304c18b9659308;p=thirdparty%2Fkernel%2Flinux.git pinctrl: add stubs for OF-specific pinconf functions Allow building drivers using these interfaces with COMPILE_TEST enabled and OF disabled by providing stub definitions. Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202505072245.OgSXI1hh-lkp@intel.com/ Signed-off-by: Bartosz Golaszewski Link: https://lore.kernel.org/20250507143551.47056-1-brgl@bgdev.pl Signed-off-by: Linus Walleij --- diff --git a/drivers/pinctrl/pinconf.h b/drivers/pinctrl/pinconf.h index a171195b36159..e1ae716105261 100644 --- a/drivers/pinctrl/pinconf.h +++ b/drivers/pinctrl/pinconf.h @@ -142,4 +142,21 @@ int pinconf_generic_parse_dt_config(struct device_node *np, int pinconf_generic_parse_dt_pinmux(struct device_node *np, struct device *dev, unsigned int **pid, unsigned int **pmux, unsigned int *npins); +#else +static inline int +pinconf_generic_parse_dt_config(struct device_node *np, + struct pinctrl_dev *pctldev, + unsigned long **configs, + unsigned int *nconfigs) +{ + return -ENOTSUPP; +} + +static inline int +pinconf_generic_parse_dt_pinmux(struct device_node *np, struct device *dev, + unsigned int **pid, unsigned int **pmux, + unsigned int *npins) +{ + return -ENOTSUPP; +} #endif