From: Laxman Dewangan <ldewangan@nvidia.com>
To: Arnd Bergmann <arnd@arndb.de>,
Alexander Stein <alexander.stein@systec-electronic.com>
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>,
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-input@vger.kernel.org, devicetree@vger.kernel.org,
linux-gpio@vger.kernel.org
Subject: Re: [PATCH v2 1/1] Input: gpio_keys - add device tree support for interrupt only keys
Date: Thu, 13 Nov 2014 16:29:02 +0530 [thread overview]
Message-ID: <54648EF6.10402@nvidia.com> (raw)
In-Reply-To: <1763965.yCxTDubTPH@wuerfel>
On Thursday 13 November 2014 04:17 PM, Arnd Bergmann wrote:
> On Thursday 13 November 2014 11:35:42 Alexander Stein wrote:
>> On Wednesday 12 November 2014 20:16:06, Arnd Bergmann wrote:
>>> On Wednesday 12 November 2014 17:38:31 Alexander Stein wrote:
>>>> On Wednesday 12 November 2014 17:04:57, Arnd Bergmann wrote:
>>>>> On Wednesday 12 November 2014 17:02:56 Alexander Stein wrote:
>>>>>> This features already exists for board config setups. Add support for
>>>>>> device tree based systems.
>>>>>>
>>>>>> Signed-off-by: Alexander Stein <alexander.stein@systec-electronic.com>
>>>>>> ---
>>>>>> Please note: Due to current lack of hardware I could not test it yet. V2
>>>>>> includes the changes proposed by Dmitry.
>>>>>>
>>>>>> Changes in v2:
>>>>>> * Added device tree bindings
>>>>>> * IRQ is only parsed and mapped when there is no "gpios" property
>>>>>>
>>>>> Can you list one or more examples in the patch description?
>>>>> Are these systems that don't expose the GPIO controller with a
>>>>> standalone driver, or systems that really actually connect the
>>>>> buttons to an interrupt pin?
>>>> You mean a use case? I came to this situation to test interrupt polarity on a microcontroller, thus a simple /IRQ pin, no GPIO at all. So in the end I have an input just connected to an interrupt line.
>>>> I noticed gpio_keys using platform data only can be used for this setup. So I added this support for device tree.
>>>>
>>> I meant a specific board file that uses this, which can't be converted
>>> to DT without your change.
>> I've searched (hopefully) the complete arch/ tree on v3.18-rc4 for
>> struct gpio_keys_button and checked each occurrence. I didn't found
>> any usage of IRQ based input keys.
> Ok, I see.
>
> I notice that Laxman Dewangan initially added the feature as part of
> (I assume) work on Tegra, but these days Tegra is DT-only so it can't
> actually get used for that any more.
>
> If we have a real usecase, I think we can still take your patch, but
> my impression at the moment is that it may be better to instead
> remove the feature entirely by reverting d8ee4a1c9052 ("Input:
> gpio_keys - add support for interrupt only keys").
>
> Regarding your initial use case of testing interrupt polarity, would
> you have been able to do the same thing by looking at the interrupt
> count in /proc/interrupts?
>
Yes, I posted patch for interrupt key on context on key connected to
PMIC-Onkey.
On PMIC, there is onkey pin input which generates interrupt only when it
toggles. So if we have key (power key on our platforms) connected to
this pin then we will only get interrupt from PMIC.
Instead of implementing full interrupt key driver, I added this support
on existing gpio keys.
next prev parent reply other threads:[~2014-11-13 10:59 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-12 16:02 [PATCH v2 1/1] Input: gpio_keys - add device tree support for interrupt only keys Alexander Stein
2014-11-12 16:04 ` Arnd Bergmann
2014-11-12 16:38 ` Alexander Stein
2014-11-12 19:16 ` Arnd Bergmann
2014-11-13 10:35 ` Alexander Stein
2014-11-13 10:47 ` Arnd Bergmann
2014-11-13 10:52 ` Alexander Stein
2014-11-13 11:00 ` Arnd Bergmann
2014-11-13 11:02 ` Laxman Dewangan
2014-11-13 10:59 ` Laxman Dewangan [this message]
2014-11-13 11:05 ` Arnd Bergmann
2014-11-13 11:17 ` Laxman Dewangan
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=54648EF6.10402@nvidia.com \
--to=ldewangan@nvidia.com \
--cc=alexander.stein@systec-electronic.com \
--cc=arnd@arndb.de \
--cc=devicetree@vger.kernel.org \
--cc=dmitry.torokhov@gmail.com \
--cc=galak@codeaurora.org \
--cc=ijc+devicetree@hellion.org.uk \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=pawel.moll@arm.com \
--cc=robh+dt@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).