public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Nix <nix@esperi.org.uk>
To: fawadlateef@gmail.com
Cc: ivan.korzakow@gmail.com, linux-kernel@vger.kernel.org
Subject: Re: best way to access device driver functions
Date: Fri, 16 Sep 2005 13:59:22 +0100	[thread overview]
Message-ID: <87mzmduq1h.fsf@amaterasu.srvr.nix> (raw)
In-Reply-To: <1e62d13705091508391832f897@mail.gmail.com> (Fawad Lateef's message of "15 Sep 2005 16:39:51 +0100")

On 15 Sep 2005, Fawad Lateef stated:
> On 9/15/05, Ivan Korzakow <ivan.korzakow@gmail.com> wrote:
>> Could you explain me why ioctl should be avoided ? Is it going to be
>> deprecated in future kernel ?
> 
> No ioctl are not deprecated, but they are just avoided b/c its not
> good to mess kernel with new system-calls as there is a different way
> for that !!!!

Well, not really; ioctl() is only one system call. They're actually
avoided because ioctl() has a horrible non-typesafe non-transparent
interface. (Quick! What parameters does the CCISS_PASSTHRU32 ioctl()
expect?)

sysfs fixes all of these problems, and adds easy scriptability
and interrogation from the command-line and a nice hierarchy
as well.


New *system calls* are generally avoided (especially if they might be
useful to non-privileged code) because they come with a *very* high
backward compatibility burden: it's pretty much the case that syscalls
that normal programs rely on should never go away. (Syscalls used only
by programs that you expect to change with the kernel, like modutils/
module-init-tools, are a special case.)

-- 
`One cannot, after all, be expected to read every single word
 of a book whose author one wishes to insult.' --- Richard Dawkins

  reply	other threads:[~2005-09-16 12:59 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-09-15  7:48 best way to access device driver functions Ivan Korzakow
2005-09-15  8:03 ` Fawad Lateef
2005-09-15 12:18   ` Ivan Korzakow
2005-09-15 15:39     ` Fawad Lateef
2005-09-16 12:59       ` Nix [this message]
2005-09-16 14:07         ` Arjan van de Ven
2005-09-16 15:24           ` Nix
2005-09-16 16:02             ` linux-os (Dick Johnson)
2005-09-16 18:30               ` Kyle Moffett
2005-09-16 19:20                 ` linux-os (Dick Johnson)
2005-09-16 19:41                   ` Valdis.Kletnieks
2005-09-16 17:52         ` Alexey Dobriyan

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=87mzmduq1h.fsf@amaterasu.srvr.nix \
    --to=nix@esperi.org.uk \
    --cc=fawadlateef@gmail.com \
    --cc=ivan.korzakow@gmail.com \
    --cc=linux-kernel@vger.kernel.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