tree: https://gitee.com/openeuler/kernel.git OLK-6.6 head: 5394cae209c4a4990d81be436ba17ae56fb09d16 commit: 9990ed08ad3b5049b5eb594c2e5ea53cb2cc6ffa [3075/3075] ub:ubus: Support for UB routing table configuration function config: arm64-allmodconfig (https://download.01.org/0day-ci/archive/20251103/202511030449.YeWYye2b-lkp@i...) compiler: clang version 19.1.7 (https://github.com/llvm/llvm-project cd708029e0b2869e80abe31ddb175f7c35361f90) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251103/202511030449.YeWYye2b-lkp@i...) 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/202511030449.YeWYye2b-lkp@intel.com/ All warnings (new ones prefixed by >>):
drivers/ub/ubus/route.c:96:6: warning: no previous prototype for function 'ub_route_clear' [-Wmissing-prototypes] 96 | void ub_route_clear(struct ub_entity *uent) | ^ drivers/ub/ubus/route.c:96:1: note: declare 'static' if the function is not intended to be used outside of this translation unit 96 | void ub_route_clear(struct ub_entity *uent) | ^ | static drivers/ub/ubus/route.c:109:5: warning: no previous prototype for function 'ub_route_add_entry' [-Wmissing-prototypes] 109 | int ub_route_add_entry(struct ub_port *port, u32 cna, short distance) | ^ drivers/ub/ubus/route.c:109:1: note: declare 'static' if the function is not intended to be used outside of this translation unit 109 | int ub_route_add_entry(struct ub_port *port, u32 cna, short distance) | ^ | static drivers/ub/ubus/route.c:144:6: warning: no previous prototype for function 'ub_route_sync_dev' [-Wmissing-prototypes] 144 | void ub_route_sync_dev(struct ub_entity *uent) | ^ drivers/ub/ubus/route.c:144:1: note: declare 'static' if the function is not intended to be used outside of this translation unit 144 | void ub_route_sync_dev(struct ub_entity *uent) | ^ | static 3 warnings generated. -- drivers/ub/ubus/route.c:141: warning: This comment starts with '/**', but isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst * after updating routing table in software, this function must be called
vim +/ub_route_clear +96 drivers/ub/ubus/route.c 95
96 void ub_route_clear(struct ub_entity *uent) 97 { 98 struct ub_port *port; 99 100 if (!uent) 101 return; 102 103 for_each_uent_port(port, uent) 104 bitmap_clear(port->cna_maps, 0, UB_ROUTE_TABLE_ENTRY_BITS); 105 106 ub_clear_cna_list(&uent->cna_list); 107 } 108 109 int ub_route_add_entry(struct ub_port *port, u32 cna, short distance) 110 { 111 if (!port) 112 return -EINVAL; 113 114 if (test_bit(cna, port->cna_maps)) 115 return -EEXIST; 116 117 set_bit(cna, port->cna_maps); 118 return ub_add_cna_node(cna, distance, &port->uent->cna_list); 119 } 120 121 static void ub_set_route_table_entry(struct ub_entity *uent, u32 dst_cna, 122 u32 *route_table_entry) 123 { 124 int i; 125 u32 offset; 126 127 /* Routing Table Block is not required for single-port devices. */ 128 if (uent->port_nums == 1) 129 return; 130 131 pr_info("cna %#x uent set dstcna %#x route\n", uent->cna, dst_cna); 132 133 for (i = 0; i < EBW(uent->port_nums); i++) { 134 offset = ((dst_cna + 1) * EBW(uent->port_nums) + i) << SZ_2; 135 ub_cfg_write_dword(uent, UB_ROUTE_TABLE_ENTRY_START + offset, 136 route_table_entry[i]); 137 } 138 } 139 140 /** 141 * after updating routing table in software, this function must be called 142 * to sync the software routing table to config space 143 */ 144 void ub_route_sync_dev(struct ub_entity *uent)
-- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki