Hi Linyu, Thank you for the patch! Yet something to improve: [auto build test ERROR on usb/usb-testing] [also build test ERROR on v5.18-rc6 next-20220506] [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/intel-lab-lkp/linux/commits/Linyu-Yuan/usb-gadget-update-DECLARE_USB_FUNCTION-_INIT-macro/20220509-144542 base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-testing config: mips-randconfig-r024-20220509 (https://download.01.org/0day-ci/archive/20220509/202205091746.HoR8ueL5-lkp@xxxxxxxxx/config) compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project a385645b470e2d3a1534aae618ea56b31177639f) 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 mips cross compiling tool for clang build # apt-get install binutils-mips-linux-gnu # https://github.com/intel-lab-lkp/linux/commit/5c9f589ea23bf995436cde6bd39f1c5b2cc1ec4f git remote add linux-review https://github.com/intel-lab-lkp/linux git fetch --no-tags linux-review Linyu-Yuan/usb-gadget-update-DECLARE_USB_FUNCTION-_INIT-macro/20220509-144542 git checkout 5c9f589ea23bf995436cde6bd39f1c5b2cc1ec4f # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=mips SHELL=/bin/bash drivers/usb/gadget/function/ If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@xxxxxxxxx> All errors (new ones prefixed by >>): >> drivers/usb/gadget/function/f_tcm.c:2313:31: error: use of undeclared identifier 'tcmusb_func'; did you mean 'tcm_usb_func'? ret = usb_function_register(&tcmusb_func); ^~~~~~~~~~~ tcm_usb_func drivers/usb/gadget/function/f_tcm.c:2307:1: note: 'tcm_usb_func' declared here DECLARE_USB_FUNCTION(tcm, tcm_alloc_inst, tcm_alloc); ^ include/linux/usb/composite.h:614:36: note: expanded from macro 'DECLARE_USB_FUNCTION' static struct usb_function_driver _name ## _usb_func = { \ ^ <scratch space>:20:1: note: expanded from here tcm_usb_func ^ drivers/usb/gadget/function/f_tcm.c:2319:28: error: use of undeclared identifier 'tcmusb_func'; did you mean 'tcm_usb_func'? usb_function_unregister(&tcmusb_func); ^~~~~~~~~~~ tcm_usb_func drivers/usb/gadget/function/f_tcm.c:2307:1: note: 'tcm_usb_func' declared here DECLARE_USB_FUNCTION(tcm, tcm_alloc_inst, tcm_alloc); ^ include/linux/usb/composite.h:614:36: note: expanded from macro 'DECLARE_USB_FUNCTION' static struct usb_function_driver _name ## _usb_func = { \ ^ <scratch space>:20:1: note: expanded from here tcm_usb_func ^ drivers/usb/gadget/function/f_tcm.c:2328:27: error: use of undeclared identifier 'tcmusb_func'; did you mean 'tcm_usb_func'? usb_function_unregister(&tcmusb_func); ^~~~~~~~~~~ tcm_usb_func drivers/usb/gadget/function/f_tcm.c:2307:1: note: 'tcm_usb_func' declared here DECLARE_USB_FUNCTION(tcm, tcm_alloc_inst, tcm_alloc); ^ include/linux/usb/composite.h:614:36: note: expanded from macro 'DECLARE_USB_FUNCTION' static struct usb_function_driver _name ## _usb_func = { \ ^ <scratch space>:20:1: note: expanded from here tcm_usb_func ^ 3 errors generated. vim +2313 drivers/usb/gadget/function/f_tcm.c dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2308 dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2309 static int tcm_init(void) dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2310 { dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2311 int ret; dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2312 dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 @2313 ret = usb_function_register(&tcmusb_func); dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2314 if (ret) dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2315 return ret; dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2316 dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2317 ret = target_register_template(&usbg_ops); dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2318 if (ret) dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2319 usb_function_unregister(&tcmusb_func); dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2320 dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2321 return ret; dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2322 } dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2323 module_init(tcm_init); dc8c46a5ae770d Andrzej Pietrasiewicz 2015-12-11 2324 -- 0-DAY CI Kernel Test Service https://01.org/lkp