]> git.neil.brown.name Git - history.git/commitdiff
Remove busy-wait for short RT nanosleeps. It's a random special case
authorLinus Torvalds <torvalds@home.transmeta.com>
Wed, 25 Sep 2002 14:04:43 +0000 (07:04 -0700)
committerLinus Torvalds <torvalds@home.transmeta.com>
Wed, 25 Sep 2002 14:04:43 +0000 (07:04 -0700)
and does the wrong thing for higher HZ values anyway.

kernel/timer.c

index 3b4be840f93165df6df19dc6b0393dc911ca2971..55c14c11c9015209ca7ba8bf3e23414b77e13769 100644 (file)
@@ -888,20 +888,6 @@ asmlinkage long sys_nanosleep(struct timespec *rqtp, struct timespec *rmtp)
        if (t.tv_nsec >= 1000000000L || t.tv_nsec < 0 || t.tv_sec < 0)
                return -EINVAL;
 
-
-       if (t.tv_sec == 0 && t.tv_nsec <= 2000000L &&
-           current->policy != SCHED_NORMAL)
-       {
-               /*
-                * Short delay requests up to 2 ms will be handled with
-                * high precision by a busy wait for all real-time processes.
-                *
-                * Its important on SMP not to do this holding locks.
-                */
-               udelay((t.tv_nsec + 999) / 1000);
-               return 0;
-       }
-
        expire = timespec_to_jiffies(&t) + (t.tv_sec || t.tv_nsec);
 
        current->state = TASK_INTERRUPTIBLE;