linux-acpi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Matthew Garrett <mjg59@srcf.ucam.org>
To: Frederick van der Wyck <fvanderwyck@gmail.com>
Cc: platform-driver-x86@vger.kernel.org,
	linux-kernel@vger.kernel.org, linux-acpi@vger.kernel.org
Subject: Re: [PATCH] platform samsung-q10: use ACPI instead of direct EC calls
Date: Mon, 08 Jul 2013 11:36:54 -0400	[thread overview]
Message-ID: <1373297814.24233.5.camel@x230.lan> (raw)
In-Reply-To: <20130703212737.GC5579@lat.lan>

On Wed, 2013-07-03 at 22:27 +0100, Frederick van der Wyck wrote:

> +#define EC_HID "PNP0C09"

This is probably wrong - you should be able to just use first_ec
directly rather than probing yourself.
> +	for (i = 0; i < SAMSUNGQ10_BL_MAX_INTENSITY; i++) {
> +		status = acpi_evaluate_object(ec_handle, "_Q63", NULL, NULL);

The potential problem here is that there's no guarantee that these event
numbers are stable, and a firmware upgrade could change them. Of course,
that's also true of the EC registers, but we haven't had anyone complain
about the driver suddenly breaking so I'm not hugely enthusiastic about
replacing one fragile but seemingly working method with a fragile but
unproven one. 

-- 
Matthew Garrett <mjg59@srcf.ucam.org>

  reply	other threads:[~2013-07-08 15:36 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-03 21:27 [PATCH] platform samsung-q10: use ACPI instead of direct EC calls Frederick van der Wyck
2013-07-08 15:36 ` Matthew Garrett [this message]
2013-07-08 21:34   ` Frederick van der Wyck
2013-07-13 23:02     ` Rafael J. Wysocki
2013-09-03 12:06     ` Matthew Garrett

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=1373297814.24233.5.camel@x230.lan \
    --to=mjg59@srcf.ucam.org \
    --cc=fvanderwyck@gmail.com \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.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 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).