[TUHS] Unix APIs: elegant or not?

Warner Losh imp at bsdimp.com
Fri Nov 2 02:43:54 AEST 2018

On Thu, Nov 1, 2018 at 9:38 AM Clem Cole <clemc at ccc.com> wrote:

> On Thu, Nov 1, 2018 at 10:20 AM ron minnich <rminnich at gmail.com> wrote:
>> In my view, what went wrong with Unix networking 40 years ago is that it
>> broke from the Unix model, i.e. that resources are accessed via path
>> names, and went with binary descriptors as paths.
> Agreed.
> And I think somthing else where P9 differed from UNIX was dealing with OOB
> (control) information (*i.e.* ioctl(2) was a terrible misstake).   Dennis
> and Ken created ioctl(2) with v7 as a generalization of stty/gtty from the
> TTY handler.  At the time, it seemed like a reasonable way to handle those
> 'small things that need to be tweeked - like baud rate or canonicalization;
> but ioctl(2) quickly got abused as the universal end-around, and those
> things caused also sorts of issues (also being a binary interface only
> made it worse, although on the PDP-11 it made sense for size reasons).
>  Creating a seperate interface from the 'file' to orchestrate/control the
> I/O and controlling that as a set of strings not binaries, seems like a
> more sane idea.

There's another school of thought too that says the kernel has no business
parsing strings with all the security implications of doing so...


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://minnie.tuhs.org/pipermail/tuhs/attachments/20181101/c81f720b/attachment.html>

More information about the TUHS mailing list