vserver 1.9.5.x5
[linux-2.6.git] / fs / select.c
index dfff0ad..1de9b6a 100644 (file)
@@ -14,6 +14,7 @@
  *     of fds to overcome nfds < 16390 descriptors limit (Tigran Aivazian).
  */
 
+#include <linux/syscalls.h>
 #include <linux/module.h>
 #include <linux/slab.h>
 #include <linux/smp_lock.h>
@@ -239,6 +240,7 @@ int do_select(int n, fd_set_bits *fds, long *timeout)
                                                retval++;
                                        }
                                }
+                               cond_resched();
                        }
                        if (res_in)
                                *rinp = res_in;
@@ -267,8 +269,6 @@ int do_select(int n, fd_set_bits *fds, long *timeout)
        return retval;
 }
 
-EXPORT_SYMBOL(do_select);
-
 static void *select_bits_alloc(int size)
 {
        return kmalloc(6 * size, GFP_KERNEL);