* [PATCH] pinctrl: tegra: correct bank for pingroup and drv pingroup
@ 2012-10-17 6:21 Pritesh Raithatha
2012-10-17 15:04 ` Greg KH
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Pritesh Raithatha @ 2012-10-17 6:21 UTC (permalink / raw)
To: linus.walleij, linux-kernel, swarren; +Cc: stable, praithatha
Signed-off-by: Pritesh Raithatha <praithatha@nvidia.com>
---
drivers/pinctrl/pinctrl-tegra30.c | 24 ++++++++++++------------
1 files changed, 12 insertions(+), 12 deletions(-)
diff --git a/drivers/pinctrl/pinctrl-tegra30.c b/drivers/pinctrl/pinctrl-tegra30.c
index 0386fdf..7894f14 100644
--- a/drivers/pinctrl/pinctrl-tegra30.c
+++ b/drivers/pinctrl/pinctrl-tegra30.c
@@ -3345,10 +3345,10 @@ static const struct tegra_function tegra30_functions[] = {
FUNCTION(vi_alt3),
};
-#define MUXCTL_REG_A 0x3000
-#define PINGROUP_REG_A 0x868
+#define DRV_PINGROUP_REG_A 0x868 /* bank 0 */
+#define PINGROUP_REG_A 0x3000 /* bank 1 */
-#define PINGROUP_REG_Y(r) ((r) - MUXCTL_REG_A)
+#define PINGROUP_REG_Y(r) ((r) - PINGROUP_REG_A)
#define PINGROUP_REG_N(r) -1
#define PINGROUP(pg_name, f0, f1, f2, f3, f_safe, r, od, ior) \
@@ -3364,25 +3364,25 @@ static const struct tegra_function tegra30_functions[] = {
}, \
.func_safe = TEGRA_MUX_ ## f_safe, \
.mux_reg = PINGROUP_REG_Y(r), \
- .mux_bank = 0, \
+ .mux_bank = 1, \
.mux_bit = 0, \
.pupd_reg = PINGROUP_REG_Y(r), \
- .pupd_bank = 0, \
+ .pupd_bank = 1, \
.pupd_bit = 2, \
.tri_reg = PINGROUP_REG_Y(r), \
- .tri_bank = 0, \
+ .tri_bank = 1, \
.tri_bit = 4, \
.einput_reg = PINGROUP_REG_Y(r), \
- .einput_bank = 0, \
+ .einput_bank = 1, \
.einput_bit = 5, \
.odrain_reg = PINGROUP_REG_##od(r), \
- .odrain_bank = 0, \
+ .odrain_bank = 1, \
.odrain_bit = 6, \
.lock_reg = PINGROUP_REG_Y(r), \
- .lock_bank = 0, \
+ .lock_bank = 1, \
.lock_bit = 7, \
.ioreset_reg = PINGROUP_REG_##ior(r), \
- .ioreset_bank = 0, \
+ .ioreset_bank = 1, \
.ioreset_bit = 8, \
.drv_reg = -1, \
}
@@ -3401,8 +3401,8 @@ static const struct tegra_function tegra30_functions[] = {
.odrain_reg = -1, \
.lock_reg = -1, \
.ioreset_reg = -1, \
- .drv_reg = ((r) - PINGROUP_REG_A), \
- .drv_bank = 1, \
+ .drv_reg = ((r) - DRV_PINGROUP_REG_A), \
+ .drv_bank = 0, \
.hsm_bit = hsm_b, \
.schmitt_bit = schmitt_b, \
.lpmd_bit = lpmd_b, \
--
1.7.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] pinctrl: tegra: correct bank for pingroup and drv pingroup
2012-10-17 6:21 [PATCH] pinctrl: tegra: correct bank for pingroup and drv pingroup Pritesh Raithatha
@ 2012-10-17 15:04 ` Greg KH
2012-10-17 15:48 ` Stephen Warren
2012-10-17 17:50 ` Linus Walleij
2 siblings, 0 replies; 4+ messages in thread
From: Greg KH @ 2012-10-17 15:04 UTC (permalink / raw)
To: Pritesh Raithatha; +Cc: linus.walleij, linux-kernel, swarren, stable
On Wed, Oct 17, 2012 at 11:51:37AM +0530, Pritesh Raithatha wrote:
> Signed-off-by: Pritesh Raithatha <praithatha@nvidia.com>
> ---
> drivers/pinctrl/pinctrl-tegra30.c | 24 ++++++++++++------------
> 1 files changed, 12 insertions(+), 12 deletions(-)
<formletter>
This is not the correct way to submit patches for inclusion in the
stable kernel tree. Please read Documentation/stable_kernel_rules.txt
for how to do this properly.
</formletter>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] pinctrl: tegra: correct bank for pingroup and drv pingroup
2012-10-17 6:21 [PATCH] pinctrl: tegra: correct bank for pingroup and drv pingroup Pritesh Raithatha
2012-10-17 15:04 ` Greg KH
@ 2012-10-17 15:48 ` Stephen Warren
2012-10-17 17:50 ` Linus Walleij
2 siblings, 0 replies; 4+ messages in thread
From: Stephen Warren @ 2012-10-17 15:48 UTC (permalink / raw)
To: linus.walleij
Cc: Pritesh Raithatha, linux-kernel, swarren,
linux-tegra@vger.kernel.org
On 10/17/2012 12:21 AM, Pritesh Raithatha wrote:
> Signed-off-by: Pritesh Raithatha <praithatha@nvidia.com>
(dropping stable from CC)
Acked-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Linus, if you could add Cc: stable when you commit it, that'd be useful
too. Thanks.
I have no idea how I screwed this up so badly, or how it worked when
programming completely bogus registers!
Adding a patch description would be useful especially for stable. A
useful patch description might be:
The bank numbers in the pinctrl driver must match the bank numbers in
the device tree. Swap the bank numbers in the driver to ensure this.
While we're at it, rename the #defines used for the bank base addresses
so it's more obvious which is which, and add comments indicating which
correspond to which device tree bank.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] pinctrl: tegra: correct bank for pingroup and drv pingroup
2012-10-17 6:21 [PATCH] pinctrl: tegra: correct bank for pingroup and drv pingroup Pritesh Raithatha
2012-10-17 15:04 ` Greg KH
2012-10-17 15:48 ` Stephen Warren
@ 2012-10-17 17:50 ` Linus Walleij
2 siblings, 0 replies; 4+ messages in thread
From: Linus Walleij @ 2012-10-17 17:50 UTC (permalink / raw)
To: Pritesh Raithatha; +Cc: linux-kernel, swarren
On Wed, Oct 17, 2012 at 8:21 AM, Pritesh Raithatha
<praithatha@nvidia.com> wrote:
> Signed-off-by: Pritesh Raithatha <praithatha@nvidia.com>
Thanks, applied with Stephens ACK/Test and stable tag.
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2012-10-17 17:50 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-10-17 6:21 [PATCH] pinctrl: tegra: correct bank for pingroup and drv pingroup Pritesh Raithatha
2012-10-17 15:04 ` Greg KH
2012-10-17 15:48 ` Stephen Warren
2012-10-17 17:50 ` Linus Walleij
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).