[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <0d4e8a8130e6a78ba3b6fcb3aee9858d22e5c23b.camel@linux.intel.com>
Date: Thu, 30 Jul 2020 10:53:55 -0700
From: "David E. Box" <david.e.box@...ux.intel.com>
To: Mark D Rustad <mrustad@...il.com>, Lee Jones <lee.jones@...aro.org>
Cc: dvhart@...radead.org, andy@...radead.org, bhelgaas@...gle.com,
alexander.h.duyck@...ux.intel.com,
linux-kernel <linux-kernel@...r.kernel.org>,
platform-driver-x86@...r.kernel.org, linux-pci@...r.kernel.org,
Andy Shevchenko <andy.shevchenko@...il.com>
Subject: Re: [PATCH V4 2/3] mfd: Intel Platform Monitoring Technology support
On Wed, 2020-07-29 at 15:59 -0700, Mark D Rustad wrote:
> at 12:58 AM, Lee Jones <lee.jones@...aro.org> wrote:
>
> > If you do:
> >
> > do {
> > int pos;
> >
> > pos = pci_find_next_ext_capability(pdev, pos,
> > PCI_EXT_CAP_ID_DVSEC);
> > if (!pos)
> > break;
> >
> > Then you can invoke pci_find_next_ext_capability() once, no?
>
> Part of your suggestion here won't work, because pos needs to be
> initialized to 0 the first time. As such it needs to be declared
> and
> initialized outside the loop. Other than that it may be ok.
Already done in V5. Thanks.
David
Powered by blists - more mailing lists