1 /* SPDX-License-Identifier: GPL-2.0 */ 1 /* SPDX-License-Identifier: GPL-2.0 */ 2 #ifndef _LINUX_NUMA_H 2 #ifndef _LINUX_NUMA_H 3 #define _LINUX_NUMA_H 3 #define _LINUX_NUMA_H 4 4 5 5 6 #ifdef CONFIG_NODES_SHIFT 6 #ifdef CONFIG_NODES_SHIFT 7 #define NODES_SHIFT CONFIG_NODES_SHIFT 7 #define NODES_SHIFT CONFIG_NODES_SHIFT 8 #else 8 #else 9 #define NODES_SHIFT 0 9 #define NODES_SHIFT 0 10 #endif 10 #endif 11 11 12 #define MAX_NUMNODES (1 << NODES_SHIFT) 12 #define MAX_NUMNODES (1 << NODES_SHIFT) 13 13 14 #define NUMA_NO_NODE (-1) 14 #define NUMA_NO_NODE (-1) 15 15 16 static inline bool numa_valid_node(int nid) << 17 { << 18 return nid >= 0 && nid < MAX_NUMNODES; << 19 } << 20 << 21 #endif /* _LINUX_NUMA_H */ 16 #endif /* _LINUX_NUMA_H */ 22 17
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.