From: Thadeu Lima de Souza Cascardo Date: Thu, 20 May 2010 21:52:28 +0000 (-0400) Subject: Use schedule. X-Git-Url: http://git.cascardo.eti.br/?p=cascardo%2Fkernel%2Fsamples%2Fchar2%2F.git;a=commitdiff_plain;h=6a496796cb3b3b77abc8d429b2cb0aa7cb70be6b Use schedule. --- diff --git a/hellochar.c b/hellochar.c index a197a1d..c3f26dc 100644 --- a/hellochar.c +++ b/hellochar.c @@ -41,7 +41,7 @@ static ssize_t hello_read(struct file *fp, char __user *buf, size_t sz, { unsigned long expire = jiffies + 5 * HZ; while (time_after(expire, jiffies)) - cpu_relax(); + schedule(); return 0; }