lkml.org 
[lkml]   [2006]   [Oct]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] Allow a larger buffer for writes to cpuset files
When using fake NUMA setup, the number of memory nodes can greatly
exceed the number of CPUs. So the current limit in
cpuset_common_file_write() is insufficient. PAGE_SIZE is still a bit
of an arbitrary limit, but gives more breathing room.

Signed-off-by: Paul Menage <menage@google.com>

--- 2.6.19-rc2.orig/kernel/cpuset.c
+++ 2.6.19-rc2/kernel/cpuset.c
@@ -1292,7 +1292,7 @@ static ssize_t cpuset_common_file_write(
int retval = 0;

/* Crude upper limit on largest legitimate cpulist user might write. */
- if (nbytes > 100 + 6 * NR_CPUS)
+ if (nbytes >= PAGE_SIZE)
return -E2BIG;

/* +1 for nul-terminator */
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2006-10-31 03:41    [W:0.279 / U:0.056 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site