diff options
author | Anton Vorontsov <cbouatmailru@gmail.com> | 2010-04-26 13:56:19 -0400 |
---|---|---|
committer | Anton Vorontsov <cbouatmailru@gmail.com> | 2010-04-26 13:56:19 -0400 |
commit | 8ef1bb539203629f77a61976e4f25415e1083bff (patch) | |
tree | 4fee25aca0928f112716fb02d27b1b355d0843b4 /kernel/sched.c | |
parent | a3bcbbee83f55cbaec9b2ad748e7300c7feb2192 (diff) | |
parent | b91ce4d14a21fc04d165be30319541e0f9204f15 (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'kernel/sched.c')
-rw-r--r-- | kernel/sched.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/sched.c b/kernel/sched.c index 528a10592c16..6af210a7de70 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
@@ -71,6 +71,7 @@ | |||
71 | #include <linux/debugfs.h> | 71 | #include <linux/debugfs.h> |
72 | #include <linux/ctype.h> | 72 | #include <linux/ctype.h> |
73 | #include <linux/ftrace.h> | 73 | #include <linux/ftrace.h> |
74 | #include <linux/slab.h> | ||
74 | 75 | ||
75 | #include <asm/tlb.h> | 76 | #include <asm/tlb.h> |
76 | #include <asm/irq_regs.h> | 77 | #include <asm/irq_regs.h> |
@@ -4902,7 +4903,7 @@ SYSCALL_DEFINE3(sched_getaffinity, pid_t, pid, unsigned int, len, | |||
4902 | int ret; | 4903 | int ret; |
4903 | cpumask_var_t mask; | 4904 | cpumask_var_t mask; |
4904 | 4905 | ||
4905 | if (len < nr_cpu_ids) | 4906 | if ((len * BITS_PER_BYTE) < nr_cpu_ids) |
4906 | return -EINVAL; | 4907 | return -EINVAL; |
4907 | if (len & (sizeof(unsigned long)-1)) | 4908 | if (len & (sizeof(unsigned long)-1)) |
4908 | return -EINVAL; | 4909 | return -EINVAL; |