linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Ihar 'Philips' Filipau" <filia@softhome.net>
To: Helge Hafting <helge.hafting@hist.no>,
	arjanv@redhat.com, viro@parcelfarce.linux.theplanet.co.uk
Cc: Linux Kernel ML <linux-kernel@vger.kernel.org>
Subject: Re: f_ops flag to speed up compatible ioctls in linux kernel
Date: Wed, 01 Sep 2004 17:28:46 +0200	[thread overview]
Message-ID: <4135EAAE.3030605@softhome.net> (raw)
In-Reply-To: <4135CEB4.5020102@softhome.net>

Ihar 'Philips' Filipau wrote:
> 
> P.P.S. Hm. Why not implement ioctl2()? which will be linked directly to 
> device by its driver? - numbering will be internal to driver, and 
> provide entry point into driver for user space applications. No one 
> likes mess with ioctl()s in Linux - no device driver developers, nor 
> users. But what is really needed - is just call into driver. Paramenter 
> - single pointer have being proved to be sufficient.
> 

   Ok. Now I recalled those mess with ioctl()s - someone have tryed to 
implement virtual methods from OO languages with file descriptors and 
miserably failed.

   I have never used ioctl()s for anything asides calling my drivers. I 
have seens people using ioctl codes for special functionality for block 
devices.

   Position "ioctl()s bad" is not related to drivers per se. People 
decided to not introduce another calls like eject_media(fd) or 
get_info(fd) - but instead implement ioctl() which will magically work 
on all fd's of block devices.
   That where mistake is. That the kind of ioctl()s, which are bad. 
ioctl() is for something what doesn't have interface. If something have 
stable interface - it must be moved over to sys/library calls.

   Instead of "painful ioctl()s" - I would rather start with solving 
this problem for standard devices: making a way to implement efficiently 
common functions for device classes. (terminals, block devices, network 
interfaces, etc). And start obsoleting/removing ioctl()s.

   I like aproach of *BSD - they routinely implement library/sys calls 
for things like that. I used if_*/getif* calls to find/operate network 
interfaces - it is much more usable & better documented, than Linux' 
bunch of magic ioctl()s (again) on _any_ network socket. Why on any? Why 
we cannot have special device to operate on list of interfaces?

   I believe people here on LKML identified problem incorrectly.

  reply	other threads:[~2004-09-01 15:29 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-01  9:50 f_ops flag to speed up compatible ioctls in linux kernel filia
2004-09-01  9:52 ` Arjan van de Ven
2004-09-01 10:16   ` filia
     [not found]     ` <4135B9FC.7050602@hist.no>
2004-09-01 13:29       ` Ihar 'Philips' Filipau
2004-09-01 15:28         ` Ihar 'Philips' Filipau [this message]
2004-09-02  7:29         ` Helge Hafting
2004-09-01 13:43     ` Olivier Galibert
  -- strict thread matches above, loose matches on Subject: below --
2004-12-27 22:22 Michael S. Tsirkin
2004-09-01 15:40 Albert Cahalan
2004-09-01 21:23 ` Michael S. Tsirkin
2004-09-01 21:38   ` Lee Revell
2004-09-01 21:43   ` Chris Wright
2004-09-01 21:44   ` Roland Dreier
2004-09-01 15:36 Albert Cahalan
2004-09-01 15:59 ` Roland Dreier
2004-09-01 21:53   ` Michael S. Tsirkin
2004-09-01 22:58     ` Roland Dreier
2004-09-01 23:18       ` Michael S. Tsirkin
2004-09-01  7:22 Michael S. Tsirkin
2004-09-01  7:32 ` viro
2004-09-01  7:44   ` Michael S. Tsirkin
2004-09-01  7:47   ` Lee Revell
2004-09-01  8:19     ` Michael S. Tsirkin
2004-09-01 15:55   ` Roland Dreier
2004-09-01 18:02     ` Chris Wright
2004-09-01 18:12       ` Roland Dreier
2004-09-01 18:31         ` viro
2004-09-01 20:54       ` Roland Dreier
     [not found]         ` <20040901170800.K1924@build.pdx.osdl.net>
     [not found]           ` <20040901190122.L1924@build.pdx.osdl.net>
2004-09-02  3:46             ` Roland Dreier
2004-09-01 18:06   ` Bill Davidsen
2004-09-01  8:30 ` Arjan van de Ven

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=4135EAAE.3030605@softhome.net \
    --to=filia@softhome.net \
    --cc=arjanv@redhat.com \
    --cc=helge.hafting@hist.no \
    --cc=linux-kernel@vger.kernel.org \
    --cc=viro@parcelfarce.linux.theplanet.co.uk \
    /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).