From: "Éric Piel" <eric.piel@tremplin-utc.net>
To: Daniel Mack <daniel@caiaq.de>
Cc: LKML <linux-kernel@vger.kernel.org>, Pavel Machek <pavel@ucw.cz>,
Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [PATCH] lis3: add click function
Date: Fri, 12 Jun 2009 13:44:52 +0200 [thread overview]
Message-ID: <4A323FB4.1090404@tremplin-utc.net> (raw)
In-Reply-To: <1244803042-2913-1-git-send-email-daniel@caiaq.de>
Op 12-06-09 12:37, Daniel Mack schreef:
> The LIS3 accelerometer chip has a 'click' feature which can be used to
> detect sudden motion on any of the three axis. Configuration data is
> passed via spi platform_data and no action is taken if that's not
> specified, so it won't harm any existing platform.
>
> To make the configuration effective, the IRQ lines need to be set up
> appropriately. This patch also adds a way to do that from board support
> code.
>
> The DD_* definitions were removed because I couldn't find any reference
> of them in the datasheet and the overlapped with the CLICK_ register
> space.
Hello,
It's not so simple. The driver supports both LIS302xx and LIS3LV02xx.
The LIS302xx (whoami == 0x3A) has CLICK_* registers, and the LIS3LV02xx
(whoami == 0x3B) has DD_* registers. So first of all, you should not
remove the references to DD_*, just add the CLICK_* definitions after
them. Moreover, the usage of those registers should therefore be
conditioned to whoami == 0x3A.
Also, I did not follow all the black magic happening with platform_data.
Could you explain how much would be needed to have the same feature in
the ACPI side?
Also, it seems to only set up the "click" feature, without ever using
it. How do you access this information from userspace? Is it specific to
SPI? Maybe it could also generate button events in the joystick interface?
See you,
Eric
next prev parent reply other threads:[~2009-06-12 11:45 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-11 19:55 [PATCH] lis3: add click function Daniel Mack
2009-06-11 21:07 ` Pavel Machek
2009-06-12 10:13 ` Daniel Mack
2009-06-12 10:18 ` Pavel Machek
[not found] ` <1244803042-2913-1-git-send-email-daniel@caiaq.de>
2009-06-12 11:44 ` Éric Piel [this message]
2009-06-12 12:31 ` Daniel Mack
2009-06-12 12:50 ` Éric Piel
2009-06-12 12:55 ` Daniel Mack
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=4A323FB4.1090404@tremplin-utc.net \
--to=eric.piel@tremplin-utc.net \
--cc=akpm@linux-foundation.org \
--cc=daniel@caiaq.de \
--cc=linux-kernel@vger.kernel.org \
--cc=pavel@ucw.cz \
/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