eal: hide internal function

Message ID 1564574853-10533-1-git-send-email-david.marchand@redhat.com (mailing list archive)
State Accepted, archived
Delegated to: Thomas Monjalon
Headers
Series eal: hide internal function |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/iol-Compile-Testing success Compile Testing PASS
ci/Intel-compilation success Compilation OK
ci/mellanox-Performance-Testing success Performance Testing PASS

Commit Message

David Marchand July 31, 2019, 12:07 p.m. UTC
  This function has never been used outside of this code unit.
Mark it static and remove it from the eal internal header.

Fixes: 9e29251b2afa ("eal: thread affinity API")
Cc: stable@dpdk.org

Signed-off-by: David Marchand <david.marchand@redhat.com>
---
 lib/librte_eal/common/eal_common_thread.c |  3 ++-
 lib/librte_eal/common/eal_thread.h        | 11 -----------
 2 files changed, 2 insertions(+), 12 deletions(-)
  

Comments

Thomas Monjalon Aug. 5, 2019, 9:55 a.m. UTC | #1
31/07/2019 14:07, David Marchand:
> This function has never been used outside of this code unit.
> Mark it static and remove it from the eal internal header.
> 
> Fixes: 9e29251b2afa ("eal: thread affinity API")
> Cc: stable@dpdk.org
> 
> Signed-off-by: David Marchand <david.marchand@redhat.com>

Applied, thanks
  

Patch

diff --git a/lib/librte_eal/common/eal_common_thread.c b/lib/librte_eal/common/eal_common_thread.c
index c91aba8..f9a8cf1 100644
--- a/lib/librte_eal/common/eal_common_thread.c
+++ b/lib/librte_eal/common/eal_common_thread.c
@@ -38,7 +38,8 @@  rte_lcore_has_role(unsigned int lcore_id, enum rte_lcore_role_t role)
 	return cfg->lcore_role[lcore_id] == role;
 }
 
-int eal_cpuset_socket_id(rte_cpuset_t *cpusetp)
+static int
+eal_cpuset_socket_id(rte_cpuset_t *cpusetp)
 {
 	unsigned cpu = 0;
 	int socket_id = SOCKET_ID_ANY;
diff --git a/lib/librte_eal/common/eal_thread.h b/lib/librte_eal/common/eal_thread.h
index 2d30b19..0d0bad0 100644
--- a/lib/librte_eal/common/eal_thread.h
+++ b/lib/librte_eal/common/eal_thread.h
@@ -35,17 +35,6 @@  void eal_thread_init_master(unsigned lcore_id);
 unsigned eal_cpu_socket_id(unsigned cpu_id);
 
 /**
- * Get the NUMA socket id from cpuset.
- * This function is private to EAL.
- *
- * @param cpusetp
- *   The point to a valid cpu set.
- * @return
- *   socket_id or SOCKET_ID_ANY
- */
-int eal_cpuset_socket_id(rte_cpuset_t *cpusetp);
-
-/**
  * Default buffer size to use with eal_thread_dump_affinity()
  */
 #define RTE_CPU_AFFINITY_STR_LEN            256