Re: [PATCH 3/7] PCI: imx6: Rework PHY search and mapping

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, May 11, 2021 at 3:11 AM Lucas Stach <l.stach@xxxxxxxxxxxxxx> wrote:
>
> Am Montag, dem 10.05.2021 um 12:05 -0500 schrieb Rob Herring:
> > On Mon, May 10, 2021 at 04:15:05PM +0200, Lucas Stach wrote:
> > > We don't need to have a phandle of the PHY, as we know the compatible
> > > of the node we are looking for. This will make it easier to put add
> > > more PHY handling for new generations later on, where the
> > > "fsl,imx7d-pcie-phy" phandle would be a misnomer.
> > >
> > > Also we can use a helper function to get the resource for us,
> > > simplifying out driver code a bit.
> >
> > Better yes, but really all the phy handling should be split out to
> > its own driver even in the older h/w with shared phy registers.
> >
> That would be a quite massive DT binding changing break, possibly even
> a separate driver. Maybe it's time to do this for i.MX8MM, as the
> current driver just kept piling on special cases for "almost the same"
> hardware that by now looks quite different to the original i.MX6 PCIe
> integration this driver was supposed to handle.

No, you don't need to change DT, and a DT change adding a phy node
wouldn't even be correct modeling of the h/w IMO. For the i.MX6 phy, a
separate PHY driver would have to create its own platform device in
its initcall (if the iMX6 PCI compatible is found). Then the PCI
driver would need to use a non-DT based phy_get() lookup. For the
cases with a phandle to the phy, I'd assume a phy driver could be
instantiated for that node. You'll again need a non-DT phy_get() if
not using the phy binding.

Rob



[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux