include/linux/framer/framer.h:184:16: warning: no previous prototype for function 'framer_get'

From: kernel test robot
Date: Sat Mar 23 2024 - 23:20:36 EST


tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 70293240c5ce675a67bfc48f419b093023b862b3
commit: 54762918ca856028d33d1d56d017a4d7706c6196 net: wan: fsl_qmc_hdlc: Add framer support
date: 13 days ago
config: powerpc-randconfig-003-20240324 (https://download.01.org/0day-ci/archive/20240324/202403241110.hfJqeJRu-lkp@xxxxxxxxx/config)
compiler: clang version 19.0.0git (https://github.com/llvm/llvm-project 23de3862dce582ce91c1aa914467d982cb1a73b4)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240324/202403241110.hfJqeJRu-lkp@xxxxxxxxx/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@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202403241110.hfJqeJRu-lkp@xxxxxxxxx/

All warnings (new ones prefixed by >>):

In file included from drivers/net/wan/fsl_qmc_hdlc.c:14:
In file included from include/linux/dma-mapping.h:11:
In file included from include/linux/scatterlist.h:8:
In file included from include/linux/mm.h:2188:
include/linux/vmstat.h:522:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion]
522 | return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_"
| ~~~~~~~~~~~ ^ ~~~
In file included from drivers/net/wan/fsl_qmc_hdlc.c:17:
>> include/linux/framer/framer.h:184:16: warning: no previous prototype for function 'framer_get' [-Wmissing-prototypes]
184 | struct framer *framer_get(struct device *dev, const char *con_id)
| ^
include/linux/framer/framer.h:184:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
184 | struct framer *framer_get(struct device *dev, const char *con_id)
| ^
| static
>> include/linux/framer/framer.h:189:6: warning: no previous prototype for function 'framer_put' [-Wmissing-prototypes]
189 | void framer_put(struct device *dev, struct framer *framer)
| ^
include/linux/framer/framer.h:189:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
189 | void framer_put(struct device *dev, struct framer *framer)
| ^
| static
drivers/net/wan/fsl_qmc_hdlc.c:783:25: error: use of undeclared identifier 'qmc_hdlc_driver'; did you mean 'qmc_hdlc_probe'?
783 | MODULE_DEVICE_TABLE(of, qmc_hdlc_driver);
| ^~~~~~~~~~~~~~~
| qmc_hdlc_probe
include/linux/module.h:244:15: note: expanded from macro 'MODULE_DEVICE_TABLE'
244 | extern typeof(name) __mod_##type##__##name##_device_table \
| ^
drivers/net/wan/fsl_qmc_hdlc.c:694:12: note: 'qmc_hdlc_probe' declared here
694 | static int qmc_hdlc_probe(struct platform_device *pdev)
| ^
3 warnings and 1 error generated.

Kconfig warnings: (for reference only)
WARNING: unmet direct dependencies detected for HOTPLUG_CPU
Depends on [n]: SMP [=y] && (PPC_PSERIES [=n] || PPC_PMAC [=n] || PPC_POWERNV [=n] || FSL_SOC_BOOKE [=n])
Selected by [y]:
- PM_SLEEP_SMP [=y] && SMP [=y] && (ARCH_SUSPEND_POSSIBLE [=y] || ARCH_HIBERNATION_POSSIBLE [=y]) && PM_SLEEP [=y]


vim +/framer_get +184 include/linux/framer/framer.h

82c944d05b1a24 Herve Codina 2023-11-28 183
82c944d05b1a24 Herve Codina 2023-11-28 @184 struct framer *framer_get(struct device *dev, const char *con_id)
82c944d05b1a24 Herve Codina 2023-11-28 185 {
82c944d05b1a24 Herve Codina 2023-11-28 186 return ERR_PTR(-ENOSYS);
82c944d05b1a24 Herve Codina 2023-11-28 187 }
82c944d05b1a24 Herve Codina 2023-11-28 188
82c944d05b1a24 Herve Codina 2023-11-28 @189 void framer_put(struct device *dev, struct framer *framer)
82c944d05b1a24 Herve Codina 2023-11-28 190 {
82c944d05b1a24 Herve Codina 2023-11-28 191 }
82c944d05b1a24 Herve Codina 2023-11-28 192

:::::: The code at line 184 was first introduced by commit
:::::: 82c944d05b1a24c76948ee9d6bb1d7de1ebb8b3a net: wan: Add framer framework support

:::::: TO: Herve Codina <herve.codina@xxxxxxxxxxx>
:::::: CC: Linus Walleij <linus.walleij@xxxxxxxxxx>

--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki