diff mbox series

[v2,1/4] reset: imx7: Add PCIE_CTRL_APPS_TURNOFF

Message ID c3a7dfd1395b12e170393a3da77e0d1602b9f542.1538670431.git.leonard.crestez@nxp.com (mailing list archive)
State New, archived
Delegated to: Bjorn Helgaas
Headers show
Series PCI: imx: Add PME_Turn_Off support | expand

Commit Message

Leonard Crestez Oct. 4, 2018, 4:34 p.m. UTC
This is required for the imx pci driver to send the PME_Turn_Off TLP.

Signed-off-by: Leonard Crestez <leonard.crestez@nxp.com>
Acked-by: Rob Herring <robh@kernel.org>
---
 drivers/reset/reset-imx7.c             | 1 +
 include/dt-bindings/reset/imx7-reset.h | 4 +++-
 2 files changed, 4 insertions(+), 1 deletion(-)

Comments

Philipp Zabel Oct. 4, 2018, 4:47 p.m. UTC | #1
Hi Leonard,

On Thu, 2018-10-04 at 16:34 +0000, Leonard Crestez wrote:
> This is required for the imx pci driver to send the PME_Turn_Off TLP.
> 
> Signed-off-by: Leonard Crestez <leonard.crestez@nxp.com>
> Acked-by: Rob Herring <robh@kernel.org>
> ---
>  drivers/reset/reset-imx7.c             | 1 +
>  include/dt-bindings/reset/imx7-reset.h | 4 +++-
>  2 files changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/reset/reset-imx7.c b/drivers/reset/reset-imx7.c
> index 97d9f08271c5..77911fa8f31d 100644
> --- a/drivers/reset/reset-imx7.c
> +++ b/drivers/reset/reset-imx7.c
> @@ -65,10 +65,11 @@ static const struct imx7_src_signal imx7_src_signals[IMX7_RESET_NUM] = {
>  	[IMX7_RESET_MIPI_PHY_MRST]	= { SRC_MIPIPHY_RCR, BIT(1) },
>  	[IMX7_RESET_MIPI_PHY_SRST]	= { SRC_MIPIPHY_RCR, BIT(2) },
>  	[IMX7_RESET_PCIEPHY]		= { SRC_PCIEPHY_RCR, BIT(2) | BIT(1) },
>  	[IMX7_RESET_PCIEPHY_PERST]	= { SRC_PCIEPHY_RCR, BIT(3) },
>  	[IMX7_RESET_PCIE_CTRL_APPS_EN]	= { SRC_PCIEPHY_RCR, BIT(6) },
> +	[IMX7_RESET_PCIE_CTRL_APPS_TURNOFF] = { SRC_PCIEPHY_RCR, BIT(11) },
>  	[IMX7_RESET_DDRC_PRST]		= { SRC_DDRC_RCR, BIT(0) },
>  	[IMX7_RESET_DDRC_CORE_RST]	= { SRC_DDRC_RCR, BIT(1) },
>  };
>  
>  static struct imx7_src *to_imx7_src(struct reset_controller_dev *rcdev)
> diff --git a/include/dt-bindings/reset/imx7-reset.h b/include/dt-bindings/reset/imx7-reset.h
> index 63948170c7b2..31b3f87dde9a 100644
> --- a/include/dt-bindings/reset/imx7-reset.h
> +++ b/include/dt-bindings/reset/imx7-reset.h
> @@ -54,9 +54,11 @@
>   */
>  #define IMX7_RESET_PCIE_CTRL_APPS_EN	22
>  #define IMX7_RESET_DDRC_PRST		23
>  #define IMX7_RESET_DDRC_CORE_RST	24
>  
> -#define IMX7_RESET_NUM			25
> +#define IMX7_RESET_PCIE_CTRL_APPS_TURNOFF 25
> +
> +#define IMX7_RESET_NUM			26
>  
>  #endif

This is contained enough to be merged with the rest of the series,
patches 1 and 2:

Acked-by: Philipp Zabel <p.zabel@pengutronix.de>

Let me know if I should pick them up instead.

regards
Philipp
Lorenzo Pieralisi Oct. 4, 2018, 5:08 p.m. UTC | #2
On Thu, Oct 04, 2018 at 06:47:01PM +0200, Philipp Zabel wrote:
> Hi Leonard,
> 
> On Thu, 2018-10-04 at 16:34 +0000, Leonard Crestez wrote:
> > This is required for the imx pci driver to send the PME_Turn_Off TLP.
> > 
> > Signed-off-by: Leonard Crestez <leonard.crestez@nxp.com>
> > Acked-by: Rob Herring <robh@kernel.org>
> > ---
> >  drivers/reset/reset-imx7.c             | 1 +
> >  include/dt-bindings/reset/imx7-reset.h | 4 +++-
> >  2 files changed, 4 insertions(+), 1 deletion(-)
> > 
> > diff --git a/drivers/reset/reset-imx7.c b/drivers/reset/reset-imx7.c
> > index 97d9f08271c5..77911fa8f31d 100644
> > --- a/drivers/reset/reset-imx7.c
> > +++ b/drivers/reset/reset-imx7.c
> > @@ -65,10 +65,11 @@ static const struct imx7_src_signal imx7_src_signals[IMX7_RESET_NUM] = {
> >  	[IMX7_RESET_MIPI_PHY_MRST]	= { SRC_MIPIPHY_RCR, BIT(1) },
> >  	[IMX7_RESET_MIPI_PHY_SRST]	= { SRC_MIPIPHY_RCR, BIT(2) },
> >  	[IMX7_RESET_PCIEPHY]		= { SRC_PCIEPHY_RCR, BIT(2) | BIT(1) },
> >  	[IMX7_RESET_PCIEPHY_PERST]	= { SRC_PCIEPHY_RCR, BIT(3) },
> >  	[IMX7_RESET_PCIE_CTRL_APPS_EN]	= { SRC_PCIEPHY_RCR, BIT(6) },
> > +	[IMX7_RESET_PCIE_CTRL_APPS_TURNOFF] = { SRC_PCIEPHY_RCR, BIT(11) },
> >  	[IMX7_RESET_DDRC_PRST]		= { SRC_DDRC_RCR, BIT(0) },
> >  	[IMX7_RESET_DDRC_CORE_RST]	= { SRC_DDRC_RCR, BIT(1) },
> >  };
> >  
> >  static struct imx7_src *to_imx7_src(struct reset_controller_dev *rcdev)
> > diff --git a/include/dt-bindings/reset/imx7-reset.h b/include/dt-bindings/reset/imx7-reset.h
> > index 63948170c7b2..31b3f87dde9a 100644
> > --- a/include/dt-bindings/reset/imx7-reset.h
> > +++ b/include/dt-bindings/reset/imx7-reset.h
> > @@ -54,9 +54,11 @@
> >   */
> >  #define IMX7_RESET_PCIE_CTRL_APPS_EN	22
> >  #define IMX7_RESET_DDRC_PRST		23
> >  #define IMX7_RESET_DDRC_CORE_RST	24
> >  
> > -#define IMX7_RESET_NUM			25
> > +#define IMX7_RESET_PCIE_CTRL_APPS_TURNOFF 25
> > +
> > +#define IMX7_RESET_NUM			26
> >  
> >  #endif
> 
> This is contained enough to be merged with the rest of the series,
> patches 1 and 2:
> 
> Acked-by: Philipp Zabel <p.zabel@pengutronix.de>
> 
> Let me know if I should pick them up instead.

I can take the whole series but I would like to have it rebased against
v4.19-rc4 please since it does not apply as it is, thanks.

Lorenzo
Leonard Crestez Oct. 4, 2018, 8:41 p.m. UTC | #3
On Thu, 2018-10-04 at 18:08 +0100, Lorenzo Pieralisi wrote:
> On Thu, Oct 04, 2018 at 06:47:01PM +0200, Philipp Zabel wrote:

> > This is contained enough to be merged with the rest of the series,
> > patches 1 and 2:
> > 
> > Acked-by: Philipp Zabel <p.zabel@pengutronix.de>
> > 
> > Let me know if I should pick them up instead.
> 
> I can take the whole series but I would like to have it rebased against
> v4.19-rc4 please since it does not apply as it is, thanks.

Series is from a branch on top of next-20181004 + a few other changes
but it applied it on top of your pci/dwc branch with no conflicts.

Pushed the branch here:

https://github.com/cdleonard/linux/commits/imx_pci_for_lorenzo

Assuming you want on top of this:

https://git.kernel.org/pub/scm/linux/kernel/git/lpieralisi/pci.git/log/?h=pci/dwc

--
Regards,
Leonard
diff mbox series

Patch

diff --git a/drivers/reset/reset-imx7.c b/drivers/reset/reset-imx7.c
index 97d9f08271c5..77911fa8f31d 100644
--- a/drivers/reset/reset-imx7.c
+++ b/drivers/reset/reset-imx7.c
@@ -65,10 +65,11 @@  static const struct imx7_src_signal imx7_src_signals[IMX7_RESET_NUM] = {
 	[IMX7_RESET_MIPI_PHY_MRST]	= { SRC_MIPIPHY_RCR, BIT(1) },
 	[IMX7_RESET_MIPI_PHY_SRST]	= { SRC_MIPIPHY_RCR, BIT(2) },
 	[IMX7_RESET_PCIEPHY]		= { SRC_PCIEPHY_RCR, BIT(2) | BIT(1) },
 	[IMX7_RESET_PCIEPHY_PERST]	= { SRC_PCIEPHY_RCR, BIT(3) },
 	[IMX7_RESET_PCIE_CTRL_APPS_EN]	= { SRC_PCIEPHY_RCR, BIT(6) },
+	[IMX7_RESET_PCIE_CTRL_APPS_TURNOFF] = { SRC_PCIEPHY_RCR, BIT(11) },
 	[IMX7_RESET_DDRC_PRST]		= { SRC_DDRC_RCR, BIT(0) },
 	[IMX7_RESET_DDRC_CORE_RST]	= { SRC_DDRC_RCR, BIT(1) },
 };
 
 static struct imx7_src *to_imx7_src(struct reset_controller_dev *rcdev)
diff --git a/include/dt-bindings/reset/imx7-reset.h b/include/dt-bindings/reset/imx7-reset.h
index 63948170c7b2..31b3f87dde9a 100644
--- a/include/dt-bindings/reset/imx7-reset.h
+++ b/include/dt-bindings/reset/imx7-reset.h
@@ -54,9 +54,11 @@ 
  */
 #define IMX7_RESET_PCIE_CTRL_APPS_EN	22
 #define IMX7_RESET_DDRC_PRST		23
 #define IMX7_RESET_DDRC_CORE_RST	24
 
-#define IMX7_RESET_NUM			25
+#define IMX7_RESET_PCIE_CTRL_APPS_TURNOFF 25
+
+#define IMX7_RESET_NUM			26
 
 #endif