[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190827142855.GG2680@smile.fi.intel.com>
Date: Tue, 27 Aug 2019 17:28:55 +0300
From: Andy Shevchenko <andriy.shevchenko@...el.com>
To: Martin Blumenstingl <martin.blumenstingl@...glemail.com>
Cc: "Chuan Hua, Lei" <chuanhua.lei@...ux.intel.com>,
eswara.kota@...ux.intel.com, cheol.yong.kim@...el.com,
devicetree@...r.kernel.org, gustavo.pimentel@...opsys.com,
hch@...radead.org, jingoohan1@...il.com,
linux-kernel@...r.kernel.org, linux-pci@...r.kernel.org,
qi-ming.wu@...el.com
Subject: Re: [PATCH v2 3/3] dwc: PCI: intel: Intel PCIe RC controller driver
On Mon, Aug 26, 2019 at 11:15:48PM +0200, Martin Blumenstingl wrote:
> On Mon, Aug 26, 2019 at 5:31 AM Chuan Hua, Lei
> <chuanhua.lei@...ux.intel.com> wrote:
> > As I mentioned, VRX200 was a very old PCIe Gen1.1 product. In our latest
> > SoC Lightning
> >
> > Mountain, we are using synopsys controller 5.20/5.50a. We support
> > Gen2(XRX350/550),
> >
> > Gen3(PRX300) and GEN4(X86 based SoC). We also supported dual lane and
> > single lane.
> >
> > Some of the above registers are needed to control FTS, link width and
> > link speed.
> only now I noticed that I didn't explain why I was asking whether all
> these registers are needed
> my understanding of the DWC PCIe controller driver "library" is that:
> - all functionality which is provided by the DesignWare PCIe core
> should be added to drivers/pci/controller/dwc/pcie-designware*
> - functionality which is built on top/around the DWC PCIe core should
> be added to <vendor specific driver>
>
> the link width and link speed settings (I don't know about "FTS")
> don't seem Intel/Lantiq controller specific to me
> so the register setup for these bits should be moved to
> drivers/pci/controller/dwc/pcie-designware*
I think it may be done this way. We have already example with stmmac
(DWC network card IP) driver which split in similar way.
> > We can support up to XRX350/XRX500/PRX300 for MIPS SoC since we still
> > sell these products.
> OK, I understand this.
> switching to regmap will give you two benefits:
> - big endian registers writes (without additional code) on the MIPS SoCs
> - you can drop the pcie_app_* helper functions and use
> regmap_{read,write,update_bits} instead
Actually one more, i.e. dump of the registers by request via debugfs, which
I found very helpful.
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists