From: Tony Lindgren <tony@atomide.com>
To: Pantelis Antoniou <panto@antoniou-consulting.com>
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>,
linux-input@vger.kernel.org, linux-kernel@vger.kernel.org,
Koen Kooi <koen@dominion.thruhere.net>,
Matt Porter <mporter@ti.com>, Russ Dill <Russ.Dill@ti.com>,
linux-omap@vger.kernel.org
Subject: Re: [PATCH] gpio-keys: Pinctrl-fy
Date: Tue, 30 Oct 2012 11:25:44 -0700 [thread overview]
Message-ID: <20121030182544.GO11908@atomide.com> (raw)
In-Reply-To: <1351699019-4313-1-git-send-email-panto@antoniou-consulting.com>
* Pantelis Antoniou <panto@antoniou-consulting.com> [121030 11:23]:
> Enable pinctrl support for gpio-keys.
There's some discussion going on regarding doing the
pinctrl boilerplate things somewhere else started by
Dmitry, but meanwhile:
Acked-by: Tony Lindgren <tony@atomide.com>
> Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
> ---
> drivers/input/keyboard/gpio_keys.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/drivers/input/keyboard/gpio_keys.c b/drivers/input/keyboard/gpio_keys.c
> index 6a68041..e421082 100644
> --- a/drivers/input/keyboard/gpio_keys.c
> +++ b/drivers/input/keyboard/gpio_keys.c
> @@ -29,6 +29,7 @@
> #include <linux/of_platform.h>
> #include <linux/of_gpio.h>
> #include <linux/spinlock.h>
> +#include <linux/pinctrl/consumer.h>
>
> struct gpio_button_data {
> const struct gpio_keys_button *button;
> @@ -666,6 +667,7 @@ static int __devinit gpio_keys_probe(struct platform_device *pdev)
> struct input_dev *input;
> int i, error;
> int wakeup = 0;
> + struct pinctrl *pinctrl;
>
> if (!pdata) {
> pdata = gpio_keys_get_devtree_pdata(dev);
> @@ -731,6 +733,10 @@ static int __devinit gpio_keys_probe(struct platform_device *pdev)
> goto fail3;
> }
>
> + pinctrl = devm_pinctrl_get_select_default(&pdev->dev);
> + if (IS_ERR(pinctrl))
> + dev_warn(&pdev->dev, "unable to select pin group\n");
> +
> /* get current state of buttons that are connected to GPIOs */
> for (i = 0; i < pdata->nbuttons; i++) {
> struct gpio_button_data *bdata = &ddata->data[i];
> --
> 1.7.12
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
prev parent reply other threads:[~2012-10-30 18:25 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-31 15:56 [PATCH] gpio-keys: Pinctrl-fy Pantelis Antoniou
2012-10-30 18:25 ` Tony Lindgren [this message]
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=20121030182544.GO11908@atomide.com \
--to=tony@atomide.com \
--cc=Russ.Dill@ti.com \
--cc=dmitry.torokhov@gmail.com \
--cc=koen@dominion.thruhere.net \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=mporter@ti.com \
--cc=panto@antoniou-consulting.com \
/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.