--- linux-2.6.3.org/fs/proc/generic.c 2004-02-18 04:59:53.000000000 +0100 +++ linux-2.6.3.test/fs/proc/generic.c 2004-02-26 21:22:52.791857440 +0100 @@ -37,10 +37,6 @@ .write = proc_file_write, }; -#ifndef MIN -#define MIN(a,b) (((a) < (b)) ? (a) : (b)) -#endif - /* buffer size is one page but our output routines use some slack for overruns */ #define PROC_BLOCK_SIZE (PAGE_SIZE - 1024) @@ -61,7 +57,7 @@ return -ENOMEM; while ((nbytes > 0) && !eof) { - count = MIN(PROC_BLOCK_SIZE, nbytes); + count = min_t(ssize_t, PROC_BLOCK_SIZE, nbytes); start = NULL; if (dp->get_info) {