Received: by 2002:ab2:6991:0:b0:1f7:f6c3:9cb1 with SMTP id v17csp948200lqo; Wed, 8 May 2024 23:16:50 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUY5s7+YdCERLQjKF+SWbZADy4I2Bco1I8IJGiCqR6anQoZpiHLZFq2iZY9L+QQzkwIhpUc4fDuyyC5BkMJWwzg9ckGBvHbKO8jYICd1Q== X-Google-Smtp-Source: AGHT+IHCmtHdcLfwqvIoJw3qGf+Me77jnXKLVU6XfmYBKxJ5HGFJcE9D1PUEuJFH/4UnsBMc8t0X X-Received: by 2002:a17:902:d4c6:b0:1dd:6ce3:7442 with SMTP id d9443c01a7336-1eeb03a5436mr51880955ad.39.1715235409961; Wed, 08 May 2024 23:16:49 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715235409; cv=pass; d=google.com; s=arc-20160816; b=nCO/+gFZx3BVhqgarW7vttigisA49h/UMFSRDXvVbXN/IzVtYX7o8a7EAuczyn+vSG eqzFJ/HutbyDBI5nZEDIP3araPuQexn691me2GvrZ704kqCYSbEWyj5kFdBK5sucePiE L8Ey9zrmUGf6QyfAwCuuN3Vr+NfnCjDxf19INUNUAeuRmScn+WIXdfVJzOwbCbC3lWTE vmBwAn1gtbTZMFSGiRjnIqIc+wefVA/TC7UmR4XcQZJia1aD0tuIGrhh+cRXKcC2YLbX 2ToIAI4UD2Es1xGpSokXmEaxSvvL5DLfYS6UCx87nKbZXZmqTofvpp/px/mmekhMS9BQ Hrhg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-subscribe:list-id:precedence:references :in-reply-to:message-id:date:subject:cc:to:from; bh=4YnRe2VnaiDtmr5LwXEmgtZGFQbqD311c6AoS4i6o2o=; fh=6JNnxDfEnr7o579DMPRTsQZxS8rnesbXYQmdjTKdPbk=; b=Wmb9xgPMvPzJLCtvuTZyz+3VWCHWEkN3OiUUXnJyf+/Pr8jWMVlr7d5s9z82FG5kQh x/Asrimg63ec7bETKH3OLfEMRUrIzpiP9hNrs9RC3hMqcU4dEyELXo5zAbfVM7wvZ+4N Foyl73mkt666gktd59CerYroFA+slXAyQqitByOREG8XX9lMM5Ih/lr7kjiMMNOwI8hC 6HGc3CiGvY59Hazss6nONG0z1ttroxnil8T4GiLig7Fwtx/B8lfjz8IZ+C9P5kXo8MJO rAfx4vz8Fkr9sjmvJbCu60Ba+uc0tK1BCtM0wKcYmDCkMutsgwHwk1XQb89mnC3B48uu GKoA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: domain of linux-kernel+bounces-174186-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-174186-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id d9443c01a7336-1ef0c160af6si7928755ad.545.2024.05.08.23.16.49 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 May 2024 23:16:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-174186-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: domain of linux-kernel+bounces-174186-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-174186-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 89197284DB4 for ; Thu, 9 May 2024 06:16:20 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1144F14A088; Thu, 9 May 2024 06:15:57 +0000 (UTC) Received: from inva020.nxp.com (inva020.nxp.com [92.121.34.13]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id EA7F5149C61; Thu, 9 May 2024 06:15:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=92.121.34.13 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715235355; cv=none; b=cEthHglMZaBNQH9T4shTb1rAg9SB5lVt1lpU0D00xTIw84M9KILP6ywyi9fViA37eSwfQ5Rk6RCtz5w6fld7GoEzoU8UncZBzd8HN93JHmVTfniqrR0Fgs7eLPN/pLl8cgzS6u0qc/ULdidQFJqf5J3uSKMW8lDxmYvn/1FbmkY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715235355; c=relaxed/simple; bh=mrEJ88IGf6e18/kECgqIOfF52OjKbXhjc74Lefp+CUI=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References; b=QVdqu/ZAGbCElz1AT81vMwFWHACLWtIlR48q1tXcaXnlI4/QyZztFDayzBWcOpwN9Ng9HHaHIRoh7uejoZstWA3ZO75Tf6PMVkhBrWWQZSAuPfh6yU5/9HK34SMKLgn7cXPGCdmz6RQdKtdKDjzpRPDwoXxDRssmSnVOa6KG1H4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; arc=none smtp.client-ip=92.121.34.13 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Received: from inva020.nxp.com (localhost [127.0.0.1]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id CFDDA1A1F48; Thu, 9 May 2024 08:15:42 +0200 (CEST) Received: from aprdc01srsp001v.ap-rdc01.nxp.com (aprdc01srsp001v.ap-rdc01.nxp.com [165.114.16.16]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id 48B641A1F45; Thu, 9 May 2024 08:15:42 +0200 (CEST) Received: from localhost.localdomain (shlinux2.ap.freescale.net [10.192.224.44]) by aprdc01srsp001v.ap-rdc01.nxp.com (Postfix) with ESMTP id 50CC31834870; Thu, 9 May 2024 14:15:40 +0800 (+08) From: Richard Zhu To: conor@kernel.org, vkoul@kernel.org, kishon@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, frank.li@nxp.com, conor+dt@kernel.org Cc: hongxing.zhu@nxp.com, linux-phy@lists.infradead.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, kernel@pengutronix.de, imx@lists.linux.dev Subject: [PATCH v4 2/3] dt-bindings: phy: Add i.MX8Q HSIO SerDes PHY binding Date: Thu, 9 May 2024 13:56:20 +0800 Message-Id: <1715234181-672-3-git-send-email-hongxing.zhu@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1715234181-672-1-git-send-email-hongxing.zhu@nxp.com> References: <1715234181-672-1-git-send-email-hongxing.zhu@nxp.com> X-Virus-Scanned: ClamAV using ClamSMTP Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Add i.MX8QM and i.MX8QXP HSIO SerDes PHY binding. Introduce one HSIO configuration 'fsl,hsio-cfg', which need be set at initialization according to board design. Signed-off-by: Richard Zhu --- .../bindings/phy/fsl,imx8qm-hsio.yaml | 142 ++++++++++++++++++ 1 file changed, 142 insertions(+) create mode 100644 Documentation/devicetree/bindings/phy/fsl,imx8qm-hsio.yaml diff --git a/Documentation/devicetree/bindings/phy/fsl,imx8qm-hsio.yaml b/Documentation/devicetree/bindings/phy/fsl,imx8qm-hsio.yaml new file mode 100644 index 000000000000..e8648cd9fea6 --- /dev/null +++ b/Documentation/devicetree/bindings/phy/fsl,imx8qm-hsio.yaml @@ -0,0 +1,142 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/phy/fsl,imx8qm-hsio.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Freescale i.MX8QM SoC series HSIO SERDES PHY + +maintainers: + - Richard Zhu + +properties: + compatible: + enum: + - fsl,imx8qm-hsio + - fsl,imx8qxp-hsio + reg: + minItems: 4 + maxItems: 4 + + "#phy-cells": + const: 3 + description: + The first defines lane index. + The second defines the type of the PHY refer to the include phy.h. + The third defines the controller index, indicated which controller + is bound to the lane. + + reg-names: + items: + - const: reg + - const: phy + - const: ctrl + - const: misc + + clocks: + minItems: 5 + maxItems: 14 + + clock-names: + minItems: 5 + maxItems: 14 + + fsl,hsio-cfg: + description: Refer macro HSIO_CFG* include/dt-bindings/phy/phy-imx8-pcie.h. + $ref: /schemas/types.yaml#/definitions/uint32 + + fsl,refclk-pad-mode: + description: + Specifies the mode of the refclk pad used. INPUT(PHY refclock is + provided externally via the refclk pad) or OUTPUT(PHY refclock is + derived from SoC internal source and provided on the refclk pad). + $ref: /schemas/types.yaml#/definitions/string + enum: [ "input", "output" ] + + power-domains: + minItems: 1 + maxItems: 2 + +required: + - compatible + - reg + - reg-names + - "#phy-cells" + - clocks + - clock-names + - fsl,hsio-cfg + +allOf: + - if: + properties: + compatible: + contains: + enum: + - fsl,imx8qxp-hsio + then: + properties: + clock-names: + items: + - const: pclk0 + - const: apb_pclk0 + - const: phy0_crr + - const: ctl0_crr + - const: misc_crr + power-domains: + minItems: 1 + + - if: + properties: + compatible: + contains: + enum: + - fsl,imx8qm-hsio + then: + properties: + clock-names: + items: + - const: pclk0 + - const: pclk1 + - const: apb_pclk0 + - const: apb_pclk1 + - const: pclk2 + - const: epcs_tx + - const: epcs_rx + - const: apb_pclk2 + - const: phy0_crr + - const: phy1_crr + - const: ctl0_crr + - const: ctl1_crr + - const: ctl2_crr + - const: misc_crr + power-domains: + minItems: 2 + +additionalProperties: false + +examples: + - | + #include + #include + #include + #include + + hsio_phy@5f1a0000 { + compatible = "fsl,imx8qxp-hsio"; + reg = <0x5f1a0000 0x10000>, + <0x5f120000 0x10000>, + <0x5f140000 0x10000>, + <0x5f160000 0x10000>; + reg-names = "reg", "phy", "ctrl", "misc"; + clocks = <&phyx1_lpcg IMX_LPCG_CLK_0>, + <&phyx1_lpcg IMX_LPCG_CLK_4>, + <&phyx1_crr1_lpcg IMX_LPCG_CLK_4>, + <&pcieb_crr3_lpcg IMX_LPCG_CLK_4>, + <&misc_crr5_lpcg IMX_LPCG_CLK_4>; + clock-names = "pclk0", "apb_pclk0", "phy0_crr", "ctl0_crr", "misc_crr"; + power-domains = <&pd IMX_SC_R_SERDES_1>; + #phy-cells = <3>; + fsl,hsio-cfg = ; + fsl,refclk-pad-mode = "input"; + }; +... -- 2.37.1