Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

libeth, libie: clean symbol exports up a little

Change EXPORT_SYMBOL_NS_GPL(x, "LIBETH") to EXPORT_SYMBOL_GPL(x) +
DEFAULT_SYMBOL_NAMESPACE "LIBETH" to make the code more compact.
Also, explicitly include <linux/export.h> to satisfy new
requirements from scripts/misc-check.

Signed-off-by: Alexander Lobakin <aleksander.lobakin@intel.com>
Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>

authored by

Alexander Lobakin and committed by
Tony Nguyen
359bcf15 8909f5f4

+14 -7
+9 -5
drivers/net/ethernet/intel/libeth/rx.c
··· 1 1 // SPDX-License-Identifier: GPL-2.0-only 2 - /* Copyright (C) 2024 Intel Corporation */ 2 + /* Copyright (C) 2024-2025 Intel Corporation */ 3 + 4 + #define DEFAULT_SYMBOL_NAMESPACE "LIBETH" 5 + 6 + #include <linux/export.h> 3 7 4 8 #include <net/libeth/rx.h> 5 9 ··· 190 186 191 187 return -ENOMEM; 192 188 } 193 - EXPORT_SYMBOL_NS_GPL(libeth_rx_fq_create, "LIBETH"); 189 + EXPORT_SYMBOL_GPL(libeth_rx_fq_create); 194 190 195 191 /** 196 192 * libeth_rx_fq_destroy - destroy a &page_pool created by libeth ··· 201 197 kvfree(fq->fqes); 202 198 page_pool_destroy(fq->pp); 203 199 } 204 - EXPORT_SYMBOL_NS_GPL(libeth_rx_fq_destroy, "LIBETH"); 200 + EXPORT_SYMBOL_GPL(libeth_rx_fq_destroy); 205 201 206 202 /** 207 203 * libeth_rx_recycle_slow - recycle a libeth page from the NAPI context ··· 213 209 { 214 210 page_pool_recycle_direct(page->pp, page); 215 211 } 216 - EXPORT_SYMBOL_NS_GPL(libeth_rx_recycle_slow, "LIBETH"); 212 + EXPORT_SYMBOL_GPL(libeth_rx_recycle_slow); 217 213 218 214 /* Converting abstract packet type numbers into a software structure with 219 215 * the packet parameters to do O(1) lookup on Rx. ··· 255 251 pt->hash_type |= libeth_rx_pt_xdp_iprot[pt->inner_prot]; 256 252 pt->hash_type |= libeth_rx_pt_xdp_pl[pt->payload_layer]; 257 253 } 258 - EXPORT_SYMBOL_NS_GPL(libeth_rx_pt_gen_hash_type, "LIBETH"); 254 + EXPORT_SYMBOL_GPL(libeth_rx_pt_gen_hash_type); 259 255 260 256 /* Module */ 261 257
+5 -2
drivers/net/ethernet/intel/libie/rx.c
··· 1 1 // SPDX-License-Identifier: GPL-2.0-only 2 - /* Copyright (C) 2024 Intel Corporation */ 2 + /* Copyright (C) 2024-2025 Intel Corporation */ 3 3 4 + #define DEFAULT_SYMBOL_NAMESPACE "LIBIE" 5 + 6 + #include <linux/export.h> 4 7 #include <linux/net/intel/libie/rx.h> 5 8 6 9 /* O(1) converting i40e/ice/iavf's 8/10-bit hardware packet type to a parsed ··· 119 116 LIBIE_RX_PT_IP(4), 120 117 LIBIE_RX_PT_IP(6), 121 118 }; 122 - EXPORT_SYMBOL_NS_GPL(libie_rx_pt_lut, "LIBIE"); 119 + EXPORT_SYMBOL_GPL(libie_rx_pt_lut); 123 120 124 121 MODULE_DESCRIPTION("Intel(R) Ethernet common library"); 125 122 MODULE_IMPORT_NS("LIBETH");