lkml.org 
[lkml]   [1999]   [Aug]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Async user space notification from kernel?
On Thu, Aug 26, 1999 at 12:08:20PM -0600, Erik Andersen wrote:

> Any hints as to what file_ops are needed to support select?
> Clearly read and write are not sufficient. flush? poll?

From looking at some old code I wrote, what you need to change is the poll
hook, of file_operations. I had some working code who used both this
approach and a wait-on-read approach, and it works quite fine.

(You actually don't need read() and write() if you don't want them. And if
you want to get data from the device just use read() - you don't
need select(), unless you wish to enjoy the timeout option).

By the way, why are you calling this an 'async event'? This is very much a
synchronous event. A signal is an asynchronous one.
Unless I'm missing some terminology here.

Nimrod

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:53    [W:0.050 / U:18.596 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site