From: "Kevin P. Fleming" <kpfleming@cox.net>
To: linux-kernel@vger.kernel.org
Subject: Re: Flaw in the driver-model implementation of attributes
Date: Wed, 18 Jun 2003 17:20:52 -0700 [thread overview]
Message-ID: <3EF101E4.3030900@cox.net> (raw)
In-Reply-To: <20030619000604.19693.qmail@email.com>
Clayton Weaver wrote:
> (Doubting that there is a sysfs faq anywhere
> yet, ...)
Sounds like we're getting there!
>
> What is a sysfs "class", as in /sys/class/...?
It is an abstraction. It is a group of objects that implement common
functionality, and have common attributes and behaviors.
>
> What do sysfs classes have in common? How is
> a /sys/class/ different from a /sys/devices,
> /sys/bus, etc?
/sys/bus, /sys/block are just special-case classes that get their own
top-level directory. They could just easily have been put under
/sys/class/block, /sys/class/bus.
>
> In re: the current discussion, are the "usb-storage" attributes under discussion
> something that the vfs would need to know
> about(/sys/block/)? Something that a pci
> bus would need to know about? Something that
> a usb controller would need to know about?
IMHO, no. Any attributes specific to a usb-storage device are not
something that any other layer would care about. As an example, a
flash-memory USB key I have here support software write protection;
while I don't know if the usb-storage driver currently exposes that, it
could, and that would be very specific to usb-storage. Any userspace
application that wanted to manipulate the state of that protection would
look at /sys/class/usb-storage/... for devices it could potentially
manage. It doesn't need to how or where those devices are connected, or
even what type of media they may be. It only needs to know that they are
usb-storage devices, and that they have a "writeprotect" attribute
exposed in the appropriate place.
next prev parent reply other threads:[~2003-06-19 0:06 UTC|newest]
Thread overview: 46+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-06-19 0:06 Flaw in the driver-model implementation of attributes Clayton Weaver
2003-06-19 0:20 ` Kevin P. Fleming [this message]
2003-06-19 16:46 ` Patrick Mochel
-- strict thread matches above, loose matches on Subject: below --
2003-06-19 21:18 Perez-Gonzalez, Inaky
2003-06-18 19:52 Perez-Gonzalez, Inaky
2003-06-18 7:48 Perez-Gonzalez, Inaky
2003-06-18 8:12 ` viro
2003-06-18 14:32 ` Alan Stern
2003-06-18 17:15 ` Greg KH
2003-06-18 19:50 ` Alan Stern
2003-06-19 16:42 ` Patrick Mochel
2003-06-19 21:18 ` Alan Stern
2003-06-19 14:13 ` Alan Stern
2003-06-19 17:07 ` Patrick Mochel
2003-06-19 21:14 ` Alan Stern
2003-06-19 21:31 ` Greg KH
2003-06-20 14:22 ` Alan Stern
2003-06-20 18:32 ` Greg KH
2003-07-02 22:12 ` Greg KH
2003-07-03 14:51 ` Alan Stern
2003-06-19 17:26 ` Mike Anderson
2003-06-18 3:44 Perez-Gonzalez, Inaky
2003-06-18 4:18 ` viro
[not found] <20030616194446.H13312@flint.arm.linux.org.uk>
2003-06-16 19:36 ` Alan Stern
2003-06-16 20:49 ` Patrick Mochel
2003-06-16 21:29 ` Alan Stern
2003-06-16 22:43 ` Patrick Mochel
2003-06-17 19:49 ` Alan Stern
2003-06-18 1:38 ` Kevin P. Fleming
2003-06-16 23:36 ` Greg KH
2003-06-17 17:29 ` Alan Stern
2003-06-17 17:33 ` Greg KH
2003-06-17 20:20 ` Alan Stern
2003-06-15 16:42 Alan Stern
2003-06-15 17:40 ` Jeremy Fitzhardinge
2003-06-16 14:05 ` Alan Stern
2003-06-16 17:08 ` Greg KH
2003-06-16 17:20 ` Russell King
2003-06-16 17:54 ` Alan Stern
2003-06-16 18:00 ` Patrick Mochel
2003-06-16 18:03 ` viro
2003-06-16 18:23 ` Alan Stern
2003-06-16 18:38 ` Patrick Mochel
2003-06-16 19:06 ` Alan Stern
2003-06-16 18:00 ` Martin Diehl
2003-06-16 18:15 ` viro
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=3EF101E4.3030900@cox.net \
--to=kpfleming@cox.net \
--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