From: "Krzysztof Wilczyński" <kw@linux.com>
To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: linux-pci@vger.kernel.org,
"Dominik Brodowski" <linux@dominikbrodowski.net>,
linux-mips@vger.kernel.org, "Bjorn Helgaas" <bhelgaas@google.com>,
sparclinux@vger.kernel.org,
"Stefano Stabellini" <sstabellini@kernel.org>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
"Russell King" <linux@armlinux.org.uk>,
"Bjorn Helgaas" <helgaas@kernel.org>,
"Miguel Ojeda" <ojeda@kernel.org>,
xen-devel@lists.xenproject.org,
"Matt Turner" <mattst88@gmail.com>,
"Arnd Bergmann" <arnd@arndb.de>,
"Richard Henderson" <richard.henderson@linaro.org>,
"Nicholas Piggin" <npiggin@gmail.com>,
"Ivan Kokshaysky" <ink@jurassic.park.msu.ru>,
"Mickaël Salaün" <mic@digikod.net>,
"Mika Westerberg" <mika.westerberg@linux.intel.com>,
linux-arm-kernel@lists.infradead.org,
"Juergen Gross" <jgross@suse.com>,
"Thomas Bogendoerfer" <tsbogend@alpha.franken.de>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 4/4] pcmcia: Convert to use pci_bus_for_each_resource_p()
Date: Fri, 4 Nov 2022 03:29:44 +0900 [thread overview]
Message-ID: <Y2QImB0OLakzz1+F@rocinante> (raw)
In-Reply-To: <Y2P2ja26ikNecTsv@smile.fi.intel.com>
Hello,
[...]
> > > -
> > > - for (i = 0; i < PCI_BRIDGE_RESOURCE_NUM; i++) {
> > > - res = s->cb_dev->bus->resource[i];
> > > -#else
> > > - pci_bus_for_each_resource(s->cb_dev->bus, res, i) {
> > > #endif
> > > +
> > > + pci_bus_for_each_resource_p(s->cb_dev->bus, res) {
> > > if (!res)
> > > continue;
> >
> > Doesn't this remove the proper iterator for X86? Even if that is the right
> > thing to do, it needs an explict explanation.
>
> I dunno what was in 2010, but reading code now I have found no differences in
> the logic on how resources are being iterated in these two pieces of code.
This code is over a decade old (13 years old to be precise) and there was
something odd between Bjorn's and Jesse's patches, as per:
89a74ecccd1f ("PCI: add pci_bus_for_each_resource(), remove direct bus->resource[] refs")
cf26e8dc4194 ("pcmcia: do not autoadd root PCI bus resources")
> But fine, I will add a line to a commit message about this change.
I wouldn't, personally. The change you are proposing is self-explanatory
and somewhat in-line with what is there already - unless I am also reading
the current implementation wrong.
That said, Dominik is the maintainer of PCMCIA driver, so his is the last
word, so to speak. :)
> Considering this is done, can you issue your conditional tag so I will
> incorporate it in v3?
No need, really. Again, unless Dominik thinks otherwise.
Krzysztof
WARNING: multiple messages have this Message-ID (diff)
From: "Krzysztof Wilczyński" <kw@linux.com>
To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: "Dominik Brodowski" <linux@dominikbrodowski.net>,
"Mickaël Salaün" <mic@digikod.net>,
"Mika Westerberg" <mika.westerberg@linux.intel.com>,
"Michael Ellerman" <mpe@ellerman.id.au>,
"Arnd Bergmann" <arnd@arndb.de>,
"Bjorn Helgaas" <helgaas@kernel.org>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
"Juergen Gross" <jgross@suse.com>,
linux-kernel@vger.kernel.org, linux-alpha@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, linux-mips@vger.kernel.org,
linuxppc-dev@lists.ozlabs.org, sparclinux@vger.kernel.org,
linux-pci@vger.kernel.org, xen-devel@lists.xenproject.org,
"Miguel Ojeda" <ojeda@kernel.org>,
"Richard Henderson" <richard.henderson@linaro.org>,
"Ivan Kokshaysky" <ink@jurassic.park.msu.ru>,
"Matt Turner" <mattst88@gmail.com>,
"Russell King" <linux@armlinux.org.uk>,
"Thomas Bogendoerfer" <tsbogend@alpha.franken.de>,
"Nicholas Piggin" <npiggin@gmail.com>,
"Christophe Leroy" <christophe.leroy@csgroup.eu>,
"David S. Miller" <davem@davemloft.net>,
"Bjorn Helgaas" <bhelgaas@google.com>,
"Stefano Stabellini" <sstabellini@kernel.org>,
"Oleksandr Tyshchenko" <oleksandr_tyshchenko@epam.com>
Subject: Re: [PATCH v2 4/4] pcmcia: Convert to use pci_bus_for_each_resource_p()
Date: Fri, 4 Nov 2022 03:29:44 +0900 [thread overview]
Message-ID: <Y2QImB0OLakzz1+F@rocinante> (raw)
In-Reply-To: <Y2P2ja26ikNecTsv@smile.fi.intel.com>
Hello,
[...]
> > > -
> > > - for (i = 0; i < PCI_BRIDGE_RESOURCE_NUM; i++) {
> > > - res = s->cb_dev->bus->resource[i];
> > > -#else
> > > - pci_bus_for_each_resource(s->cb_dev->bus, res, i) {
> > > #endif
> > > +
> > > + pci_bus_for_each_resource_p(s->cb_dev->bus, res) {
> > > if (!res)
> > > continue;
> >
> > Doesn't this remove the proper iterator for X86? Even if that is the right
> > thing to do, it needs an explict explanation.
>
> I dunno what was in 2010, but reading code now I have found no differences in
> the logic on how resources are being iterated in these two pieces of code.
This code is over a decade old (13 years old to be precise) and there was
something odd between Bjorn's and Jesse's patches, as per:
89a74ecccd1f ("PCI: add pci_bus_for_each_resource(), remove direct bus->resource[] refs")
cf26e8dc4194 ("pcmcia: do not autoadd root PCI bus resources")
> But fine, I will add a line to a commit message about this change.
I wouldn't, personally. The change you are proposing is self-explanatory
and somewhat in-line with what is there already - unless I am also reading
the current implementation wrong.
That said, Dominik is the maintainer of PCMCIA driver, so his is the last
word, so to speak. :)
> Considering this is done, can you issue your conditional tag so I will
> incorporate it in v3?
No need, really. Again, unless Dominik thinks otherwise.
Krzysztof
WARNING: multiple messages have this Message-ID (diff)
From: "Krzysztof Wilczyński" <kw@linux.com>
To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: linux-pci@vger.kernel.org,
"Dominik Brodowski" <linux@dominikbrodowski.net>,
linux-mips@vger.kernel.org, "Bjorn Helgaas" <bhelgaas@google.com>,
sparclinux@vger.kernel.org,
"Stefano Stabellini" <sstabellini@kernel.org>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
"Russell King" <linux@armlinux.org.uk>,
"Bjorn Helgaas" <helgaas@kernel.org>,
"Miguel Ojeda" <ojeda@kernel.org>,
xen-devel@lists.xenproject.org,
"Matt Turner" <mattst88@gmail.com>,
"Arnd Bergmann" <arnd@arndb.de>,
"Richard Henderson" <richard.henderson@linaro.org>,
"Nicholas Piggin" <npiggin@gmail.com>,
"Ivan Kokshaysky" <ink@jurassic.park.msu.ru>,
"Mickaël Salaün" <mic@digikod.net>,
"Mika Westerberg" <mika.westerberg@linux.intel.com>,
linux-arm-kernel@lists.infradead.org,
"Juergen Gross" <jgross@suse.com>,
"Thomas Bogendoerfer" <tsbogend@alpha.franken.de>,
linux-kernel@vger.kernel.org,
"Oleksandr Tyshchenko" <oleksandr_tyshchenko@epam.com>,
linux-alpha@vger.kernel.org, linuxppc-dev@lists.ozlabs.org,
"David S. Miller" <davem@davemloft.net>
Subject: Re: [PATCH v2 4/4] pcmcia: Convert to use pci_bus_for_each_resource_p()
Date: Fri, 4 Nov 2022 03:29:44 +0900 [thread overview]
Message-ID: <Y2QImB0OLakzz1+F@rocinante> (raw)
In-Reply-To: <Y2P2ja26ikNecTsv@smile.fi.intel.com>
Hello,
[...]
> > > -
> > > - for (i = 0; i < PCI_BRIDGE_RESOURCE_NUM; i++) {
> > > - res = s->cb_dev->bus->resource[i];
> > > -#else
> > > - pci_bus_for_each_resource(s->cb_dev->bus, res, i) {
> > > #endif
> > > +
> > > + pci_bus_for_each_resource_p(s->cb_dev->bus, res) {
> > > if (!res)
> > > continue;
> >
> > Doesn't this remove the proper iterator for X86? Even if that is the right
> > thing to do, it needs an explict explanation.
>
> I dunno what was in 2010, but reading code now I have found no differences in
> the logic on how resources are being iterated in these two pieces of code.
This code is over a decade old (13 years old to be precise) and there was
something odd between Bjorn's and Jesse's patches, as per:
89a74ecccd1f ("PCI: add pci_bus_for_each_resource(), remove direct bus->resource[] refs")
cf26e8dc4194 ("pcmcia: do not autoadd root PCI bus resources")
> But fine, I will add a line to a commit message about this change.
I wouldn't, personally. The change you are proposing is self-explanatory
and somewhat in-line with what is there already - unless I am also reading
the current implementation wrong.
That said, Dominik is the maintainer of PCMCIA driver, so his is the last
word, so to speak. :)
> Considering this is done, can you issue your conditional tag so I will
> incorporate it in v3?
No need, really. Again, unless Dominik thinks otherwise.
Krzysztof
WARNING: multiple messages have this Message-ID (diff)
From: "Krzysztof Wilczyński" <kw@linux.com>
To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: "Dominik Brodowski" <linux@dominikbrodowski.net>,
"Mickaël Salaün" <mic@digikod.net>,
"Mika Westerberg" <mika.westerberg@linux.intel.com>,
"Michael Ellerman" <mpe@ellerman.id.au>,
"Arnd Bergmann" <arnd@arndb.de>,
"Bjorn Helgaas" <helgaas@kernel.org>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
"Juergen Gross" <jgross@suse.com>,
linux-kernel@vger.kernel.org, linux-alpha@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, linux-mips@vger.kernel.org,
linuxppc-dev@lists.ozlabs.org, sparclinux@vger.kernel.org,
linux-pci@vger.kernel.org, xen-devel@lists.xenproject.org,
"Miguel Ojeda" <ojeda@kernel.org>,
"Richard Henderson" <richard.henderson@linaro.org>,
"Ivan Kokshaysky" <ink@jurassic.park.msu.ru>,
"Matt Turner" <mattst88@gmail.com>,
"Russell King" <linux@armlinux.org.uk>,
"Thomas Bogendoerfer" <tsbogend@alpha.franken.de>,
"Nicholas Piggin" <npiggin@gmail.com>,
"Christophe Leroy" <christophe.leroy@csgroup.eu>,
"David S. Miller" <davem@davemloft.net>,
"Bjorn Helgaas" <bhelgaas@google.com>,
"Stefano Stabellini" <sstabellini@kernel.org>,
"Oleksandr Tyshchenko" <oleksandr_tyshchenko@epam.com>
Subject: Re: [PATCH v2 4/4] pcmcia: Convert to use pci_bus_for_each_resource_p()
Date: Fri, 4 Nov 2022 03:29:44 +0900 [thread overview]
Message-ID: <Y2QImB0OLakzz1+F@rocinante> (raw)
In-Reply-To: <Y2P2ja26ikNecTsv@smile.fi.intel.com>
Hello,
[...]
> > > -
> > > - for (i = 0; i < PCI_BRIDGE_RESOURCE_NUM; i++) {
> > > - res = s->cb_dev->bus->resource[i];
> > > -#else
> > > - pci_bus_for_each_resource(s->cb_dev->bus, res, i) {
> > > #endif
> > > +
> > > + pci_bus_for_each_resource_p(s->cb_dev->bus, res) {
> > > if (!res)
> > > continue;
> >
> > Doesn't this remove the proper iterator for X86? Even if that is the right
> > thing to do, it needs an explict explanation.
>
> I dunno what was in 2010, but reading code now I have found no differences in
> the logic on how resources are being iterated in these two pieces of code.
This code is over a decade old (13 years old to be precise) and there was
something odd between Bjorn's and Jesse's patches, as per:
89a74ecccd1f ("PCI: add pci_bus_for_each_resource(), remove direct bus->resource[] refs")
cf26e8dc4194 ("pcmcia: do not autoadd root PCI bus resources")
> But fine, I will add a line to a commit message about this change.
I wouldn't, personally. The change you are proposing is self-explanatory
and somewhat in-line with what is there already - unless I am also reading
the current implementation wrong.
That said, Dominik is the maintainer of PCMCIA driver, so his is the last
word, so to speak. :)
> Considering this is done, can you issue your conditional tag so I will
> incorporate it in v3?
No need, really. Again, unless Dominik thinks otherwise.
Krzysztof
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2022-11-03 18:29 UTC|newest]
Thread overview: 47+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-03 16:46 [PATCH v2 0/4] PCI: Add pci_dev_for_each_resource() helper and refactor bus one Andy Shevchenko
2022-11-03 16:46 ` Andy Shevchenko
2022-11-03 16:46 ` Andy Shevchenko
2022-11-03 16:46 ` [PATCH v2 1/4] PCI: Introduce pci_dev_for_each_resource() Andy Shevchenko
2022-11-03 16:46 ` Andy Shevchenko
2022-11-03 16:46 ` Andy Shevchenko
2022-11-03 16:46 ` [PATCH v2 2/4] PCI: Split pci_bus_for_each_resource_p() out of pci_bus_for_each_resource() Andy Shevchenko
2022-11-03 16:46 ` Andy Shevchenko
2022-11-03 16:46 ` Andy Shevchenko
2022-11-03 16:46 ` [PATCH v2 3/4] EISA: Convert to use pci_bus_for_each_resource_p() Andy Shevchenko
2022-11-03 16:46 ` Andy Shevchenko
2022-11-03 16:46 ` Andy Shevchenko
2022-11-03 16:46 ` [PATCH v2 4/4] pcmcia: " Andy Shevchenko
2022-11-03 16:46 ` Andy Shevchenko
2022-11-03 16:46 ` Andy Shevchenko
2022-11-03 17:03 ` Dominik Brodowski
2022-11-03 17:03 ` Dominik Brodowski
2022-11-03 17:03 ` Dominik Brodowski
2022-11-03 17:03 ` Dominik Brodowski
2022-11-03 17:12 ` Andy Shevchenko
2022-11-03 17:12 ` Andy Shevchenko
2022-11-03 17:12 ` Andy Shevchenko
2022-11-03 17:12 ` Andy Shevchenko
2022-11-03 17:25 ` Dominik Brodowski
2022-11-03 17:25 ` Dominik Brodowski
2022-11-03 17:25 ` Dominik Brodowski
2022-11-03 17:25 ` Dominik Brodowski
2022-11-03 18:01 ` Andy Shevchenko
2022-11-03 18:01 ` Andy Shevchenko
2022-11-03 18:01 ` Andy Shevchenko
2022-11-03 18:01 ` Andy Shevchenko
2022-11-03 18:29 ` Krzysztof Wilczyński [this message]
2022-11-03 18:29 ` Krzysztof Wilczyński
2022-11-03 18:29 ` Krzysztof Wilczyński
2022-11-03 18:29 ` Krzysztof Wilczyński
2022-11-03 18:38 ` Dominik Brodowski
2022-11-03 18:38 ` Dominik Brodowski
2022-11-03 18:38 ` Dominik Brodowski
2022-11-03 18:38 ` Dominik Brodowski
2022-11-03 19:01 ` Andy Shevchenko
2022-11-03 19:01 ` Andy Shevchenko
2022-11-03 19:01 ` Andy Shevchenko
2022-11-03 19:01 ` Andy Shevchenko
2022-11-03 18:59 ` Andy Shevchenko
2022-11-03 18:59 ` Andy Shevchenko
2022-11-03 18:59 ` Andy Shevchenko
2022-11-03 18:59 ` Andy Shevchenko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Y2QImB0OLakzz1+F@rocinante \
--to=kw@linux.com \
--cc=andriy.shevchenko@linux.intel.com \
--cc=arnd@arndb.de \
--cc=bhelgaas@google.com \
--cc=helgaas@kernel.org \
--cc=ink@jurassic.park.msu.ru \
--cc=jgross@suse.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mips@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=linux@dominikbrodowski.net \
--cc=mattst88@gmail.com \
--cc=mic@digikod.net \
--cc=mika.westerberg@linux.intel.com \
--cc=npiggin@gmail.com \
--cc=ojeda@kernel.org \
--cc=rafael.j.wysocki@intel.com \
--cc=richard.henderson@linaro.org \
--cc=sparclinux@vger.kernel.org \
--cc=sstabellini@kernel.org \
--cc=tsbogend@alpha.franken.de \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.