The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
From: Bakul Shah <bakul@iitbombay.org>
To: The Eunuchs Hysterical Society <tuhs@tuhs.org>
Subject: Re: [TUHS] VFS prior to 1984
Date: Tue, 23 Jun 2020 22:33:56 -0700	[thread overview]
Message-ID: <F5B5B0FA-CAFA-40B1-B622-4DBA158B34C2@iitbombay.org> (raw)
In-Reply-To: <alpine.BSF.2.21.9999.2006241448080.46505@aneurin.horsfall.org>

On Jun 23, 2020, at 10:10 PM, Dave Horsfall <dave@horsfall.org> wrote:
> 
> On Tue, 23 Jun 2020, Warner Losh wrote:
> 
>> > Ioctl: the Swiss Army knife of system calls.  I thought it was a neat > idea when it arrived (much better then those primitive stty/gtty > calls) but now...
>> More like the swiss army chainsaw with engine trouble and a dull blade....
> 
> (Slowly drifting off-topic (as all mailing lists do) so perhaps a new thread would be better.)
> 
> Love it!  On the other hand though, if an extra service is required of the OS and you don't want to extend ioctl(), then that means Yet Another System Call (tm).  I really like the idea of /proc, so if there's an equivalent for ioctl() then I'd love to see it; /sys would be an obvious choice, but it's already taken (Harris' Lament).
> 
> No doubt, someone will now chime in and say that there's an existing mechanism involving shared memory or something...  My Unix-fu is getting rather long in the tooth now (just like me).

plan9 has ctl devices that accept commands as ascii strings and mostly
return results as ascii strings too. Very handy. For example if you have
a optical disk drive you can send commands via its ctl device. There is
no technical reason why this model can't be adapted in Unix.

The fact is that the Unix byte/block read/write model goes only so far.
Every device has its own peculiarities that need to be queried or
controlled. And then there are controllers or USB device treees where
you can hang useful devices at varius places. Bottom line: while dealing
with real devices you can push this complexity around. You can't make it
disappear. At one point a friend and I were looking at building a
product using plan9 and one of the things I wanted to do was to make
sure that the "ctl" file for every device responded to a "help" message
that yielded one line per command and "help <command>" for more details.
That way you can discover their capabilities at runtime.

  reply	other threads:[~2020-06-24  5:34 UTC|newest]

Thread overview: 56+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-23 22:17 Norman Wilson
2020-06-23 22:24 ` Dave Horsfall
2020-06-24  4:09   ` Warner Losh
2020-06-24  5:10     ` Dave Horsfall
2020-06-24  5:33       ` Bakul Shah [this message]
2020-06-24  9:10         ` Andrew Warkentin
  -- strict thread matches above, loose matches on Subject: below --
2020-06-29  9:11 Paul Ruizendaal
2020-06-29 14:45 ` Larry McVoy
2020-06-29 14:53   ` Paul Ruizendaal
2020-06-29 15:14     ` Larry McVoy
2020-06-29 16:34 ` Heinz Lycklama
2020-06-25 20:25 Noel Chiappa
2020-06-26  5:49 ` Lars Brinkhoff
2020-06-26  8:34   ` Dave Horsfall
2020-06-26 11:13     ` arnold
2020-06-25 20:23 Noel Chiappa
2020-06-25 19:31 Noel Chiappa
2020-06-24 18:31 Norman Wilson
2020-06-25  6:22 ` arnold
2020-06-24 17:51 Noel Chiappa
2020-06-24 18:13 ` Richard Salz
2020-06-24 18:46   ` Lars Brinkhoff
2020-06-24 14:31 Noel Chiappa
2020-06-24 15:21 ` Clem Cole
2020-06-23  9:09 Paul Ruizendaal
2020-06-23 14:01 ` Larry McVoy
2020-06-23 15:12   ` Clem Cole
2020-06-23 15:55     ` Rich Morin
2020-06-23 20:38     ` Rob Pike
2020-06-23 20:57       ` Larry McVoy
2020-06-24  5:14       ` arnold
2020-06-24 21:08         ` Dave Horsfall
2020-06-24 19:30       ` Clem Cole
2020-06-24 19:36     ` Larry McVoy
2020-06-25  6:52       ` Rob Gingell
2020-07-05  0:05       ` Dave Horsfall
2020-07-05  0:16         ` Larry McVoy
2020-07-06  4:42           ` Dave Horsfall
2020-07-06 16:51           ` Chris Torek
2020-07-07  1:07             ` Bakul Shah
2020-07-05  1:43         ` Clem Cole
2020-07-05 14:43           ` Larry McVoy
2020-07-05 18:40             ` Arthur Krewat
2020-07-05 20:08             ` Clem Cole
2020-07-05 20:42               ` John Cowan
2020-07-05 21:04                 ` Clem Cole
2020-07-05 21:14                   ` Dan Cross
2020-06-24 16:51 ` Anthony Martin
2020-06-24 17:31   ` Anthony Martin
2020-06-24 18:31   ` Paul Ruizendaal
2020-06-25  0:56     ` Rob Gingell via TUHS
2020-06-24 19:05   ` Paul Ruizendaal
2020-06-24 20:27 ` Derek Fawcus
2020-06-24 21:33 ` Greg A. Woods
2020-06-25  0:45   ` Adam Thornton
2020-06-25 19:40     ` Greg A. Woods

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=F5B5B0FA-CAFA-40B1-B622-4DBA158B34C2@iitbombay.org \
    --to=bakul@iitbombay.org \
    --cc=tuhs@tuhs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).