Re: [PATCH v2 6/9] ethernet: stmicro: Simplify PCI devres usage

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

 



On Wed, Aug 21, 2024 at 11:36:36AM +0200, Philipp Stanner wrote:
> On Wed, 2024-08-21 at 11:14 +0300, Andy Shevchenko wrote:
> > On Wed, Aug 21, 2024 at 10:19 AM Philipp Stanner
> > <pstanner@xxxxxxxxxx> wrote:

...

> > > -       for (i = 0; i < PCI_STD_NUM_BARS; i++) {
> > > -               if (pci_resource_len(pdev, i) == 0)
> > > -                       continue;
> > > -               pcim_iounmap_regions(pdev, BIT(i));
> > 
> > Here is the BARx, which contradicts the probe :-)
> 
> I'm not sure what should be done about it. The only interesting
> question is whether the other code with pcim_iomap_regions(... BIT(i)
> does also only grap BAR 0.
> In that case the driver wouldn't even be knowing what its own hardware
> is / does, though.

I think your patch does the right thing already.

> > > -               break;
> > > -       }

-- 
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