aboutsummaryrefslogtreecommitdiff
path: root/arch/um/drivers/random.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/um/drivers/random.c')
-rw-r--r--arch/um/drivers/random.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/arch/um/drivers/random.c b/arch/um/drivers/random.c
index f9e22198e01..ba471f5864a 100644
--- a/arch/um/drivers/random.c
+++ b/arch/um/drivers/random.c
@@ -58,10 +58,8 @@ static ssize_t rng_dev_read (struct file *filp, char __user *buf, size_t size,
if (filp->f_flags & O_NONBLOCK)
return ret ? : -EAGAIN;
- if(need_resched()){
- current->state = TASK_INTERRUPTIBLE;
- schedule_timeout(1);
- }
+ if(need_resched())
+ schedule_timeout_interruptible(1);
}
else return n;
if (signal_pending (current))