]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
Fix units in mbind patch
authorChris Wright <chrisw@sous-sol.org>
Tue, 21 Feb 2006 01:18:44 +0000 (17:18 -0800)
committerChris Wright <chrisw@sous-sol.org>
Tue, 21 Feb 2006 01:18:44 +0000 (17:18 -0800)
queue/sys_mbind-sanity-checking.patch

index 9f9d4645bdbf89c2a2ba0a1999bdaa03c6a9ec7f..c6ad544369cdd650d23349c45cd124b78c993ad2 100644 (file)
@@ -8,6 +8,8 @@ get_nodes().
 
 Signed-off-by: Chris Wright <chrisw@sous-sol.org>
 Signed-off-by: Linus Torvalds <torvalds@osdl.org>
+[chrisw: fix units, pointed out by Andi]
+Cc: Andi Kleen <ak@suse.de>
 ---
 
  mm/mempolicy.c |    2 ++
@@ -19,7 +21,7 @@ Signed-off-by: Linus Torvalds <torvalds@osdl.org>
        nodes_clear(*nodes);
        if (maxnode == 0 || !nmask)
                return 0;
-+      if (maxnode > PAGE_SIZE)
++      if (maxnode > PAGE_SIZE*BITS_PER_BYTE)
 +              return -EINVAL;
  
        nlongs = BITS_TO_LONGS(maxnode);