diff options
author | Mike Travis <travis@sgi.com> | 2008-07-09 01:35:21 +0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-13 21:11:58 +0400 |
commit | 11369f356b66d363a615fde2c5526962f7683674 (patch) | |
tree | 9723013073973c413e7cde295e99221ff40afca3 /include/asm-generic/topology.h | |
parent | ce8b06b985ae48f9425de6e4641e77cb3613ef00 (diff) | |
download | linux-11369f356b66d363a615fde2c5526962f7683674.tar.xz |
x86: change _node_to_cpumask_ptr to return const ptr
* Strengthen the return type for the _node_to_cpumask_ptr to be
a const pointer. This adds compiler checking to insure that
node_to_cpumask_map[] is not changed inadvertently.
Signed-off-by: Mike Travis <travis@sgi.com>
Cc: "akpm@linux-foundation.org" <akpm@linux-foundation.org>
Cc: Yinghai Lu <yhlu.kernel@gmail.com>
Acked-by: Vegard Nossum <vegard.nossum@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/asm-generic/topology.h')
-rw-r--r-- | include/asm-generic/topology.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/asm-generic/topology.h b/include/asm-generic/topology.h index a6aea79bca4f..54bbf6e04ee8 100644 --- a/include/asm-generic/topology.h +++ b/include/asm-generic/topology.h @@ -60,7 +60,8 @@ #ifndef node_to_cpumask_ptr #define node_to_cpumask_ptr(v, node) \ - cpumask_t _##v = node_to_cpumask(node), *v = &_##v + cpumask_t _##v = node_to_cpumask(node); \ + const cpumask_t *v = &_##v #define node_to_cpumask_ptr_next(v, node) \ _##v = node_to_cpumask(node) |