* VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero
@ 2015-11-15 2:44 Andrew Lunn
2015-11-16 15:25 ` Alonso Adrian
2015-11-23 13:28 ` Shawn Guo
0 siblings, 2 replies; 8+ messages in thread
From: Andrew Lunn @ 2015-11-15 2:44 UTC (permalink / raw
To: linux-arm-kernel
Hi Adrian
Your patch
commit e7b37a522aa92da5f47106aa07b6c1fc58bfd922
Author: Adrian Alonso <aalonso@freescale.com>
Date: Fri Sep 25 16:05:59 2015 -0500
pinctrl: freescale: imx: allow mux_reg offset zero
Allow mux_reg offset zero to be a valid pin_id, on imx7d
mux_conf reg offset is zero for iomuxc-lspr controller
has broken VF610.
It looks like you partially reverted
commit 3dac1918a4912cea9375e76cb3916b751cef22db
Author: Stefan Agner <stefan@agner.ch>
Date: Sat Sep 6 18:25:04 2014 +0200
pinctrl: imx: detect uninitialized pins
The pinctrl driver initialized the register offsets for the pins
with 0. On Vybrid an offset of 0 is a valid offset for the pinctrl
mux register. So far, this was solved using the ZERO_OFFSET_VALID
flag which allowed offsets of 0. However, this does not allow to
verify whether a pins struct imx_pmx_func was initialized or not.
Use signed offset values for register offsets and initialize those
with -1 in order to detect uninitialized offset values reliable.
and in the process you have broken VF610, which also uses offset 0.
What i don't yet understand is why you needed to make this change. If
VF610 can already use mux_reg, why cannot imx7d?
Anyway, it looks like -rc1 is going to be broken on VF610 for some
boards, because this pin is the Ethernet clock input/output. Please
can you get it fixed for -rc2?
Thanks
Andrew
^ permalink raw reply [flat|nested] 8+ messages in thread
* VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero
2015-11-15 2:44 VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero Andrew Lunn
@ 2015-11-16 15:25 ` Alonso Adrian
2015-11-20 13:54 ` Andrew Lunn
2015-11-23 13:28 ` Shawn Guo
1 sibling, 1 reply; 8+ messages in thread
From: Alonso Adrian @ 2015-11-16 15:25 UTC (permalink / raw
To: linux-arm-kernel
Hi Adrew,
> -----Original Message-----
> From: Andrew Lunn [mailto:andrew at lunn.ch]
> Sent: Saturday, November 14, 2015 8:44 PM
> To: Alonso Lazcano Adrian-B38018 <aalonso@freescale.com>
> Cc: Linus Walleij <linus.walleij@linaro.org>; Shawn Guo
> <shawnguo@kernel.org>; stefan at agner.ch; linux ARM <linux-arm-
> kernel at lists.infradead.org>
> Subject: VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero
>
> Hi Adrian
>
> Your patch
>
> commit e7b37a522aa92da5f47106aa07b6c1fc58bfd922
> Author: Adrian Alonso <aalonso@freescale.com>
> Date: Fri Sep 25 16:05:59 2015 -0500
>
> pinctrl: freescale: imx: allow mux_reg offset zero
>
> Allow mux_reg offset zero to be a valid pin_id, on imx7d
> mux_conf reg offset is zero for iomuxc-lspr controller
>
> has broken VF610.
>
> It looks like you partially reverted
>
> commit 3dac1918a4912cea9375e76cb3916b751cef22db
> Author: Stefan Agner <stefan@agner.ch>
> Date: Sat Sep 6 18:25:04 2014 +0200
>
> pinctrl: imx: detect uninitialized pins
>
> The pinctrl driver initialized the register offsets for the pins
> with 0. On Vybrid an offset of 0 is a valid offset for the pinctrl
> mux register. So far, this was solved using the ZERO_OFFSET_VALID
> flag which allowed offsets of 0. However, this does not allow to
> verify whether a pins struct imx_pmx_func was initialized or not.
>
> Use signed offset values for register offsets and initialize those
> with -1 in order to detect uninitialized offset values reliable.
>
> and in the process you have broken VF610, which also uses offset 0.
>
> What i don't yet understand is why you needed to make this change. If
> VF610 can already use mux_reg, why cannot imx7d?
[Adrian] iMX7D has two iomuxc controllers where mux_reg id's overlap for each controller
So mux_reg offset can't be used to resolve the corresponding pad_id;
>
> Anyway, it looks like -rc1 is going to be broken on VF610 for some boards,
> because this pin is the Ethernet clock input/output. Please can you get it fixed
> for -rc2?
>
[Adrian] Sure let me take a look at this.
> Thanks
> Andrew
^ permalink raw reply [flat|nested] 8+ messages in thread
* VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero
2015-11-16 15:25 ` Alonso Adrian
@ 2015-11-20 13:54 ` Andrew Lunn
0 siblings, 0 replies; 8+ messages in thread
From: Andrew Lunn @ 2015-11-20 13:54 UTC (permalink / raw
To: linux-arm-kernel
> > Anyway, it looks like -rc1 is going to be broken on VF610 for some boards,
> > because this pin is the Ethernet clock input/output. Please can you get it fixed
> > for -rc2?
> >
> [Adrian] Sure let me take a look at this.
Hi Adrian
Do you have a fix for this regression yet? I'm happy to test patches.
Thanks
Andrew
^ permalink raw reply [flat|nested] 8+ messages in thread
* VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero
2015-11-15 2:44 VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero Andrew Lunn
2015-11-16 15:25 ` Alonso Adrian
@ 2015-11-23 13:28 ` Shawn Guo
2015-11-23 15:08 ` Andrew Lunn
2015-11-25 2:10 ` Andrew Lunn
1 sibling, 2 replies; 8+ messages in thread
From: Shawn Guo @ 2015-11-23 13:28 UTC (permalink / raw
To: linux-arm-kernel
Hi Andrew,
On Sun, Nov 15, 2015 at 03:44:09AM +0100, Andrew Lunn wrote:
> Hi Adrian
>
> Your patch
>
> commit e7b37a522aa92da5f47106aa07b6c1fc58bfd922
> Author: Adrian Alonso <aalonso@freescale.com>
> Date: Fri Sep 25 16:05:59 2015 -0500
>
> pinctrl: freescale: imx: allow mux_reg offset zero
>
> Allow mux_reg offset zero to be a valid pin_id, on imx7d
> mux_conf reg offset is zero for iomuxc-lspr controller
>
> has broken VF610.
>
> It looks like you partially reverted
>
> commit 3dac1918a4912cea9375e76cb3916b751cef22db
> Author: Stefan Agner <stefan@agner.ch>
> Date: Sat Sep 6 18:25:04 2014 +0200
>
> pinctrl: imx: detect uninitialized pins
>
> The pinctrl driver initialized the register offsets for the pins
> with 0. On Vybrid an offset of 0 is a valid offset for the pinctrl
> mux register. So far, this was solved using the ZERO_OFFSET_VALID
> flag which allowed offsets of 0. However, this does not allow to
> verify whether a pins struct imx_pmx_func was initialized or not.
>
> Use signed offset values for register offsets and initialize those
> with -1 in order to detect uninitialized offset values reliable.
>
> and in the process you have broken VF610, which also uses offset 0.
>
> What i don't yet understand is why you needed to make this change. If
> VF610 can already use mux_reg, why cannot imx7d?
>
> Anyway, it looks like -rc1 is going to be broken on VF610 for some
> boards, because this pin is the Ethernet clock input/output. Please
> can you get it fixed for -rc2?
Can you please try the following change to see if it fixes your problem?
Shawn
diff --git a/drivers/pinctrl/freescale/pinctrl-vf610.c b/drivers/pinctrl/freescale/pinctrl-vf610.c
index 37a037543d29..587d1ff6210e 100644
--- a/drivers/pinctrl/freescale/pinctrl-vf610.c
+++ b/drivers/pinctrl/freescale/pinctrl-vf610.c
@@ -299,7 +299,7 @@ static const struct pinctrl_pin_desc vf610_pinctrl_pads[] = {
static struct imx_pinctrl_soc_info vf610_pinctrl_info = {
.pins = vf610_pinctrl_pads,
.npins = ARRAY_SIZE(vf610_pinctrl_pads),
- .flags = SHARE_MUX_CONF_REG,
+ .flags = SHARE_MUX_CONF_REG | ZERO_OFFSET_VALID,
};
static const struct of_device_id vf610_pinctrl_of_match[] = {
^ permalink raw reply related [flat|nested] 8+ messages in thread
* VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero
2015-11-23 13:28 ` Shawn Guo
@ 2015-11-23 15:08 ` Andrew Lunn
2015-11-24 5:41 ` Shawn Guo
2015-11-25 2:10 ` Andrew Lunn
1 sibling, 1 reply; 8+ messages in thread
From: Andrew Lunn @ 2015-11-23 15:08 UTC (permalink / raw
To: linux-arm-kernel
> Can you please try the following change to see if it fixes your problem?
>
> Shawn
>
> diff --git a/drivers/pinctrl/freescale/pinctrl-vf610.c b/drivers/pinctrl/freescale/pinctrl-vf610.c
> index 37a037543d29..587d1ff6210e 100644
> --- a/drivers/pinctrl/freescale/pinctrl-vf610.c
> +++ b/drivers/pinctrl/freescale/pinctrl-vf610.c
> @@ -299,7 +299,7 @@ static const struct pinctrl_pin_desc vf610_pinctrl_pads[] = {
> static struct imx_pinctrl_soc_info vf610_pinctrl_info = {
> .pins = vf610_pinctrl_pads,
> .npins = ARRAY_SIZE(vf610_pinctrl_pads),
> - .flags = SHARE_MUX_CONF_REG,
> + .flags = SHARE_MUX_CONF_REG | ZERO_OFFSET_VALID,
> };
>
> static const struct of_device_id vf610_pinctrl_of_match[] = {
Hi Shawn
I'm away from the hardware right now, but yes, that should fix it.
Andrew
^ permalink raw reply [flat|nested] 8+ messages in thread
* VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero
2015-11-23 15:08 ` Andrew Lunn
@ 2015-11-24 5:41 ` Shawn Guo
0 siblings, 0 replies; 8+ messages in thread
From: Shawn Guo @ 2015-11-24 5:41 UTC (permalink / raw
To: linux-arm-kernel
On Mon, Nov 23, 2015 at 04:08:23PM +0100, Andrew Lunn wrote:
> > Can you please try the following change to see if it fixes your problem?
> >
> > Shawn
> >
> > diff --git a/drivers/pinctrl/freescale/pinctrl-vf610.c b/drivers/pinctrl/freescale/pinctrl-vf610.c
> > index 37a037543d29..587d1ff6210e 100644
> > --- a/drivers/pinctrl/freescale/pinctrl-vf610.c
> > +++ b/drivers/pinctrl/freescale/pinctrl-vf610.c
> > @@ -299,7 +299,7 @@ static const struct pinctrl_pin_desc vf610_pinctrl_pads[] = {
> > static struct imx_pinctrl_soc_info vf610_pinctrl_info = {
> > .pins = vf610_pinctrl_pads,
> > .npins = ARRAY_SIZE(vf610_pinctrl_pads),
> > - .flags = SHARE_MUX_CONF_REG,
> > + .flags = SHARE_MUX_CONF_REG | ZERO_OFFSET_VALID,
> > };
> >
> > static const struct of_device_id vf610_pinctrl_of_match[] = {
>
> Hi Shawn
>
> I'm away from the hardware right now, but yes, that should fix it.
I would wait for your testing confirmation to send the formal patch.
Shawn
^ permalink raw reply [flat|nested] 8+ messages in thread
* VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero
2015-11-23 13:28 ` Shawn Guo
2015-11-23 15:08 ` Andrew Lunn
@ 2015-11-25 2:10 ` Andrew Lunn
2015-11-25 3:08 ` Stefan Agner
1 sibling, 1 reply; 8+ messages in thread
From: Andrew Lunn @ 2015-11-25 2:10 UTC (permalink / raw
To: linux-arm-kernel
> Can you please try the following change to see if it fixes your problem?
>
> Shawn
>
> diff --git a/drivers/pinctrl/freescale/pinctrl-vf610.c b/drivers/pinctrl/freescale/pinctrl-vf610.c
> index 37a037543d29..587d1ff6210e 100644
> --- a/drivers/pinctrl/freescale/pinctrl-vf610.c
> +++ b/drivers/pinctrl/freescale/pinctrl-vf610.c
> @@ -299,7 +299,7 @@ static const struct pinctrl_pin_desc vf610_pinctrl_pads[] = {
> static struct imx_pinctrl_soc_info vf610_pinctrl_info = {
> .pins = vf610_pinctrl_pads,
> .npins = ARRAY_SIZE(vf610_pinctrl_pads),
> - .flags = SHARE_MUX_CONF_REG,
> + .flags = SHARE_MUX_CONF_REG | ZERO_OFFSET_VALID,
> };
>
> static const struct of_device_id vf610_pinctrl_of_match[] = {
Hi Shawn
I tested it, and it does work.
Thanks
Andrew
^ permalink raw reply [flat|nested] 8+ messages in thread
* VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero
2015-11-25 2:10 ` Andrew Lunn
@ 2015-11-25 3:08 ` Stefan Agner
0 siblings, 0 replies; 8+ messages in thread
From: Stefan Agner @ 2015-11-25 3:08 UTC (permalink / raw
To: linux-arm-kernel
On 2015-11-24 18:10, Andrew Lunn wrote:
>> Can you please try the following change to see if it fixes your problem?
>>
>> Shawn
>>
>> diff --git a/drivers/pinctrl/freescale/pinctrl-vf610.c b/drivers/pinctrl/freescale/pinctrl-vf610.c
>> index 37a037543d29..587d1ff6210e 100644
>> --- a/drivers/pinctrl/freescale/pinctrl-vf610.c
>> +++ b/drivers/pinctrl/freescale/pinctrl-vf610.c
>> @@ -299,7 +299,7 @@ static const struct pinctrl_pin_desc vf610_pinctrl_pads[] = {
>> static struct imx_pinctrl_soc_info vf610_pinctrl_info = {
>> .pins = vf610_pinctrl_pads,
>> .npins = ARRAY_SIZE(vf610_pinctrl_pads),
>> - .flags = SHARE_MUX_CONF_REG,
>> + .flags = SHARE_MUX_CONF_REG | ZERO_OFFSET_VALID,
>> };
>>
>> static const struct of_device_id vf610_pinctrl_of_match[] = {
>
> Hi Shawn
>
> I tested it, and it does work.
Thanks for bringing this up and testing this. FWIW:
Acked-by: Stefan Agner <stefan@agner.ch>
--
Stefan
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2015-11-25 3:08 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-15 2:44 VF610 broken by pinctrl: freescale: imx: allow mux_reg offset zero Andrew Lunn
2015-11-16 15:25 ` Alonso Adrian
2015-11-20 13:54 ` Andrew Lunn
2015-11-23 13:28 ` Shawn Guo
2015-11-23 15:08 ` Andrew Lunn
2015-11-24 5:41 ` Shawn Guo
2015-11-25 2:10 ` Andrew Lunn
2015-11-25 3:08 ` Stefan Agner
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.