From: Andy Ross <andy.ross@windriver.com>
To: Dmitry Torokhov <dmitry.torokhov@gmail.com>,
Corentin Chary <corentincj@iksaif.net>,
linux-input@vger.kernel.org,
acpi4asus-user@lists.sourceforge.net,
platform-driver-x86@vger.kernel.org
Subject: [PATCH 0/2] Pegatron Lucid tablet accelerometer
Date: Mon, 17 Jan 2011 09:56:49 -0800 [thread overview]
Message-ID: <1295287011-12849-1-git-send-email-andy.ross@windriver.com> (raw)
Resend with fixes per comments: Driver for the ACPI interface to the
accelerometer on the Pegatron Lucid tablets (sold as WeTab and ExoPC).
Corentin Chary wrote:
> > + int z = acpi_s16("\\_SB.ATKD.XLRZ");
>
> Using the absolute path (\\_SB.ATKD) may not work on new hardware, you
> should find the path of the device using the HID (AKT0100, or
> something like that). But we may not core in this case since it's pega
> specific.
I could pass the ACPI prefix (or a handle) through the platform driver
if you like, but it's a little more complexity and as you mention that
seems like overkill for a driver whose core is only three lines of
code. Left unchanged.
Corentin Chary wrote:
> > +static int __devinit platform_probe(struct platform_device *pd)
>
> You should check if the device exists here, before trying to do
> anything, (using the path or the HID, depending of what you'll do
> about my previous comment)
Detection is done in asus-laptop: this code won't be reached unless
the platform device is created, which is after the three needed
methods have already been detected with acpi_check_handle().
Dmitry Torokhov wrote:
> This is not a critical component; default should be 'n' (or just omit
> default statement).
Fixed.
Dmitry Torokhov wrote:
> Please keep Kconfig and Makefile sorted alphabetically.
Fixed in Makefile. Kconfig is hopelessly out of order, but I did what
I could.
Dmitry Torokhov wrote:
> What's up with people loving to put filename into comments? It just
> makes renaming files more4 difficult.
No love here; I was trying to adhere to what looked like existing
convention. Removed.
Dmitry Torokhov wrote:
> No need to initialize to 0, in fact, it is quite often dangerous as it
> masks compiler warnings.
True enough. Fixed.
> > + ipdev->input->dev.release = dev_noop_release;
>
> WTH is this???
It's an attempt to avoid this from drivers/base/core.c:
WARN(1, KERN_ERR "Device '%s' does not have a release() "
"function, it is broken and must be fixed.\n",
dev_name(dev));
...but it was in the wrong place. The input device doesn't hit that
path, the platform device does. Moved to where it belongs.
Andy
next reply other threads:[~2011-01-17 17:56 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-17 17:56 Andy Ross [this message]
2011-01-17 17:56 ` [PATCH 1/2] input: Pegatron Lucid accelerometer Andy Ross
2011-01-18 5:48 ` Shubhrajyoti
2011-01-18 5:59 ` Dmitry Torokhov
2011-01-18 17:21 ` Andy Ross
[not found] ` <4D35CC1B.3020808-CWA4WttNNZF54TAoqtyWWQ@public.gmane.org>
2011-01-31 21:30 ` Matthew Garrett
2011-03-18 15:39 ` Anisse Astier
2011-01-17 17:56 ` [PATCH 2/2] asus-laptop: Support pega_accel driver Andy Ross
2011-01-17 18:49 ` [PATCH 0/2] Pegatron Lucid tablet accelerometer Dmitry Torokhov
2011-01-17 22:14 ` Andy Ross
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=1295287011-12849-1-git-send-email-andy.ross@windriver.com \
--to=andy.ross@windriver.com \
--cc=acpi4asus-user@lists.sourceforge.net \
--cc=corentincj@iksaif.net \
--cc=dmitry.torokhov@gmail.com \
--cc=linux-input@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).