All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Pali Rohár" <pali.rohar@gmail.com>
To: Darren Hart <dvhart@infradead.org>
Cc: Matthew Garrett <mjg59@srcf.ucam.org>,
	Andy Shevchenko <andy@infradead.org>,
	"Gabriel M. Elder" <gabriel@tekgnowsys.com>,
	Gabriele Mazzotta <gabriele.mzt@gmail.com>,
	Mario.Limonciello@dell.com, platform-driver-x86@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] dell-laptop: Fix keyboard led max_brightness property for Dell Latitude E6410
Date: Wed, 18 Oct 2017 20:02:59 +0200	[thread overview]
Message-ID: <20171018180259.xy7ms2mo5fsees6y@pali> (raw)
In-Reply-To: <20171016214837.GC14419@fury>

On Monday 16 October 2017 14:48:37 Darren Hart wrote:
> On Sun, Oct 15, 2017 at 06:03:14PM +0200, Pali Rohár wrote:
> > This machine reports number of keyboard backlight led levels, instead of
> > value of the last led level index. Therefore max_brightness properly needs
> > to be subtracted by 1 to match led max_brightness API.
> 
> Which field is behaving differently?
> 
> If I'm understanding this correctly:
> 
> Since the max level is something we test for once at runtime, it seems
> to me a cleaner fix would be to check for this quirk in kbd_get_info()
> and set kbd_info.levels accordingly. The rest of the driver logic would
> then remain unchanged.

Great, this is a good idea. I would send a new patch in a few minutes.

> The idea being to translate what the platform firmware reports into what
> the driver already understands, instead of giving the levels fields of
> the structure multiple meanings.

-- 
Pali Rohár
pali.rohar@gmail.com

  reply	other threads:[~2017-10-18 18:03 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-15 16:03 [PATCH] dell-laptop: Fix keyboard led max_brightness property for Dell Latitude E6410 Pali Rohár
2017-10-16 21:48 ` Darren Hart
2017-10-18 18:02   ` Pali Rohár [this message]
2017-10-18 18:06 ` [PATCH v2] " Pali Rohár
2017-10-18 19:09   ` Andy Shevchenko
2017-10-18 19:14     ` Pali Rohár
2017-10-18 20:00   ` Darren Hart
2017-11-02 20:25   ` [PATCH v3] " Pali Rohár
2017-11-03  1:18     ` Darren Hart
2017-11-11 22:12       ` Pali Rohár
2017-12-08 21:41     ` Darren Hart

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=20171018180259.xy7ms2mo5fsees6y@pali \
    --to=pali.rohar@gmail.com \
    --cc=Mario.Limonciello@dell.com \
    --cc=andy@infradead.org \
    --cc=dvhart@infradead.org \
    --cc=gabriel@tekgnowsys.com \
    --cc=gabriele.mzt@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mjg59@srcf.ucam.org \
    --cc=platform-driver-x86@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.