[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1201308912.7784.6.camel@localhost>
Date: Fri, 25 Jan 2008 17:55:12 -0700
From: Zan Lynx <zlynx@....org>
To: Andreas Dilger <adilger@....com>
Cc: Theodore Tso <tytso@....EDU>, Adrian Bunk <bunk@...nel.org>,
Bodo Eggert <7eggert@....de>,
Alan Cox <alan@...rguk.ukuu.org.uk>, Valdis.Kletnieks@...edu,
David Chinner <dgc@....com>,
Valerie Henson <val@...consulting.com>,
linux-fsdevel@...r.kernel.org, linux-ext4@...r.kernel.org,
linux-kernel@...r.kernel.org, Ric Wheeler <ric@....com>
Subject: Re: [RFC] Parallelize IO for e2fsck
On Fri, 2008-01-25 at 04:09 -0700, Andreas Dilger wrote:
> On Jan 24, 2008 17:25 -0700, Zan Lynx wrote:
> > Have y'all been following the /dev/mem_notify patches?
> > http://article.gmane.org/gmane.linux.kernel/628653
>
> Having the notification be via poll() is a very restrictive processing
> model. Having the notification be via a signal means that any kind of
> process (and not just those that are event loop driven) can register
> a callback at some arbitrary point in the code and be notified. I
> don't object to the poll() interface, but it would be good to have a
> signal mechanism also.
The commentary on the mem_notify threads claimed that the signal is
easily provided by setting up the file handle for SIGIO.
Yeah. Here it is...copied from email written by KOSAKI Motohiro:
implement FASYNC capability to /dev/mem_notify.
<usage example>
fd = open("/dev/mem_notify", O_RDONLY);
fcntl(fd, F_SETOWN, getpid());
flags = fcntl(fd, F_GETFL);
fcntl(fd, F_SETFL, flags|FASYNC); /* when low memory, receive SIGIO */
</usage example>
--
Zan Lynx <zlynx@....org>
Download attachment "signature.asc" of type "application/pgp-signature" (190 bytes)
Powered by blists - more mailing lists