From patchwork Fri Dec 20 11:05:35 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kever Yang X-Patchwork-Id: 13916579 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id DD334E7718D for ; Fri, 20 Dec 2024 11:14:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=qb0CcfxkRDNXcy5MLyQZJMQC+rGD5SHalPGr3CXNm/I=; b=QtdbRWR5GzsD66 1Wd+KM0kIk1kzRrRhQu7vCO0yyTaUuhxHDqNMJe6lAfst3Q9KhiJC3B4I+N8tM+V7e9WKxi2QNf0Q Ucexd0j8gC1AxmIpciOpCC/+0yZpanzUCHIr2UWRKthjFsr1JmXZiH2xzZPE4GHok614UHHrWKWxk XSLJfjmokHEyw6DzT7gDoK2kru3lD+J9C7Si53euuScIX3kbl7KqRrkQgXpguPOhm1ZSFyrkD8uGn wOVUq2KvK/0aK9NAJc9ANM8fRliTUGMlNcOf1nskvOluEpSRgJz0deEBH5bn+E8vEAZXcgYbqsDEy rpQ0hVCKyVC17m37TG5Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1tOay5-00000004jBb-1WML; Fri, 20 Dec 2024 11:14:53 +0000 Received: from mail-m15580.qiye.163.com ([101.71.155.80]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1tOaph-00000004fDS-2j4C for linux-rockchip@lists.infradead.org; Fri, 20 Dec 2024 11:06:14 +0000 Received: from localhost.localdomain (unknown [58.22.7.114]) by smtp.qiye.163.com (Hmail) with ESMTP id 657291e4; Fri, 20 Dec 2024 19:06:10 +0800 (GMT+08:00) From: Kever Yang To: heiko@sntech.de Cc: linux-rockchip@lists.infradead.org, Kever Yang Subject: [PATCH 15/38] dt-bindings: nvmem: rockchip,otp: Add support for rk3562 and rk3568 Date: Fri, 20 Dec 2024 19:05:35 +0800 Message-Id: <20241220110558.3511994-6-kever.yang@rock-chips.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20241220110558.3511994-1-kever.yang@rock-chips.com> References: <20241220103825.3509421-1-kever.yang@rock-chips.com> <20241220110558.3511994-1-kever.yang@rock-chips.com> MIME-Version: 1.0 X-HM-Spam-Status: e1kfGhgUHx5ZQUpXWQgPGg8OCBgUHx5ZQUlOS1dZFg8aDwILHllBWSg2Ly tZV1koWUFDSUNOT01LS0k3V1ktWUFJV1kPCRoVCBIfWUFZQk9JTVZJTx5JGhpLT0NISBlWFRQJFh oXVRMBExYaEhckFA4PWVdZGBILWUFZTkNVSUlVTFVKSk9ZV1kWGg8SFR0UWUFZT0tIVUpLSU9PT0 hVSktLVUpCS0tZBg++ X-HM-Tid: 0a93e3bf13a903afkunm657291e4 X-HM-MType: 1 X-HM-Sender-Digest: e1kMHhlZQR0aFwgeV1kSHx4VD1lBWUc6NAw6CSo6ITIKPghLNks1SBca Fj0aCRdVSlVKTEhPTUJJTExKT01JVTMWGhIXVRAeDR4JVQIaFRw7CRQYEFYYExILCFUYFBZFWVdZ EgtZQVlOQ1VJSVVMVUpKT1lXWQgBWUFJT0hDNwY+ DKIM-Signature: a=rsa-sha256; b=SEwMEvSjTDU+TtfkQW95ez0h7PUsXzqmds94iZDg/r+GsbTNmbY9lALhPHQ97mQc+qQjVZYPgvOZvED+OMhiCYqigSh+QO1dFerJ6rWPZY8AvyF9yk1ySp+MU+4z4uoRp8k9zJq8+pjKx8KfsBNodFI0d7XDmEeeYebxKBDib7s=; s=default; c=relaxed/relaxed; d=rock-chips.com; v=1; bh=zG8fo9UPdwDqsNEMp4SUheJp0t9EsDHamrlelso9VNk=; h=date:mime-version:subject:message-id:from; X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241220_030613_887360_E8EACFCF X-CRM114-Status: UNSURE ( 5.31 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org rk3562 and rk3568 has similar clocks which different than other SoCs. Signed-off-by: Kever Yang --- .../bindings/nvmem/rockchip,otp.yaml | 49 ++++++++++++++++--- 1 file changed, 42 insertions(+), 7 deletions(-) diff --git a/Documentation/devicetree/bindings/nvmem/rockchip,otp.yaml b/Documentation/devicetree/bindings/nvmem/rockchip,otp.yaml index a44d44b32809..33d2905f6c16 100644 --- a/Documentation/devicetree/bindings/nvmem/rockchip,otp.yaml +++ b/Documentation/devicetree/bindings/nvmem/rockchip,otp.yaml @@ -14,6 +14,8 @@ properties: enum: - rockchip,px30-otp - rockchip,rk3308-otp + - rockchip,rk3562-otp + - rockchip,rk3568-otp - rockchip,rk3588-otp reg: @@ -25,19 +27,15 @@ properties: clock-names: minItems: 3 - items: - - const: otp - - const: apb_pclk - - const: phy - - const: arb + maxItems: 4 resets: minItems: 1 - maxItems: 3 + maxItems: 4 reset-names: minItems: 1 - maxItems: 3 + maxItems: 4 required: - compatible @@ -62,12 +60,43 @@ allOf: properties: clocks: maxItems: 3 + clock-names: + items: + - const: otp + - const: apb_pclk + - const: phy resets: maxItems: 1 reset-names: items: - const: phy + - if: + properties: + compatible: + contains: + enum: + - rockchip,rk3562-otp + - rockchip,rk3568-otp + then: + properties: + clocks: + minItems: 4 + clock-names: + items: + - const: usr + - const: sbpi + - const: apb_pclk + - const: phy + resets: + minItems: 4 + reset-names: + items: + - const: usr + - const: sbpi + - const: apb + - const: phy + - if: properties: compatible: @@ -78,6 +107,12 @@ allOf: properties: clocks: minItems: 4 + clock-names: + items: + - const: otp + - const: apb_pclk + - const: phy + - const: arb resets: minItems: 3 reset-names: