Re: SVR4 STREAMS (for example LiS)

From: Luciano Miguel Ferreira Rocha (luciano@lsd.di.uminho.pt)
Date: Mon Jul 21 2003 - 09:50:42 EST


On Mon, Jul 21, 2003 at 10:38:38AM -0400, Richard B. Johnson wrote:
> Streams are an extension of buffered I/O implimented by the 'C'
> runtime library. Streams really have nothing to do with the
> internal workings of kernel I/O. As far as kernel I/O goes,
> one reads() and writes() from user-space.

Actually, SysV Streams do.

An ex, for openning a pty, on svr4:
fds = open(pts_name, O_RDWR)
ioctl(fds, I_PUSH, "ptem")
ioctl(fds, I_PUSH, "ldterm")
ioctl(fds, I_PUSH, "ttcompat")

Where ptem, ldterm, ttcompat work as independent modules converting the
stream, resulting in a pseudo-terminal implementation.

New programs should just use openpty directly, and let libc take care
of the actual implementation.

Also, BSD sockets were implemented using streams also, thus the compatibility
libraries.

Anyway, I see no point in caring wether streams are used or not in normal
programs.

Regards,
Luciano Rocha
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Wed Jul 23 2003 - 22:00:43 EST