[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAFSKS=NrdVSDEh5DWN+JOcZ5fycM1y_N5b8cxzZwQxm-hJbVHQ@mail.gmail.com>
Date: Thu, 14 Jan 2021 12:47:46 -0600
From: George McCollister <george.mccollister@...il.com>
To: Vladimir Oltean <olteanv@...il.com>
Cc: Andrew Lunn <andrew@...n.ch>,
Vivien Didelot <vivien.didelot@...il.com>,
Florian Fainelli <f.fainelli@...il.com>,
Rob Herring <robh@...nel.org>,
"David S . Miller" <davem@...emloft.net>, netdev@...r.kernel.org,
"open list:OPEN FIRMWARE AND..." <devicetree@...r.kernel.org>
Subject: Re: [PATCH net-next v4 2/3] net: dsa: add Arrow SpeedChips XRS700x driver
On Thu, Jan 14, 2021 at 12:32 PM Vladimir Oltean <olteanv@...il.com> wrote:
> > > May boil down to preference too, but I don't believe "dev" is a happy
> > > name to give to a driver private data structure.
> >
> > There are other drivers in the subsystem that do this. If there was a
> > consistent pattern followed in the subsystem I would have followed it.
> > Trust me I was a bit frustrated with home much time I spent going
> > through multiple drivers trying to determine the best practices for
> > organization, naming, etc.
> > If it's a big let me know and I'll change it.
>
> Funny that you are complaining about consistency in other drivers,
> because if I count correctly, out of a total of 22 occurrences of
> struct xrs700x variables in yours, 13 are named priv and 9 are named
> dev. So you are not even consistent with yourself. But it's not a major
> issue either way.
Touché. This ended up happening because I followed the pattern used by
different drivers in different places. Specifically ksz was using
regmap to work on multiple buses but wasn't a very clean example for
much else.
I'll just change it to priv everywhere.
Powered by blists - more mailing lists