Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1499004

Re: [PATCH 3/4] PCI: dra7xx: Add support to force RC to work in GEN1 mode

From Sekhar Nori <nsekhar@ti.com>
Newsgroups linux.kernel
Subject Re: [PATCH 3/4] PCI: dra7xx: Add support to force RC to work in GEN1 mode
Date 2016-10-11 18:30 +0200
Message-ID <sr86d-wM-17@gated-at.bofh.it> (permalink)
References <sr4YF-77t-5@gated-at.bofh.it> <sr4YG-77t-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tuesday 11 October 2016 06:28 PM, Kishon Vijay Abraham I wrote:
> PCIe in AM57x/DRA7x devices is by default
> configured to work in GEN2 mode.  However there
> may be situations when working in GEN1 mode is
> desired. One example is limitation i925 (PCIe GEN2
> mode not supported at junction temperatures < 0C).
> 
> Add support to force Root Complex to work in GEN1
> mode if so desired, but don't force GEN1 mode on
> any board just yet.
> 
> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
> Signed-off-by: Sekhar Nori <nsekhar@ti.com>
> ---
>  Documentation/devicetree/bindings/pci/ti-pci.txt |    1 +
>  drivers/pci/host/pci-dra7xx.c                    |   27 ++++++++++++++++++++++
>  2 files changed, 28 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/pci/ti-pci.txt b/Documentation/devicetree/bindings/pci/ti-pci.txt
> index 60e2516..a3d6ca3 100644
> --- a/Documentation/devicetree/bindings/pci/ti-pci.txt
> +++ b/Documentation/devicetree/bindings/pci/ti-pci.txt
> @@ -25,6 +25,7 @@ PCIe Designware Controller
>  
>  Optional Property:
>   - gpios : Should be added if a gpio line is required to drive PERST# line
> + - ti,pcie-is-gen1 : Force the PCIe controller to work in GEN1 (2.5 GT/s).
>  
>  Example:
>  axi {
> diff --git a/drivers/pci/host/pci-dra7xx.c b/drivers/pci/host/pci-dra7xx.c
> index 4ccba6d..2a669cb 100644
> --- a/drivers/pci/host/pci-dra7xx.c
> +++ b/drivers/pci/host/pci-dra7xx.c
> @@ -63,11 +63,14 @@
>  #define	LINK_UP						BIT(16)
>  #define	DRA7XX_CPU_TO_BUS_ADDR				0x0FFFFFFF
>  
> +#define EXP_CAP_ID_OFFSET				0x70
> +
>  struct dra7xx_pcie {
>  	struct pcie_port	pp;
>  	void __iomem		*base;		/* DT ti_conf */
>  	int			phy_count;	/* DT phy-names count */
>  	struct phy		**phy;
> +	bool			is_gen1;

I think it will be nice to reference the errata number as comments in
the code along with references to TI public documentation that explains
the said errata.

Or may be this can be added to the binding documentation. Somewhere 'git
grep' can find.

BTW, per Documentation/devicetree/bindings/submitting-patches.txt, the
binding documentation should be a separate patch.

Thanks,
Sekhar

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 0/4] PCI: designware/dra7xx: misc fixes and cleanups Kishon Vijay Abraham I <kishon@ti.com> - 2016-10-11 15:10 +0200
  [PATCH 3/4] PCI: dra7xx: Add support to force RC to work in GEN1 mode Kishon Vijay Abraham I <kishon@ti.com> - 2016-10-11 15:10 +0200
    Re: [PATCH 3/4] PCI: dra7xx: Add support to force RC to work in GEN1  mode Sekhar Nori <nsekhar@ti.com> - 2016-10-11 18:30 +0200
    Re: [PATCH 3/4] PCI: dra7xx: Add support to force RC to work in GEN1  mode Shawn Lin <shawn.lin@rock-chips.com> - 2016-10-12 06:20 +0200
  [PATCH 4/4] PCI: dra7xx: Enable MSI and legacy interrupts simultaneously Kishon Vijay Abraham I <kishon@ti.com> - 2016-10-11 15:10 +0200
  [PATCH 2/4] PCI: dra7xx: simplify the probe code Kishon Vijay Abraham I <kishon@ti.com> - 2016-10-11 15:10 +0200
  [PATCH 1/4] PCI: designware: Fix compiler warning Kishon Vijay Abraham I <kishon@ti.com> - 2016-10-11 15:10 +0200
    Re: [PATCH 1/4] PCI: designware: Fix compiler warning Bjorn Helgaas <helgaas@kernel.org> - 2016-10-11 16:00 +0200

csiph-web