how to process data recvd from a device that wont give interrupts
devendra.aaru
devendra.aaru at gmail.com
Fri Oct 5 05:46:40 EDT 2012
On Fri, Oct 5, 2012 at 2:32 AM, Kshemendra KP <kshemendra at suphalaam.com> wrote:
>
> Hi Devendra,
>
> In the kernel thread if you continuously in a loop read a register it
> will increase
> the CPU usage. After every register read if data is not ready call a
> schedule() (or related
> call). This may help to reduce CPU utilization
>
[please no top posting],
I Know, i didn't say i use copy_from(to)user in the softirqs. its
wrong, and you can use the copy to (from) user in a different context,
ie our fops callbacks.
coming to threads,
these are also one and the same as your timers,
and your threading is wrong, since there is only register read, should
be checking at every 10 - 20 msec,
so coming back to timers :) no?
anyways thanks for letting me know .
>
More information about the Kernelnewbies
mailing list