[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <d719b331-84ed-4889-9959-0d7dde270804@kernel.org>
Date: Fri, 17 May 2024 11:15:13 +0200
From: Krzysztof Kozlowski <krzk@...nel.org>
To: Johan Hovold <johan@...nel.org>
Cc: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>,
Andy Shevchenko <andy.shevchenko@...il.com>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
Johan Hovold <johan+linaro@...nel.org>, Lee Jones <lee@...nel.org>,
Mark Brown <broonie@...nel.org>, Linus Walleij <linus.walleij@...aro.org>,
Bjorn Andersson <andersson@...nel.org>,
Konrad Dybcio <konrad.dybcio@...aro.org>, Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk+dt@...nel.org>, Conor Dooley
<conor+dt@...nel.org>, Liam Girdwood <lgirdwood@...il.com>,
Das Srinagesh <quic_gurus@...cinc.com>,
Satya Priya <quic_c_skakit@...cinc.com>, Stephen Boyd <swboyd@...omium.org>,
linux-arm-msm@...r.kernel.org, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-gpio@...r.kernel.org
Subject: Re: [PATCH 12/13] regulator: add pm8008 pmic regulator driver
On 09/05/2024 14:26, Johan Hovold wrote:
> On Thu, May 09, 2024 at 12:48:18PM +0200, Krzysztof Kozlowski wrote:
>> On 09/05/2024 10:57, Johan Hovold wrote:
>>> On Tue, May 07, 2024 at 08:14:43PM +0200, Krzysztof Kozlowski wrote:
>>>> On 07/05/2024 19:22, Andy Shevchenko wrote:
>
>>>> Yeah, please use ID table, since this is a driver (unless I missed
>>>> something). Module alias does not scale, leads to stale and duplicated
>>>> entries, so should not be used as substitute of ID table. Alias is
>>>> suitable for different cases.
>>>
>>> There's no scalability issue here. If the driver uses driver name
>>> matching then there will always be exactly one alias needed.
>>
>> And then we add one more ID with driver data and how does it scale?
>
> That's what I wrote in the part of my reply that you left out. If a
> driver is going to be used for multiple devices, then a module id table
> makes sense, but there is no need to go around adding redundant tables
> just for the sake of it when a simple alias will do.
>
I still in general prefer ID tables, because I saw many times people
copy existing code while not understanding above subtleties thus they
just keep multiplying MODULE_ALIAS, but I understand your explanation
and it is reasonable.
FWIW:
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
Best regards,
Krzysztof
Powered by blists - more mailing lists