From: Thierry Reding <thierry.reding@gmail.com>
To: Greg KH <gregkh@linuxfoundation.org>
Cc: linux-pwm@vger.kernel.org, linux-kernel@vger.kernel.org,
David Hsu <davidhsu@google.com>
Subject: Re: [PATCH] pwm: Create device class for pwm channels
Date: Wed, 15 Jun 2016 16:37:20 +0200 [thread overview]
Message-ID: <20160615143720.GA23483@ulmo.ba.sec> (raw)
In-Reply-To: <20160615021204.GA11507@kroah.com>
[-- Attachment #1: Type: text/plain, Size: 1475 bytes --]
On Tue, Jun 14, 2016 at 07:12:04PM -0700, Greg KH wrote:
> From: David Hsu <davidhsu@google.com>
>
> Pwm channels don't send uevents when exported, this change adds the
> channels to a pwm class and set their device type to pwm_channel so
> uevents are sent.
>
> To do this properly, the device names need to change to uniquely
> identify a channel. This change is from pwmN to pwm-(chip->base):N
>
> Signed-off-by: David Hsu <davidhsu@google.com>
> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> ---
> Documentation/pwm.txt | 6 ++++--
> drivers/pwm/sysfs.c | 15 ++++++++++++---
> 2 files changed, 16 insertions(+), 5 deletions(-)
>
> Note, this patch came from David with his work on a system that has
> dynamic PWM devices and channels, and we needed some way to tell
> userspace what is going on when they are added or removed. If anyone
> knows any other way of doing this that does not involve changing the pwm
> names, please let us know.
Is it truly PWM channels that dynamically appear and disappear? I'd be
interested in how that's achieved, because there are probably other
issues that will manifest if you do that. Do you have a pointer to the
work that David's been undertaking? Generally some more context on the
use-case would be helpful here.
Also I'd prefer if this avoided using chip->base here, because it exists
purely for legacy purposes and is supposed to go away eventually.
Thierry
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
next prev parent reply other threads:[~2016-06-15 14:37 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-15 2:12 [PATCH] pwm: Create device class for pwm channels Greg KH
2016-06-15 14:37 ` Thierry Reding [this message]
2016-06-15 23:52 ` David Hsu
2016-06-24 20:54 ` David Hsu
2016-07-11 9:39 ` Thierry Reding
2016-07-12 1:25 ` David Hsu
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=20160615143720.GA23483@ulmo.ba.sec \
--to=thierry.reding@gmail.com \
--cc=davidhsu@google.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pwm@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