From: "Rafał Miłecki" <zajec5@gmail.com>
To: Kishon Vijay Abraham I <kishon@ti.com>,
Vinod Koul <vkoul@kernel.org>, Rob Herring <robh+dt@kernel.org>
Cc: linux-kernel@vger.kernel.org, devicetree@vger.kernel.org,
"Florian Fainelli" <f.fainelli@gmail.com>,
"Vivek Unune" <npcomplete13@gmail.com>,
bcm-kernel-feedback-list@broadcom.com,
"Rafał Miłecki" <rafal@milecki.pl>
Subject: [PATCH 2/3] dt-bindings: phy: brcm,ns-usb2-phy: bind single CRU reg
Date: Fri, 26 Feb 2021 12:45:00 +0100 [thread overview]
Message-ID: <20210226114501.31086-2-zajec5@gmail.com> (raw)
In-Reply-To: <20210226114501.31086-1-zajec5@gmail.com>
From: Rafał Miłecki <rafal@milecki.pl>
The old binding was using whole DMU space. It was an overkill. DMU is a
big block which contains e.g. CRU which contains e.g. PLLs, PHY, pinctrl
and thermal blocks.
Rework the binding to directly use a single CRU register that controls
USB 2.0 PHY. It's still required to reference CRU generic clkset
register so add a syscon for that.
For a full DMU & CRU description see arch/arm/boot/dts/bcm5301x.dtsi .
The old binding is deprecated now.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
---
This has been verified using dt_binding_check
I'd really like to get Rob's ack to make sure I don't do anything stupid
It's a reworked version of my abonded 2019 patch:
[PATCH V2 1/2] dt-bindings: bcm-ns-usb2-phy: rework binding to use CRU syscon
https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20190108123907.19816-1-zajec5@gmail.com/
---
.../bindings/phy/brcm,ns-usb2-phy.yaml | 46 +++++++++++++++----
1 file changed, 36 insertions(+), 10 deletions(-)
diff --git a/Documentation/devicetree/bindings/phy/brcm,ns-usb2-phy.yaml b/Documentation/devicetree/bindings/phy/brcm,ns-usb2-phy.yaml
index b8b683ce8fa9..8e056d4d205a 100644
--- a/Documentation/devicetree/bindings/phy/brcm,ns-usb2-phy.yaml
+++ b/Documentation/devicetree/bindings/phy/brcm,ns-usb2-phy.yaml
@@ -16,11 +16,20 @@ properties:
const: brcm,ns-usb2-phy
reg:
- maxItems: 1
- description: DMU (Device Management Unit) address range
+ anyOf:
+ - maxItems: 1
+ description: PHY control register
+ - maxItems: 1
+ description: DMU (Device Management Unit) address range
+ deprecated: true
reg-names:
const: dmu
+ deprecated: true
+
+ brcm,syscon-clkset:
+ description: phandle to syscon for clkset register
+ $ref: /schemas/types.yaml#/definitions/phandle
clocks:
maxItems: 1
@@ -34,22 +43,39 @@ properties:
required:
- reg
- - reg-names
- clocks
- clock-names
- "#phy-cells"
+oneOf:
+ - required:
+ - brcm,syscon-clkset
+ - required:
+ - reg-names
+
additionalProperties: false
examples:
- |
#include <dt-bindings/clock/bcm-nsp.h>
- usb2-phy@1800c000 {
- compatible = "brcm,ns-usb2-phy";
- reg = <0x1800c000 0x1000>;
- reg-names = "dmu";
- clocks = <&genpll BCM_NSP_GENPLL_USB_PHY_REF_CLK>;
- clock-names = "phy-ref-clk";
- #phy-cells = <0>;
+ cru-bus@1800c100 {
+ compatible = "simple-bus";
+ ranges = <0 0x1800c100 0x1a4>;
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ usb2-phy@64 {
+ compatible = "brcm,ns-usb2-phy";
+ reg = <0x64 0x4>;
+ brcm,syscon-clkset = <&clkset>;
+ clocks = <&genpll BCM_NSP_GENPLL_USB_PHY_REF_CLK>;
+ clock-names = "phy-ref-clk";
+ #phy-cells = <0>;
+ };
+
+ clkset: syscon@80 {
+ compatible = "brcm,cru-clkset", "syscon";
+ reg = <0x80 0x4>;
+ };
};
--
2.26.2
next prev parent reply other threads:[~2021-02-26 11:46 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-26 11:44 [PATCH 1/3] dt-bindings: phy: convert Broadcom NS USB 2.0 to the json-schema Rafał Miłecki
2021-02-26 11:45 ` Rafał Miłecki [this message]
2021-03-05 17:24 ` [PATCH 2/3] dt-bindings: phy: brcm,ns-usb2-phy: bind single CRU reg Rafał Miłecki
2021-03-05 17:24 ` Rafał Miłecki
2021-03-05 21:50 ` Rafał Miłecki
2021-03-05 21:50 ` Rafał Miłecki
2021-03-06 21:52 ` Rob Herring
2021-03-09 14:50 ` Rafał Miłecki
2021-02-26 11:45 ` [PATCH 3/3] phy: bcm-ns-usb2: support updated single CRU reg DT binding Rafał Miłecki
2021-03-05 17:25 ` Rafał Miłecki
2021-03-05 17:25 ` Rafał Miłecki
2021-03-05 21:50 ` Rafał Miłecki
2021-03-05 21:50 ` Rafał Miłecki
2021-03-05 17:24 ` [PATCH 1/3] dt-bindings: phy: convert Broadcom NS USB 2.0 to the json-schema Rafał Miłecki
2021-03-05 17:24 ` Rafał Miłecki
2021-03-05 21:48 ` Rafał Miłecki
2021-03-05 21:48 ` Rafał Miłecki
2021-03-06 21:25 ` Rob Herring
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=20210226114501.31086-2-zajec5@gmail.com \
--to=zajec5@gmail.com \
--cc=bcm-kernel-feedback-list@broadcom.com \
--cc=devicetree@vger.kernel.org \
--cc=f.fainelli@gmail.com \
--cc=kishon@ti.com \
--cc=linux-kernel@vger.kernel.org \
--cc=npcomplete13@gmail.com \
--cc=rafal@milecki.pl \
--cc=robh+dt@kernel.org \
--cc=vkoul@kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.