[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Google SOC project POSIXFIFOs
- Date: Fri, 21 Mar 2008 01:13:20 +0800
- From: cquark at gmail.com (Wei Shen)
- Subject: Google SOC project POSIXFIFOs
Thanks for the reply and suggestion.
> Hmm... read that carefully.. it said you MIGHT be able to refactor the
> buffering code out of termios into a common ring buffer handler. It
also said that it might be impossible because the canonical character
processing might be too intertwined.
I browsed the termios code and feel it is possible to be refactored, but
we may have to add more code that is not needed by termios. I think at
least two new buffer control fields are needed: writers and readers, to
indicate current buffer writer and reader counts respectively (termios
does not need these fields because a writer (e.g. console in the case
of input buffer) and a reader are always presumed to exist).
And, seems that current code (it reads and writes characters one by one
from and to buffers) can be further optimized.
Of cause, still further analysis needed prior to a conclusion.
> The other parts are implementing the required buffering somehow,
> adding the hooks into the IMFS (In-Memory File System), adding tests,
> and making sure everything still works.
I am wondering it is better to implement a virtual pipefs (or say, extract
some common code out to a new module), or to entirely embed it into
IMFS (so may difficult for other FS to use the code)? More work needed...
-------------- next part --------------
An HTML attachment was scrubbed...