[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210928200811.GA724823@bhelgaas>
Date: Tue, 28 Sep 2021 15:08:11 -0500
From: Bjorn Helgaas <helgaas@...nel.org>
To: Uwe Kleine-König
<u.kleine-koenig@...gutronix.de>
Cc: Uwe Kleine-König <uwe@...ine-koenig.org>,
Oliver O'Halloran <oohall@...il.com>,
Russell Currey <ruscur@...sell.cc>,
Benjamin Herrenschmidt <benh@...nel.crashing.org>,
linux-pci@...r.kernel.org, Alexander Duyck <alexanderduyck@...com>,
oss-drivers@...igine.com, Paul Mackerras <paulus@...ba.org>,
Herbert Xu <herbert@...dor.apana.org.au>,
Michael Ellerman <mpe@...erman.id.au>,
Rafał Miłecki <zajec5@...il.com>,
Jesse Brandeburg <jesse.brandeburg@...el.com>,
Ido Schimmel <idosch@...dia.com>,
Jakub Kicinski <kuba@...nel.org>,
Yisen Zhuang <yisen.zhuang@...wei.com>,
Vadym Kochan <vkochan@...vell.com>, Michael Buesch <m@...s.ch>,
Jiri Pirko <jiri@...dia.com>,
Salil Mehta <salil.mehta@...wei.com>, netdev@...r.kernel.org,
linux-wireless@...r.kernel.org, linux-kernel@...r.kernel.org,
Taras Chornyi <tchornyi@...vell.com>,
Zhou Wang <wangzhou1@...ilicon.com>,
linux-crypto@...r.kernel.org, kernel@...gutronix.de,
Simon Horman <simon.horman@...igine.com>,
linuxppc-dev@...ts.ozlabs.org,
"David S. Miller" <davem@...emloft.net>
Subject: Re: [PATCH v4 4/8] PCI: replace pci_dev::driver usage that gets the
driver name
On Tue, Sep 28, 2021 at 09:29:36PM +0200, Uwe Kleine-König wrote:
> On Tue, Sep 28, 2021 at 12:17:59PM -0500, Bjorn Helgaas wrote:
> > [+to Oliver, Russell for eeh_driver_name() question below]
> >
> > On Mon, Sep 27, 2021 at 10:43:22PM +0200, Uwe Kleine-König wrote:
> > > From: Uwe Kleine-König <u.kleine-koenig@...gutronix.de>
> > >
> > > struct pci_dev::driver holds (apart from a constant offset) the same
> > > data as struct pci_dev::dev->driver. With the goal to remove struct
> > > pci_dev::driver to get rid of data duplication replace getting the
> > > driver name by dev_driver_string() which implicitly makes use of struct
> > > pci_dev::dev->driver.
> > Also, would you mind using "pci_dev.driver" instead of
> > "pci_dev::driver"? AFAIK, the "::" operator is not actually part of
> > C, so I think it's more confusing than useful.
>
> pci_dev.driver doesn't work either in C because pci_dev is a type and
> not a variable.
Sure, "pci_dev.driver" is not strictly acceptable C unless you have a
"struct pci_dev pci_dev", but it's pretty common.
Powered by blists - more mailing lists