From: Krzysztof Kozlowski <krzk@kernel.org>
To: Haylen Chu <heylenay@4d2.org>
Cc: Michael Turquette <mturquette@baylibre.com>,
Stephen Boyd <sboyd@kernel.org>, Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Haylen Chu <heylenay@outlook.com>, Yixun Lan <dlan@gentoo.org>,
linux-riscv@lists.infradead.org, linux-clk@vger.kernel.org,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
Inochi Amaoto <inochiama@outlook.com>,
Chen Wang <unicornxdotw@foxmail.com>,
Jisheng Zhang <jszhang@kernel.org>,
Meng Zhang <zhangmeng.kevin@linux.spacemit.com>
Subject: Re: [PATCH v4 2/4] dt-bindings: soc: spacemit: Add spacemit,k1-syscon
Date: Tue, 11 Feb 2025 09:03:20 +0100 [thread overview]
Message-ID: <19e5129b-8423-4660-8e4f-8b898214d275@kernel.org> (raw)
In-Reply-To: <Z6rdBhQ7s2ReOgBL@ketchup>
On 11/02/2025 06:15, Haylen Chu wrote:
> On Sat, Jan 04, 2025 at 11:07:58AM +0100, Krzysztof Kozlowski wrote:
>> On Fri, Jan 03, 2025 at 09:56:35PM +0000, Haylen Chu wrote:
>>> Add documentation to describe Spacemit K1 system controller registers.
>>>
>>> Signed-off-by: Haylen Chu <heylenay@4d2.org>
>>> ---
>>> .../soc/spacemit/spacemit,k1-syscon.yaml | 52 +++++++++++++++++++
>>> 1 file changed, 52 insertions(+)
>>> create mode 100644 Documentation/devicetree/bindings/soc/spacemit/spacemit,k1-syscon.yaml
>>>
>>> diff --git a/Documentation/devicetree/bindings/soc/spacemit/spacemit,k1-syscon.yaml b/Documentation/devicetree/bindings/soc/spacemit/spacemit,k1-syscon.yaml
>>> new file mode 100644
>>> index 000000000000..79c4a74ff30e
>>> --- /dev/null
>>> +++ b/Documentation/devicetree/bindings/soc/spacemit/spacemit,k1-syscon.yaml
>>> @@ -0,0 +1,52 @@
>>> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
>>> +%YAML 1.2
>>> +---
>>> +$id: http://devicetree.org/schemas/soc/spacemit/spacemit,k1-syscon.yaml#
>>> +$schema: http://devicetree.org/meta-schemas/core.yaml#
>>> +
>>> +title: Spacemit K1 SoC System Controller
>>> +
>>> +maintainers:
>>> + - Haylen Chu <heylenay@4d2.org>
>>> +
>>> +description:
>>> + The Spacemit K1 SoC system controller provides access to shared register files
>>> + for related SoC modules, such as clock controller and reset controller.
>>> +
>>> +properties:
>>> + compatible:
>>> + items:
>>> + - enum:
>>> + - spacemit,k1-apbc-syscon
>>> + - spacemit,k1-apbs-syscon
>>> + - spacemit,k1-apmu-syscon
>>> + - spacemit,k1-mpmu-syscon
>>> + - const: syscon
>>> + - const: simple-mfd
>>> +
>>> + reg:
>>> + maxItems: 1
>>> +
>>> + clock-controller:
>>> + $ref: /schemas/clock/spacemit,k1-ccu.yaml#
>>> + type: object
>>
>> So now we see the full picture and it leads to questions.
>>
>> 1. Why spacemit,k1-apbc-syscon with spacemit,k1-ccu-apmu child is a
>> correct combination?
>>
>> 2. Why having this split in the first place? Please confirm that clock
>> controller is really, really a separate device and its child in
>> datasheet. IOW, fake child for your Linux is a no-go. Fake child while
>> devices are independent is another no-go.
>
> These syscons are introduced because the clock controllers share
> registers with reset controllers. Folding them into the parents results
So a fake split...
> in devicetree nodes act as both reset and clock controllers, like what
Which is correct hardware representation, isn't it?
> has been done for Rockchip SoCs. Such folding isn't practical for the
> MPMU region either, since watchdog and other misc bits (e.g. PLL lock
> status) locates in it.
Hm? Why? You have a device which is reset and clock controller, so why
one device node is not practical? Other vendors do not have problem with
this.
>
> If you're more comfortable with reset and clock controllers folded
> together and eliminating most of these syscons, I'm willing to make the
> change.
This is expected.
Best regards,
Krzysztof
next prev parent reply other threads:[~2025-02-11 8:03 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-03 21:56 [PATCH v4 0/4] Add clock controller support for SpacemiT K1 Haylen Chu
2025-01-03 21:56 ` [PATCH v4 1/4] dt-bindings: clock: spacemit: Add clock controllers of Spacemit K1 SoC Haylen Chu
2025-01-04 9:58 ` Krzysztof Kozlowski
2025-01-15 7:29 ` Haylen Chu
2025-01-03 21:56 ` [PATCH v4 2/4] dt-bindings: soc: spacemit: Add spacemit,k1-syscon Haylen Chu
2025-01-04 10:07 ` Krzysztof Kozlowski
2025-02-11 5:15 ` Haylen Chu
2025-02-11 8:03 ` Krzysztof Kozlowski [this message]
2025-02-13 11:14 ` Haylen Chu
2025-02-13 18:07 ` Krzysztof Kozlowski
2025-02-15 8:41 ` Haylen Chu
2025-02-21 23:40 ` Alex Elder
2025-02-22 9:59 ` Krzysztof Kozlowski
2025-02-22 10:48 ` Haylen Chu
2025-02-22 11:50 ` Krzysztof Kozlowski
2025-02-24 10:17 ` Haylen Chu
2025-02-25 8:12 ` Krzysztof Kozlowski
2025-02-25 21:14 ` Alex Elder
2025-02-22 9:52 ` Krzysztof Kozlowski
2025-02-22 11:36 ` Haylen Chu
2025-01-03 21:56 ` [PATCH v4 3/4] clk: spacemit: Add clock support for Spacemit K1 SoC Haylen Chu
2025-01-16 5:25 ` Samuel Holland
2025-01-21 17:01 ` Haylen Chu
2025-02-14 4:04 ` Alex Elder
2025-02-16 11:34 ` Haylen Chu
2025-02-21 21:10 ` Alex Elder
2025-02-22 9:57 ` Haylen Chu
2025-02-22 9:40 ` Haylen Chu
2025-03-03 9:41 ` Haylen Chu
2025-03-03 14:10 ` Alex Elder
2025-01-03 21:56 ` [PATCH v4 4/4] riscv: dts: spacemit: Add clock controller for K1 Haylen Chu
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=19e5129b-8423-4660-8e4f-8b898214d275@kernel.org \
--to=krzk@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dlan@gentoo.org \
--cc=heylenay@4d2.org \
--cc=heylenay@outlook.com \
--cc=inochiama@outlook.com \
--cc=jszhang@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-clk@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=mturquette@baylibre.com \
--cc=robh@kernel.org \
--cc=sboyd@kernel.org \
--cc=unicornxdotw@foxmail.com \
--cc=zhangmeng.kevin@linux.spacemit.com \
/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
all inboxes | Powered by JetHome®