diff mbox

[v4,10/10] ARM: imx6sx: enable pcie on imx6sx sdb board

Message ID 1412069804-17162-11-git-send-email-r65037@freescale.com (mailing list archive)
State New, archived
Delegated to: Bjorn Helgaas
Headers show

Commit Message

Richard Zhu Sept. 30, 2014, 9:36 a.m. UTC
Signed-off-by: Richard Zhu <r65037@freescale.com>
---
 arch/arm/boot/dts/imx6sx-sdb.dts | 13 +++++++++++++
 1 file changed, 13 insertions(+)

Comments

Fabio Estevam Sept. 30, 2014, 4:21 p.m. UTC | #1
Hi Richard,

On Tue, Sep 30, 2014 at 6:36 AM, Richard Zhu <r65037@freescale.com> wrote:
> Signed-off-by: Richard Zhu <r65037@freescale.com>
> ---
>  arch/arm/boot/dts/imx6sx-sdb.dts | 13 +++++++++++++
>  1 file changed, 13 insertions(+)
>
> diff --git a/arch/arm/boot/dts/imx6sx-sdb.dts b/arch/arm/boot/dts/imx6sx-sdb.dts
> index a3980d9..2976913 100644
> --- a/arch/arm/boot/dts/imx6sx-sdb.dts
> +++ b/arch/arm/boot/dts/imx6sx-sdb.dts
> @@ -251,6 +251,13 @@
>         };
>  };
>
> +&pcie {
> +       pinctrl-names = "default";
> +       pinctrl-0 = <&pinctrl_pcie>;
> +       reset-gpio = <&gpio2 0 0>;
> +       status = "okay";
> +};

There is also GPIO2_1 which is the PCIE_PWR_EN signal and should be
added as a GPIO controlled regulator.
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Richard Zhu Oct. 2, 2014, 2:40 a.m. UTC | #2
WWVzLCAgUENJRV9QV1JfRU4gd291bGQgYmUgYWRkZWQgbGF0ZXIuDQpUaGFua3MsIEZhYmlvLg0K
DQpCZXN0IHJlZ2FyZHMNClJpY2hhcmQNCg0KPiDU2iAyMDE0xOoxMNTCMcjVo6zJz87nMTI6MjGj
rCJGYWJpbyBFc3RldmFtIiA8ZmVzdGV2YW1AZ21haWwuY29tPiDQtLXAo7o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yb2xsZWQgcmVndWxhdG9yLg0K
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Richard Zhu Oct. 8, 2014, 6:41 a.m. UTC | #3
Hi Fabio:

> -----Original Message-----

> From: Zhu Richard-R65037

> Sent: Thursday, October 02, 2014 10:40 AM

> To: Fabio Estevam

> Cc: Zhu Richard-R65037; linux-pci-owner@vger.kernel.org; linux-

> pci@vger.kernel.org; Guo Shawn-R65073; Lucas Stach; Tim Harvey

> Subject: Re: [PATCH v4 10/10] ARM: imx6sx: enable pcie on imx6sx sdb board

> 

> Yes,  PCIE_PWR_EN would be added later.

> Thanks, Fabio.

> 

> Best regards

> Richard

> 

> > ? 2014?10?1????12:21?"Fabio Estevam" <festevam@gmail.com> ???

> >

> > Hi Richard,

> >

> >> On Tue, Sep 30, 2014 at 6:36 AM, Richard Zhu <r65037@freescale.com> wrote:

> >> Signed-off-by: Richard Zhu <r65037@freescale.com>

> >> ---

> >> arch/arm/boot/dts/imx6sx-sdb.dts | 13 +++++++++++++

> >> 1 file changed, 13 insertions(+)

> >>

> >> diff --git a/arch/arm/boot/dts/imx6sx-sdb.dts

> >> b/arch/arm/boot/dts/imx6sx-sdb.dts

> >> index a3980d9..2976913 100644

> >> --- a/arch/arm/boot/dts/imx6sx-sdb.dts

> >> +++ b/arch/arm/boot/dts/imx6sx-sdb.dts

> >> @@ -251,6 +251,13 @@

> >>        };

> >> };

> >>

> >> +&pcie {

> >> +       pinctrl-names = "default";

> >> +       pinctrl-0 = <&pinctrl_pcie>;

> >> +       reset-gpio = <&gpio2 0 0>;

> >> +       status = "okay";

> >> +};

> >

> > There is also GPIO2_1 which is the PCIE_PWR_EN signal and should be

> > added as a GPIO controlled regulator.

[Richard] The GIPO controlled regulator is discarded in the latest kernel, it is pointed out by Lucas in the
previous review.
"
> @@ -502,6 +503,7 @@

>  &pcie {

>  	pinctrl-names = "default";

>  	pinctrl-0 = <&pinctrl_pcie>;

> +	power-on-gpio = <&gpio3 19 0>;

>  	reset-gpio = <&gpio7 12 0>;

>  	status = "okay";

>  };


This hunk is wrong. There is no "power-on-gpio" in the binding anymore.
Also there is already a change in Shawns tree to model this as a always-on regulator. If we really want to control pci bus power this needs to be done through this regulator, not some arbitrary gpio hack.
"

Best Regards
Richard Zhu
Fabio Estevam Oct. 9, 2014, 1:11 a.m. UTC | #4
On Wed, Oct 8, 2014 at 3:41 AM, Hong-Xing.Zhu@freescale.com
<Hong-Xing.Zhu@freescale.com> wrote:

> This hunk is wrong. There is no "power-on-gpio" in the binding anymore.
> Also there is already a change in Shawns tree to model this as a always-on regulator. If we really want to control pci bus power this needs to be done through this regulator, not some arbitrary gpio hack.

Yes, I never asked you to include 'power-on-gpio'. What needs to be
done is the same as in imx6qdl-sabresd, which passes the regulator
that powers the PCI slot. You can refer to Shawn's tree or linux-next.
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Richard Zhu Oct. 9, 2014, 5:39 a.m. UTC | #5
DQo+IC0tLS0tT3JpZ2luYWwgTWVzc2FnZS0tLS0tDQo+IEZyb206IEZhYmlvIEVzdGV2YW0gW21h
aWx0bzpmZXN0ZXZhbUBnbWFpbC5jb21dDQo+IFNlbnQ6IFRodXJzZGF5LCBPY3RvYmVyIDA5LCAy
MDE0IDk6MTEgQU0NCj4gVG86IFpodSBSaWNoYXJkLVI2NTAzNw0KPiBDYzogbGludXgtcGNpLW93
bmVyQHZnZXIua2VybmVsLm9yZzsgbGludXgtcGNpQHZnZXIua2VybmVsLm9yZzsgR3VvIFNoYXdu
LQ0KPiBSNjUwNzM7IEx1Y2FzIFN0YWNoOyBUaW0gSGFydmV5DQo+IFN1YmplY3Q6IFJlOiBbUEFU
Q0ggdjQgMTAvMTBdIEFSTTogaW14NnN4OiBlbmFibGUgcGNpZSBvbiBpbXg2c3ggc2RiIGJvYX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: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/arch/arm/boot/dts/imx6sx-sdb.dts b/arch/arm/boot/dts/imx6sx-sdb.dts
index a3980d9..2976913 100644
--- a/arch/arm/boot/dts/imx6sx-sdb.dts
+++ b/arch/arm/boot/dts/imx6sx-sdb.dts
@@ -251,6 +251,13 @@ 
 	};
 };
 
+&pcie {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_pcie>;
+	reset-gpio = <&gpio2 0 0>;
+	status = "okay";
+};
+
 &ssi2 {
 	status = "okay";
 };
@@ -365,6 +372,12 @@ 
 			>;
 		};
 
+		pinctrl_pcie: pciegrp {
+			fsl,pins = <
+				MX6SX_PAD_ENET1_COL__GPIO2_IO_0 0x17059
+			>;
+		};
+
 		pinctrl_vcc_sd3: vccsd3grp {
 			fsl,pins = <
 				MX6SX_PAD_KEY_COL1__GPIO2_IO_11		0x17059