summaryrefslogtreecommitdiffstats
path: root/include/linux/sched.h
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2013-10-07 11:29:30 +0100
committerIngo Molnar <mingo@kernel.org>2013-10-09 14:48:04 +0200
commitb32e86b4301e345611f0446265f782a229faadf6 (patch)
tree8cc0a8b731e63f2b3450f89330d49009374c99fb /include/linux/sched.h
parent7dbd13ed06513b047216a7ffc718bad9df0660f1 (diff)
downloadop-kernel-dev-b32e86b4301e345611f0446265f782a229faadf6.zip
op-kernel-dev-b32e86b4301e345611f0446265f782a229faadf6.tar.gz
sched/numa: Add debugging
Signed-off-by: Ingo Molnar <mingo@kernel.org> Reviewed-by: Rik van Riel <riel@redhat.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Mel Gorman <mgorman@suse.de> Cc: Srikar Dronamraju <srikar@linux.vnet.ibm.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Signed-off-by: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Ingo Molnar <mingo@kernel.org> Link: http://lkml.kernel.org/r/1381141781-10992-53-git-send-email-mgorman@suse.de
Diffstat (limited to 'include/linux/sched.h')
-rw-r--r--include/linux/sched.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h
index f638510..1127a46 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -1366,6 +1366,7 @@ struct task_struct {
unsigned long *numa_faults_buffer;
int numa_preferred_nid;
+ unsigned long numa_pages_migrated;
#endif /* CONFIG_NUMA_BALANCING */
struct rcu_head rcu;
@@ -2661,6 +2662,11 @@ static inline unsigned int task_cpu(const struct task_struct *p)
return task_thread_info(p)->cpu;
}
+static inline int task_node(const struct task_struct *p)
+{
+ return cpu_to_node(task_cpu(p));
+}
+
extern void set_task_cpu(struct task_struct *p, unsigned int cpu);
#else
OpenPOWER on IntegriCloud