[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <190100e7-8a59-4cf3-8434-bcb6292cacb2@linaro.org>
Date: Tue, 20 May 2025 10:02:32 +0200
From: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To: Johan Hovold <johan@...nel.org>
Cc: Bryan O'Donoghue <bryan.odonoghue@...aro.org>,
Robert Foss <rfoss@...nel.org>, Todor Tomov <todor.too@...il.com>,
Mauro Carvalho Chehab <mchehab@...nel.org>, linux-media@...r.kernel.org,
linux-arm-msm@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/3] media: qcom: camss: vfe: Stop spamming logs with
version
On 20/05/2025 09:53, Johan Hovold wrote:
> On Tue, May 20, 2025 at 08:06:22AM +0200, Krzysztof Kozlowski wrote:
>> On 30/04/2025 10:33, Krzysztof Kozlowski wrote:
>>> On 30/04/2025 10:30, Bryan O'Donoghue wrote:
>>>> On 30/04/2025 09:19, Krzysztof Kozlowski wrote:
>>>>> If anyone wants to know it and cannot deduce from compatible, then add
>>>>> debugfs interface.
>>>>
>>>> dev_dbg(); isn't too offensive really IMO but if it really bothers you
>>>> switching to debugfs would be fine.
>>>
>>> Yes, please. Dmesg should be only contain issues or some useful
>>> debugging data. Probe success is not useful. It duplicates sysfs and
>>> tracing. Version of hardware - well, I am sure it duplicates the compatible.
>>
>> To recall: kernel coding style is also clear here:
>> "When drivers are working properly they are quiet,"
>
> That's clear and well known (or should be).
>
>> and kernel debugging guide as well:
>> "In almost all cases the debug statements shouldn't be upstreamed, as a
>> working driver is supposed to be silent."
>
> But this is a very recent addition and questionable when read in
> isolation since debug statements are not printed by default. The
> preceding sentences do qualify this:
>
> Permanent debug statements have to be useful for a developer to
Keyword here: useful ------------------------^^^^^^^^^^
> troubleshoot driver misbehavior. Judging that is a bit more of
> an art than a science...
>
>> So I really do not get why this driver deserved exception. Nevertheless
>> I think we agreed that these logs can go away, thus I just sent a v2
>> with a bit extended commit msg.
>
> Spamming the logs as the driver currently does is clearly broken and
> should be fixed. Keeping a hw version dev_dbg() is generally perfectly
> fine, though.
My main argument, expressed in the commit msg to which no one objected,
is that this debug is 100% useless: deducible from the compatible,
always known upfront, always the same.
Best regards,
Krzysztof
Powered by blists - more mailing lists