From: Victor Rodriguez <vm.rod25@gmail.com>
To: Ben Gardiner <bengardiner@nanometrics.ca>
Cc: Kevin Hilman <khilman@deeprootsystems.com>,
davinci-linux-open-source@linux.davincidsp.com,
linux-input@vger.kernel.org,
Dmitry Torokhov <dmitry.torokhov@gmail.com>,
Paul Mundt <lethal@linux-sh.org>,
linux-kernel@vger.kernel.org,
Chris Cordahi <christophercordahi@nanometrics.ca>
Subject: Re: [PATCH v3 3/4] da850-evm: extract defines for SEL{A, B, C} pins in UI expander
Date: Fri, 19 Nov 2010 15:41:11 -0600 [thread overview]
Message-ID: <AANLkTimOByqsZjCYoz=pjwT7jcgN76Sgi4W6SFJ9+N-d@mail.gmail.com> (raw)
In-Reply-To: <a367bea7c1bdc198b5540b7fe3c02d10ad59cf16.1290201713.git.bengardiner@nanometrics.ca>
On Fri, Nov 19, 2010 at 3:37 PM, Ben Gardiner
<bengardiner@nanometrics.ca> wrote:
> The setup and teardown methods of the UI expander reference the SEL_{A,B,C}
> pins by 'magic number' in each function. This uses the common enum for their offsets
> in the expander setup and teardown functions.
>
> Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
> Reviewed-by: Chris Cordahi <christophercordahi@nanometrics.ca>
> Reviewed-by: Sekhar Nori <nsekhar@ti.com>
> Signed-off-by: Sekhar Nori <nsekhar@ti.com>
>
> ---
>
> Changes since v2:
> * rebased to 083eae3e28643e0eefc5243719f8b1572cf98299 of
> git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-davinci.git
> * integrated the static array initialization patch provided by Sekhar Nori
>
> Changes since v1:
> * No changes since v1
>
> ---
I think that ther must be just one --- , This is extra
Regards
Victor Rodriguez
> arch/arm/mach-davinci/board-da850-evm.c | 24 ++++++++++++------------
> 1 files changed, 12 insertions(+), 12 deletions(-)
>
> diff --git a/arch/arm/mach-davinci/board-da850-evm.c b/arch/arm/mach-davinci/board-da850-evm.c
> index b0763f7..c689e7e 100644
> --- a/arch/arm/mach-davinci/board-da850-evm.c
> +++ b/arch/arm/mach-davinci/board-da850-evm.c
> @@ -361,23 +361,23 @@ static int da850_evm_ui_expander_setup(struct i2c_client *client, unsigned gpio,
> {
> int sel_a, sel_b, sel_c, ret;
>
> - sel_a = gpio + 7;
> - sel_b = gpio + 6;
> - sel_c = gpio + 5;
> + sel_a = gpio + DA850_EVM_UI_EXP_SEL_A;
> + sel_b = gpio + DA850_EVM_UI_EXP_SEL_B;
> + sel_c = gpio + DA850_EVM_UI_EXP_SEL_C;
>
> - ret = gpio_request(sel_a, "sel_a");
> + ret = gpio_request(sel_a, da850_evm_ui_exp[DA850_EVM_UI_EXP_SEL_A]);
> if (ret) {
> pr_warning("Cannot open UI expander pin %d\n", sel_a);
> goto exp_setup_sela_fail;
> }
>
> - ret = gpio_request(sel_b, "sel_b");
> + ret = gpio_request(sel_b, da850_evm_ui_exp[DA850_EVM_UI_EXP_SEL_B]);
> if (ret) {
> pr_warning("Cannot open UI expander pin %d\n", sel_b);
> goto exp_setup_selb_fail;
> }
>
> - ret = gpio_request(sel_c, "sel_c");
> + ret = gpio_request(sel_c, da850_evm_ui_exp[DA850_EVM_UI_EXP_SEL_C]);
> if (ret) {
> pr_warning("Cannot open UI expander pin %d\n", sel_c);
> goto exp_setup_selc_fail;
> @@ -420,13 +420,13 @@ static int da850_evm_ui_expander_teardown(struct i2c_client *client,
> platform_device_unregister(&da850_evm_ui_keys_device);
>
> /* deselect all functionalities */
> - gpio_set_value_cansleep(gpio + 5, 1);
> - gpio_set_value_cansleep(gpio + 6, 1);
> - gpio_set_value_cansleep(gpio + 7, 1);
> + gpio_set_value_cansleep(gpio + DA850_EVM_UI_EXP_SEL_C, 1);
> + gpio_set_value_cansleep(gpio + DA850_EVM_UI_EXP_SEL_B, 1);
> + gpio_set_value_cansleep(gpio + DA850_EVM_UI_EXP_SEL_A, 1);
>
> - gpio_free(gpio + 5);
> - gpio_free(gpio + 6);
> - gpio_free(gpio + 7);
> + gpio_free(gpio + DA850_EVM_UI_EXP_SEL_C);
> + gpio_free(gpio + DA850_EVM_UI_EXP_SEL_B);
> + gpio_free(gpio + DA850_EVM_UI_EXP_SEL_A);
>
> return 0;
> }
> --
> 1.7.0.4
>
> _______________________________________________
> Davinci-linux-open-source mailing list
> Davinci-linux-open-source@linux.davincidsp.com
> http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source
>
next prev parent reply other threads:[~2010-11-19 21:41 UTC|newest]
Thread overview: 62+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <cover.1289835508.git.bengardiner@nanometrics.ca>
2010-11-16 19:39 ` [PATCH v2 0/4] da850-evm: add gpio-{keys,leds} for UI and BB expanders Ben Gardiner
2010-11-16 19:39 ` [PATCH v2 1/4] input: gpio_keys: polling mode support Ben Gardiner
2010-11-16 19:39 ` [PATCH v2 2/4] da850-evm: add UI Expander pushbuttons Ben Gardiner
2010-11-19 9:58 ` Nori, Sekhar
2010-11-19 15:38 ` Ben Gardiner
2010-11-22 11:49 ` Nori, Sekhar
2010-11-22 13:50 ` Ben Gardiner
2010-11-23 12:38 ` Nori, Sekhar
2010-11-23 13:29 ` Ben Gardiner
2010-11-23 15:48 ` Kevin Hilman
2010-11-23 17:58 ` Ben Gardiner
2010-11-24 6:09 ` Paul Mundt
2010-11-24 17:17 ` Ben Gardiner
2010-11-16 19:39 ` [PATCH v2 3/4] da850-evm: extract defines for SEL{A,B,C} pins in UI expander Ben Gardiner
2010-11-19 11:19 ` [PATCH v2 3/4] da850-evm: extract defines for SEL{A, B, C} " Nori, Sekhar
2010-11-19 15:38 ` Ben Gardiner
2010-11-16 19:39 ` [PATCH v2 4/4] da850-evm: add baseboard UI expander buttons, switches and LEDs Ben Gardiner
2010-11-19 12:14 ` Nori, Sekhar
2010-11-19 15:40 ` Ben Gardiner
2010-11-19 17:02 ` Dmitry Torokhov
2010-11-19 17:15 ` Ben Gardiner
2010-11-22 12:00 ` Nori, Sekhar
2010-11-22 14:15 ` Ben Gardiner
2010-11-23 12:42 ` Nori, Sekhar
2010-11-23 13:32 ` Ben Gardiner
2010-11-19 21:37 ` [PATCH v3 0/4] da850-evm: add gpio-{keys,leds} for UI and BB expanders Ben Gardiner
2010-11-19 21:37 ` [PATCH v3 1/4] input: gpio_keys: polling mode support Ben Gardiner
2010-11-19 21:37 ` [PATCH v3 2/4] da850-evm: add UI Expander pushbuttons Ben Gardiner
2010-11-19 21:37 ` [PATCH v3 3/4] da850-evm: extract defines for SEL{A,B,C} pins in UI expander Ben Gardiner
2010-11-19 21:41 ` Victor Rodriguez [this message]
2010-11-19 22:25 ` [PATCH v3 3/4] da850-evm: extract defines for SEL{A, B, C} " Ben Gardiner
2010-11-19 21:37 ` [PATCH v3 4/4] da850-evm: add baseboard GPIO expander buttons, switches and LEDs Ben Gardiner
2010-11-23 19:40 ` [PATCH v4 0/5] da850-evm: add gpio-{keys,leds} for UI and BB expanders Ben Gardiner
2010-11-23 19:40 ` [PATCH v4 1/5] input: gpio_keys: polling mode support Ben Gardiner
2010-11-23 19:40 ` [PATCH v4 2/5] da850-evm: add UI Expander pushbuttons Ben Gardiner
2010-11-24 13:16 ` Nori, Sekhar
2010-11-24 17:16 ` Ben Gardiner
2010-11-23 19:40 ` [PATCH v4 3/5] da850-evm: extract defines for SEL{A,B,C} pins in UI expander Ben Gardiner
2010-11-23 19:40 ` [PATCH v4 4/5] da850-evm: add baseboard GPIO expander buttons, switches and LEDs Ben Gardiner
2010-11-23 19:41 ` [PATCH v4 5/5] da850-evm: KEYBOARD_GPIO and INPUT_POLLDEV Kconfig conditionals Ben Gardiner
2010-11-24 21:59 ` [PATCH v5 0/5] da850-evm: add gpio-{keys,leds} for UI and BB expanders Ben Gardiner
2010-11-24 21:59 ` [PATCH v5 1/5] [WIP] input: add input driver for polled GPIO buttons Ben Gardiner
2010-11-24 21:59 ` [PATCH v5 2/5] da850-evm: add UI Expander pushbuttons Ben Gardiner
2010-11-24 21:59 ` [PATCH v5 3/5] da850-evm: extract defines for SEL{A,B,C} pins in UI expander Ben Gardiner
2010-11-24 21:59 ` [PATCH v5 4/5] da850-evm: add baseboard GPIO expander buttons, switches and LEDs Ben Gardiner
2010-11-24 21:59 ` [PATCH v5 5/5] da850-evm: KEYBOARD_GPIO_POLLED Kconfig conditional Ben Gardiner
2010-12-09 21:51 ` [PATCH v6 0/5] da850-evm: add gpio-{keys,leds} for UI and BB expanders Ben Gardiner
2010-12-09 21:51 ` [PATCH v6 1/5] Input: add input driver for polled GPIO buttons Ben Gardiner
2010-12-10 15:50 ` Kevin Hilman
2010-12-09 21:51 ` [PATCH v6 2/5] da850-evm: add UI Expander pushbuttons Ben Gardiner
2010-12-09 21:51 ` [PATCH v6 3/5] da850-evm: extract defines for SEL{A,B,C} pins in UI expander Ben Gardiner
2010-12-09 21:51 ` [PATCH v6 4/5] da850-evm: add baseboard GPIO expander buttons, switches and LEDs Ben Gardiner
2010-12-09 21:51 ` [PATCH v6 5/5] da850-evm: KEYBOARD_GPIO_POLLED Kconfig conditional Ben Gardiner
2010-12-10 16:16 ` [PATCH v6 0/5] da850-evm: add gpio-{keys,leds} for UI and BB expanders Kevin Hilman
2010-12-10 16:33 ` Ben Gardiner
2010-12-11 0:04 ` Kevin Hilman
2010-12-13 17:02 ` Ben Gardiner
2010-12-13 21:53 ` Kevin Hilman
2010-12-14 4:31 ` Ben Gardiner
2010-12-14 16:17 ` Ben Gardiner
2010-12-14 17:10 ` Kevin Hilman
2010-12-17 15:15 ` Ben Gardiner
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='AANLkTimOByqsZjCYoz=pjwT7jcgN76Sgi4W6SFJ9+N-d@mail.gmail.com' \
--to=vm.rod25@gmail.com \
--cc=bengardiner@nanometrics.ca \
--cc=christophercordahi@nanometrics.ca \
--cc=davinci-linux-open-source@linux.davincidsp.com \
--cc=dmitry.torokhov@gmail.com \
--cc=khilman@deeprootsystems.com \
--cc=lethal@linux-sh.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@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).