Re: [PATCH v1 1/1] PCI: keystone: Use device_get_match_data()

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

 



On Wed, Jul 28, 2021 at 6:51 PM Bjorn Helgaas <helgaas@xxxxxxxxxx> wrote:
> On Wed, Jul 28, 2021 at 01:55:58PM +0300, Andy Shevchenko wrote:
> > Instead of manipulations with OF APIs, use device_get_match_data().
> >
> > While at it, drop of_match_ptr() completely and make compiler happy,
> > otherwise it complains:
> >
> >   pci-keystone.c:1069:34: warning: ‘ks_pcie_of_match’ defined but not used [-Wunused-const-variable=]
>
> These are two separate things and I'd prefer two separate patches.
>
> I have a to-do item on my list to replace of_match_device(), as you
> did here.  I originally suggested replacing with
> device_get_match_data(), but I think Rob prefers
> of_device_get_match_data() because there's really no benefit to the
> extra indirection of device_get_match_data().  These are not drivers
> that may potentially be used with either ACPI or OF; they're just OF.
>
> Either way, I'd like to see a patch that does this for all drivers in
> drivers/pci/controller/ at the same time so they get slightly more
> consistent.
>
> Same for the .of_match_table update; a good change that I'd like to
> apply universally.  It looks like pcie-spear13xx.c, pcie-armada8k.c,
> pci-ftpci100.c, pci-v3-semi.c, pci-xgene.c, pcie-iproc-platform.c also
> have the same issue.

Thanks for the review, I will drop this.

-- 
With Best Regards,
Andy Shevchenko




[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