From: Sebastian Reichel <sre@kernel.org>
To: Tony Lindgren <tony@atomide.com>
Cc: "Pavel Machek" <pavel@ucw.cz>,
"Benoît Cousson" <bcousson@baylibre.com>,
"Aaro Koskinen" <aaro.koskinen@iki.fi>,
"Rob Herring" <robh+dt@kernel.org>,
"Pawel Moll" <pawel.moll@arm.com>,
"Mark Rutland" <mark.rutland@arm.com>,
"Ian Campbell" <ijc+devicetree@hellion.org.uk>,
"Kumar Gala" <galak@codeaurora.org>,
linux-omap@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 4/7] ARM: dts: Enable N950 keyboard sleep leds by default
Date: Thu, 31 Mar 2016 02:48:10 +0200 [thread overview]
Message-ID: <20160331004809.GA27951@earth> (raw)
In-Reply-To: <20160330193520.GY9329@atomide.com>
[-- Attachment #1: Type: text/plain, Size: 2197 bytes --]
Hi,
On Wed, Mar 30, 2016 at 12:35:21PM -0700, Tony Lindgren wrote:
> > > I must say I've seen it on N900, and yes, it is useful, but no, I
> > > don't think this is right.
> > >
> > > This is not a LED. This is a interface that changes meaning of two
> > > other LEDs. I guess it should go to debugfs somewhere.
>
> Eh that sounds like a GPIO LED to me :) And it already has a
> /sys/class/leds/debug interface.
>
> The two LEDs this GPIO controls are hardwired to sys_clkreq and
> sys_off_mode pins that are the control signals between the SoC
> and PMIC.
>
> In theory you could steal the sys_clkreq and sys_off_mode pins
> from the PMIC at the cost of breaking PM. But I doubt anybody
> wants to do that considering it's a battery operated device.
>
> > I don't think we should diverge N900 and N950 userspace
> > APIs in this regard.
> >
> > Actually the correct way would be a custom trigger
> > for the leds IMHO. I don't know if the led framework
> > supports per led custom triggers, though.
>
> Sure, there are something like 10 triggers already. And
> you can already change them using:
>
> echo none > /sys/class/leds/debug::sleep/trigger
>
> That still does not change the fact that the LEDs trigger
> based on the state of sys_clkreq and sys_off_mode.
>
> Maybe I'm not following what you guys are trying to achieve
> here though :) If so, please let me know.
If I understand the situation correctly there are two different
control methods for the same LED. I was wondering if the trigger
from lp5523:kb0 could enable the gpio. For example like this:
echo cpu-sleep-state > /sys/class/leds/lp5523:kb0/trigger
Thinking about it again supporting this requires quite some effort
with N9xx being the only affected platform. Apart from that (as
Pavel mentioned) two LEDs are affected by the GPIO, so even the
trigger is not a clean option.
So I'm fine with the current solution. IMHO moving it to debugfs
is not recommendable while keeping it default enabled (which makes
sense IMHO). At the end the correct solution is fixing the power
management. If the cpu sleeps the impact of this should be marginal.
-- Sebastian
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
next prev parent reply other threads:[~2016-03-31 0:48 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-13 0:06 [PATCH 0/7] Nokia N9/N950 misc. DT patches Sebastian Reichel
2016-03-13 0:06 ` [PATCH 1/7] ARM: dts: n9/n950: regulator configuration Sebastian Reichel
2016-03-13 0:06 ` [PATCH 2/7] ARM: dts: OMAP3-N950: Add Keypad Matrix Sebastian Reichel
2016-03-13 0:06 ` [PATCH 3/7] ARM: dts: OMAP3-N950: Add Vibrator Sebastian Reichel
[not found] ` <1457827580-16919-1-git-send-email-sre-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2016-03-13 0:06 ` [PATCH 4/7] ARM: dts: Enable N950 keyboard sleep leds by default Sebastian Reichel
2016-03-13 0:06 ` Sebastian Reichel
[not found] ` <1457827580-16919-5-git-send-email-sre-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2016-03-29 10:51 ` Pavel Machek
2016-03-29 14:52 ` Sebastian Reichel
2016-03-29 17:54 ` Pavel Machek
2016-03-30 19:35 ` Tony Lindgren
2016-03-31 0:48 ` Sebastian Reichel [this message]
2016-04-01 12:45 ` Pavel Machek
2016-04-01 18:32 ` Tony Lindgren
2016-04-02 6:47 ` Pavel Machek
2016-04-12 21:02 ` Tony Lindgren
2016-03-13 0:06 ` [PATCH 5/7] ARM: dts: OMAP3-N950: Add Keypad Slide Switch Sebastian Reichel
2016-03-13 0:06 ` [PATCH 6/7] ARM: dts: N9/N950: Add support for 1GHz CPU clock Sebastian Reichel
2016-03-13 0:06 ` [PATCH 7/7] ARM: dts: N9/N950: Add support for accelerometer Sebastian Reichel
2016-03-29 10:53 ` Pavel Machek
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=20160331004809.GA27951@earth \
--to=sre@kernel.org \
--cc=aaro.koskinen@iki.fi \
--cc=bcousson@baylibre.com \
--cc=devicetree@vger.kernel.org \
--cc=galak@codeaurora.org \
--cc=ijc+devicetree@hellion.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=pavel@ucw.cz \
--cc=pawel.moll@arm.com \
--cc=robh+dt@kernel.org \
--cc=tony@atomide.com \
/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).