From: Bruce Richardson Date: Tue, 28 May 2019 11:07:47 +0000 (+0100) Subject: mem: mark unused function in 32-bit builds X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=be9d80d4df05715181e01cce79c5c82a9c36d6d5;p=dpdk.git mem: mark unused function in 32-bit builds The get_socket_mem_size() function is only used in 64-bit builds, causing clang to warn about it for 32-bit builds. Add the __rte_unused attribute to the function to silence the warning. Signed-off-by: Bruce Richardson Acked-by: Luca Boccassi --- diff --git a/lib/librte_eal/linux/eal/eal_memory.c b/lib/librte_eal/linux/eal/eal_memory.c index 40a0f687ad..1853acea52 100644 --- a/lib/librte_eal/linux/eal/eal_memory.c +++ b/lib/librte_eal/linux/eal/eal_memory.c @@ -1088,6 +1088,7 @@ remap_needed_hugepages(struct hugepage_file *hugepages, int n_pages) return 0; } +__rte_unused /* function is unused on 32-bit builds */ static inline uint64_t get_socket_mem_size(int socket) {