From: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
To: Daniel Golle <daniel@makrotopia.org>
Cc: AngeloGioacchino Del Regno
<angelogioacchino.delregno@collabora.com>,
Wim Van Sebroeck <wim@linux-watchdog.org>,
Guenter Roeck <linux@roeck-us.net>,
Rob Herring <robh+dt@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
Conor Dooley <conor+dt@kernel.org>,
Matthias Brugger <matthias.bgg@gmail.com>,
Philipp Zabel <p.zabel@pengutronix.de>,
linux-watchdog@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-mediatek@lists.infradead.org
Subject: Re: [PATCH 1/2] dt-bindings: watchdog: mediatek,mtk-wdt: add MT7988 watchdog and toprgu
Date: Fri, 10 Nov 2023 16:15:04 +0100 [thread overview]
Message-ID: <6576d4a6-31fa-4780-9a8a-5a1d1974836f@linaro.org> (raw)
In-Reply-To: <ZU5IcrjqQpwMopJC@makrotopia.org>
On 10/11/2023 16:12, Daniel Golle wrote:
>>>>>>>>> diff --git a/include/dt-bindings/reset/mediatek,mt7988-resets.h b/include/dt-bindings/reset/mediatek,mt7988-resets.h
>>>>>>>>> new file mode 100644
>>>>>>>>> index 0000000000000..fa7c937505e08
>>>>>>>>> --- /dev/null
>>>>>>>>> +++ b/include/dt-bindings/reset/mediatek,mt7988-resets.h
>>>>>>>>> @@ -0,0 +1,12 @@
>>>>>>>>> +/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) */
>>>>>>>>> +
>>>>>>>>> +/* TOPRGU resets */
>>>>>>>>
>>>>>>>> The first reset is zero, the second reset is one.
>>>>>>>>
>>>>>>>> Where's the zero'th reset? :-)
>>>>>>>
>>>>>>> Currently the reset numbers represent the corresponding bit positions in
>>>>>>> the toprgu register, as this is how the mtk-wdt driver is organized.
>>>>>>>
>>>>>>> So there is probably something at bit 0, and also at bit 3~11 and
>>>>>>> maybe also 17~23, but it's unknown and may be added later once known
>>>>>>> and/or needed.
>>>>>>
>>>>>> There is no need to put register bits, which are not used by the driver,
>>>>>> in the bindings.
>>>>>
>>>>> There aren't. That's why there isn't a zero'th reset (and also not 3~11, 17~24).
>>>>>
>>>>> Or should the driver be reorganized to provide a mapping of logical to
>>>>> physical resets, and then have only the needed once present and start
>>>>> counting logical resets from 0? This is doable, of course, but it's a
>>>>> bit of effort just for the aesthetical goal of starting to count from
>>>>> zero and continous in header file.
>>>>>
>>>>> And, of course, chances are that other currently still unused bits
>>>>> will be needed at a later point which then would mean having to add
>>>>> them in at least 2 places (header file and mapping logical<->physical)
>>>>> where as currently it would just mean adding a line defining it in the
>>>>> header file.
>>>>
>>>> You can do it, but it's not what I wrote here. So bear with me:
>>>>
>>>> "There is no need to put register bits in the bindings."
>>
>> No comments here, so I assume you agree with this.
Here is the answer to...
>>
>>>>
>>>> You replied "There aren't", which I don't understand in this context. I
>>>> can be clearer:
>>>> Drop this hunk.
>>>
>>> So adding the file to include/dt-bindings/reset/ should go into a
>>> seperate patch? Because including it with the driver itself gave me
>>> a checkpath warning telling me that dt-bindings should go seperate,
>>> which is why I included it with the binding docs.
>>
>> No, I said the hunk should be dropped. Removed.
>
> I guess we are somehow misunderstanding each other.
> Lets go with an example. I can put the header into a commit of its own,
> just like commit
> 5794dda109fc8 dt-bindings: reset: mt7986: Add reset-controller header file
> https://lore.kernel.org/r/20220105100456.7126-2-sam.shih@mediatek.com
>
> Would that be acceptable? And if not, why?
...this question.
Again, whether this is separate patch - it is still hunk which I think
should be removed. I gave the reason "why" in this mail thread and in
multiple other discussions.
Best regards,
Krzysztof
next prev parent reply other threads:[~2023-11-10 15:15 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-10 0:30 [PATCH 1/2] dt-bindings: watchdog: mediatek,mtk-wdt: add MT7988 watchdog and toprgu Daniel Golle
2023-11-10 0:30 ` [PATCH 2/2] watchdog: mediatek: mt7988: add wdt support Daniel Golle
2023-11-10 5:24 ` Guenter Roeck
2023-11-10 11:55 ` AngeloGioacchino Del Regno
2023-11-10 15:13 ` Guenter Roeck
2023-11-10 8:09 ` [PATCH 1/2] dt-bindings: watchdog: mediatek,mtk-wdt: add MT7988 watchdog and toprgu Krzysztof Kozlowski
2023-11-10 15:20 ` Krzysztof Kozlowski
2023-11-10 20:00 ` Krzysztof Kozlowski
2023-11-10 20:45 ` Daniel Golle
2023-11-11 7:55 ` Krzysztof Kozlowski
2023-11-10 11:56 ` AngeloGioacchino Del Regno
2023-11-10 14:17 ` Daniel Golle
2023-11-10 14:20 ` Krzysztof Kozlowski
2023-11-10 14:40 ` Daniel Golle
2023-11-10 14:46 ` Krzysztof Kozlowski
2023-11-10 14:51 ` Daniel Golle
2023-11-10 15:07 ` Krzysztof Kozlowski
2023-11-10 15:12 ` Daniel Golle
2023-11-10 15:15 ` Krzysztof Kozlowski [this message]
2023-11-10 15:21 ` Krzysztof Kozlowski
2023-11-10 17:07 ` Daniel Golle
2023-11-10 19:58 ` Krzysztof Kozlowski
2023-11-10 20:18 ` Daniel Golle
2023-11-10 20:21 ` Krzysztof Kozlowski
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=6576d4a6-31fa-4780-9a8a-5a1d1974836f@linaro.org \
--to=krzysztof.kozlowski@linaro.org \
--cc=angelogioacchino.delregno@collabora.com \
--cc=conor+dt@kernel.org \
--cc=daniel@makrotopia.org \
--cc=devicetree@vger.kernel.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux-watchdog@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=matthias.bgg@gmail.com \
--cc=p.zabel@pengutronix.de \
--cc=robh+dt@kernel.org \
--cc=wim@linux-watchdog.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).