diff options
author | Mark Goodwin <markgw@sgi.com> | 2005-08-17 18:17:00 -0400 |
---|---|---|
committer | Tony Luck <tony.luck@intel.com> | 2005-08-24 19:24:42 -0400 |
commit | 60a3ba0bb45995ecf9cfe208527d7cfd6128d053 (patch) | |
tree | 3a510269b2e336f58ecc3735877e60c1677a4b11 /include/asm-ia64/sn/sn2/sn_hwperf.h | |
parent | ecc3c30ae39c4d3cbf249a1ebd599465e0e25708 (diff) |
[IA64] - SGI SN hwperf enhancements -
Add a new exported function for determining the nearest node
with CPUs for I/O nodes and fix a bug where the hwperf dynamic
misc device was being registered before misc_init().
Signed-off-by: Mark Goodwin <markgw@sgi.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
Diffstat (limited to 'include/asm-ia64/sn/sn2/sn_hwperf.h')
-rw-r--r-- | include/asm-ia64/sn/sn2/sn_hwperf.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/asm-ia64/sn/sn2/sn_hwperf.h b/include/asm-ia64/sn/sn2/sn_hwperf.h index df75f4c4aec3..291ef3d69da2 100644 --- a/include/asm-ia64/sn/sn2/sn_hwperf.h +++ b/include/asm-ia64/sn/sn2/sn_hwperf.h | |||
@@ -43,6 +43,7 @@ struct sn_hwperf_object_info { | |||
43 | 43 | ||
44 | /* macros for object classification */ | 44 | /* macros for object classification */ |
45 | #define SN_HWPERF_IS_NODE(x) ((x) && strstr((x)->name, "SHub")) | 45 | #define SN_HWPERF_IS_NODE(x) ((x) && strstr((x)->name, "SHub")) |
46 | #define SN_HWPERF_IS_NODE_SHUB2(x) ((x) && strstr((x)->name, "SHub 2.")) | ||
46 | #define SN_HWPERF_IS_IONODE(x) ((x) && strstr((x)->name, "TIO")) | 47 | #define SN_HWPERF_IS_IONODE(x) ((x) && strstr((x)->name, "TIO")) |
47 | #define SN_HWPERF_IS_ROUTER(x) ((x) && strstr((x)->name, "Router")) | 48 | #define SN_HWPERF_IS_ROUTER(x) ((x) && strstr((x)->name, "Router")) |
48 | #define SN_HWPERF_IS_NL3ROUTER(x) ((x) && strstr((x)->name, "NL3Router")) | 49 | #define SN_HWPERF_IS_NL3ROUTER(x) ((x) && strstr((x)->name, "NL3Router")) |
@@ -214,6 +215,15 @@ struct sn_hwperf_ioctl_args { | |||
214 | */ | 215 | */ |
215 | #define SN_HWPERF_GET_NODE_NASID (102|SN_HWPERF_OP_MEM_COPYOUT) | 216 | #define SN_HWPERF_GET_NODE_NASID (102|SN_HWPERF_OP_MEM_COPYOUT) |
216 | 217 | ||
218 | /* | ||
219 | * Given a node id, determine the id of the nearest node with CPUs | ||
220 | * and the id of the nearest node that has memory. The argument | ||
221 | * node would normally be a "headless" node, e.g. an "IO node". | ||
222 | * Return 0 on success. | ||
223 | */ | ||
224 | extern int sn_hwperf_get_nearest_node(cnodeid_t node, | ||
225 | cnodeid_t *near_mem, cnodeid_t *near_cpu); | ||
226 | |||
217 | /* return codes */ | 227 | /* return codes */ |
218 | #define SN_HWPERF_OP_OK 0 | 228 | #define SN_HWPERF_OP_OK 0 |
219 | #define SN_HWPERF_OP_NOMEM 1 | 229 | #define SN_HWPERF_OP_NOMEM 1 |