LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Greg KH <greg@kroah.com>
To: Ian Pilcher <arequipeno@gmail.com>
Cc: "Valdis Klētnieks" <valdis.kletnieks@vt.edu>,
axboe@kernel.dk, kernelnewbies@kernelnewbies.org,
linux-kernel@vger.kernel.org, linux-block@vger.kernel.org,
pavel@ucw.cz, linux-leds@vger.kernel.org
Subject: Re: [RFC PATCH 1/8] docs: Add block device LED trigger documentation
Date: Fri, 30 Jul 2021 07:22:16 +0200 [thread overview]
Message-ID: <YQOMiO1HAf60Odqa@kroah.com> (raw)
In-Reply-To: <ee56510e-e8ef-5e92-3e29-4e290bfad9b2@gmail.com>
On Thu, Jul 29, 2021 at 10:52:06AM -0500, Ian Pilcher wrote:
> On 7/28/21 10:09 PM, Valdis Klētnieks wrote:
> > > + # cat /sys/class/block/led_trigger_list
> > > + baz: 0
> > > + bar: 0
> > > + foo: 0
> >
> > This looks like an abuse of the "one entry one value" rule for sysfs.
> > Perhaps this should be a directory /sys/class/block/defined_triggers/
> > and separate files under that for foo, bar, and baz? That would probably
> > make reference counting a lot easier as well....
>
> Indeed it is.
>
> Funny that you should mention using a subdirectory. I originally wanted
> to put all of the trigger-related stuff into
> /sys/class/block/led_triggers/, but I couldn't find any API to create a
> subdirectory for *class* attributes (only for device attributes), nor do
> I see any such subdirectories on my system.
Add a name to your attribute group and sysfs creates the subdirectory
automagically for you.
thanks,
greg k-h
next prev parent reply other threads:[~2021-07-30 5:22 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-29 1:53 [RFC PATCH 0/8] Add configurable block device LED triggers Ian Pilcher
2021-07-29 1:53 ` [RFC PATCH 1/8] docs: Add block device LED trigger documentation Ian Pilcher
2021-07-29 3:09 ` Valdis Klētnieks
2021-07-29 15:52 ` Ian Pilcher
2021-07-30 5:22 ` Greg KH [this message]
2021-07-29 5:53 ` Greg KH
2021-07-29 11:59 ` Marek Behún
2021-07-29 18:03 ` Ian Pilcher
2021-07-29 1:53 ` [RFC PATCH 2/8] block: Add block device LED trigger list Ian Pilcher
2021-07-29 3:14 ` Valdis Klētnieks
2021-07-29 15:55 ` Ian Pilcher
2021-07-29 1:53 ` [RFC PATCH 3/8] block: Add kernel APIs to create & delete block device LED triggers Ian Pilcher
2021-07-29 3:45 ` Valdis Klētnieks
2021-07-29 16:16 ` Ian Pilcher
2021-07-29 5:52 ` Greg KH
2021-07-29 1:53 ` [RFC PATCH 4/8] block: Add block class attributes to manage LED trigger list Ian Pilcher
2021-07-29 5:54 ` Greg KH
2021-07-29 1:53 ` [RFC PATCH 5/8] block: Add block device LED trigger info to struct genhd Ian Pilcher
2021-07-29 1:53 ` [RFC PATCH 6/8] block: Add kernel APIs to set & clear per-block device LED triggers Ian Pilcher
2021-07-29 1:53 ` [RFC PATCH 7/8] block: Add block device attributes to set & clear " Ian Pilcher
2021-07-29 1:53 ` [RFC PATCH 8/8] block: Blink device LED when request is sent to low-level driver Ian Pilcher
2021-07-29 8:54 ` [RFC PATCH 0/8] Add configurable block device LED triggers Pavel Machek
2021-07-29 17:03 ` Ian Pilcher
2021-07-29 18:35 ` Pavel Machek
2021-07-29 19:14 ` Ian Pilcher
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=YQOMiO1HAf60Odqa@kroah.com \
--to=greg@kroah.com \
--cc=arequipeno@gmail.com \
--cc=axboe@kernel.dk \
--cc=kernelnewbies@kernelnewbies.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-leds@vger.kernel.org \
--cc=pavel@ucw.cz \
--cc=valdis.kletnieks@vt.edu \
/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).