Add odp_cpu_socket_id() and odp_cpu_socket_id_cpu() routines
Signed-off-by: Bill Fischofer <[email protected]>
---
include/odp/api/cpu.h | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)
diff --git a/include/odp/api/cpu.h b/include/odp/api/cpu.h
index 4cbaf58..fe74825 100644
--- a/include/odp/api/cpu.h
+++ b/include/odp/api/cpu.h
@@ -36,6 +36,29 @@ extern "C" {
int odp_cpu_id(void);
/**
+ * CPU socket id
+ *
+ * Returns the socket id associated with the calling CPU on NUMA systems.
+ * Socket ID numbering is system specific.
+ *
+ * @return Socket ID of the calling CPU
+ * @retval ODP_SOCKET_ID_ANY If the caller is not running on a NUMA system.
+ */
+uint32_t odp_cpu_socket_id(void);
+
+/**
+ * CPU socket id of designated CPU
+ *
+ * Returns the socket id associated with a specified CPU on NUMA systems.
+ * Socket ID numbering is system specific.
+ *
+ * @return Socket ID of the designated CPU
+ * @retval ODP_SOCKET_ID_ANY If the specified CPU is unknown or caller is
+ * not running on a NUMA system.
+ */
+uint32_t odp_cpu_socket_id_cpu(int cpu_id);
+
+/**
* CPU count
*
* Report the number of CPU's available to this ODP program.
--
2.5.0
_______________________________________________
lng-odp mailing list
[email protected]
https://lists.linaro.org/mailman/listinfo/lng-odp