Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: clock: add qca8386/qca8084 clock and reset definitions

QCA8386/QCA8084 includes the clock & reset controller that is
accessed by MDIO bus. Two work modes are supported, qca8386 works
as switch mode, qca8084 works as PHY mode.

Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
Link: https://lore.kernel.org/r/20240605124541.2711467-3-quic_luoj@quicinc.com
Signed-off-by: Bjorn Andersson <andersson@kernel.org>

authored by

Luo Jie and committed by
Bjorn Andersson
80bbd1c3 7311bbff

+263
+86
Documentation/devicetree/bindings/clock/qcom,qca8k-nsscc.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/clock/qcom,qca8k-nsscc.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: Qualcomm NSS Clock & Reset Controller on QCA8386/QCA8084 8 + 9 + maintainers: 10 + - Bjorn Andersson <andersson@kernel.org> 11 + - Luo Jie <quic_luoj@quicinc.com> 12 + 13 + description: | 14 + Qualcomm NSS clock control module provides the clocks and resets 15 + on QCA8386(switch mode)/QCA8084(PHY mode) 16 + 17 + See also:: 18 + include/dt-bindings/clock/qcom,qca8k-nsscc.h 19 + include/dt-bindings/reset/qcom,qca8k-nsscc.h 20 + 21 + properties: 22 + compatible: 23 + oneOf: 24 + - const: qcom,qca8084-nsscc 25 + - items: 26 + - enum: 27 + - qcom,qca8082-nsscc 28 + - qcom,qca8085-nsscc 29 + - qcom,qca8384-nsscc 30 + - qcom,qca8385-nsscc 31 + - qcom,qca8386-nsscc 32 + - const: qcom,qca8084-nsscc 33 + 34 + clocks: 35 + items: 36 + - description: Chip reference clock source 37 + - description: UNIPHY0 RX 312P5M/125M clock source 38 + - description: UNIPHY0 TX 312P5M/125M clock source 39 + - description: UNIPHY1 RX 312P5M/125M clock source 40 + - description: UNIPHY1 TX 312P5M/125M clock source 41 + - description: UNIPHY1 RX 312P5M clock source 42 + - description: UNIPHY1 TX 312P5M clock source 43 + 44 + reg: 45 + items: 46 + - description: MDIO bus address for Clock & Reset Controller register 47 + 48 + reset-gpios: 49 + description: GPIO connected to the chip 50 + maxItems: 1 51 + 52 + required: 53 + - compatible 54 + - clocks 55 + - reg 56 + - reset-gpios 57 + 58 + allOf: 59 + - $ref: qcom,gcc.yaml# 60 + 61 + unevaluatedProperties: false 62 + 63 + examples: 64 + - | 65 + #include <dt-bindings/gpio/gpio.h> 66 + mdio { 67 + #address-cells = <1>; 68 + #size-cells = <0>; 69 + 70 + clock-controller@18 { 71 + compatible = "qcom,qca8084-nsscc"; 72 + reg = <0x18>; 73 + reset-gpios = <&tlmm 51 GPIO_ACTIVE_LOW>; 74 + clocks = <&pcs0_pll>, 75 + <&qca8k_uniphy0_rx>, 76 + <&qca8k_uniphy0_tx>, 77 + <&qca8k_uniphy1_rx>, 78 + <&qca8k_uniphy1_tx>, 79 + <&qca8k_uniphy1_rx312p5m>, 80 + <&qca8k_uniphy1_tx312p5m>; 81 + #clock-cells = <1>; 82 + #reset-cells = <1>; 83 + #power-domain-cells = <1>; 84 + }; 85 + }; 86 + ...
+101
include/dt-bindings/clock/qcom,qca8k-nsscc.h
··· 1 + /* SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) */ 2 + /* 3 + * Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved. 4 + */ 5 + 6 + #ifndef _DT_BINDINGS_CLK_QCOM_QCA8K_NSS_CC_H 7 + #define _DT_BINDINGS_CLK_QCOM_QCA8K_NSS_CC_H 8 + 9 + #define NSS_CC_SWITCH_CORE_CLK_SRC 0 10 + #define NSS_CC_SWITCH_CORE_CLK 1 11 + #define NSS_CC_APB_BRIDGE_CLK 2 12 + #define NSS_CC_MAC0_TX_CLK_SRC 3 13 + #define NSS_CC_MAC0_TX_DIV_CLK_SRC 4 14 + #define NSS_CC_MAC0_TX_CLK 5 15 + #define NSS_CC_MAC0_TX_SRDS1_CLK 6 16 + #define NSS_CC_MAC0_RX_CLK_SRC 7 17 + #define NSS_CC_MAC0_RX_DIV_CLK_SRC 8 18 + #define NSS_CC_MAC0_RX_CLK 9 19 + #define NSS_CC_MAC0_RX_SRDS1_CLK 10 20 + #define NSS_CC_MAC1_TX_CLK_SRC 11 21 + #define NSS_CC_MAC1_TX_DIV_CLK_SRC 12 22 + #define NSS_CC_MAC1_SRDS1_CH0_XGMII_RX_DIV_CLK_SRC 13 23 + #define NSS_CC_MAC1_SRDS1_CH0_RX_CLK 14 24 + #define NSS_CC_MAC1_TX_CLK 15 25 + #define NSS_CC_MAC1_GEPHY0_TX_CLK 16 26 + #define NSS_CC_MAC1_SRDS1_CH0_XGMII_RX_CLK 17 27 + #define NSS_CC_MAC1_RX_CLK_SRC 18 28 + #define NSS_CC_MAC1_RX_DIV_CLK_SRC 19 29 + #define NSS_CC_MAC1_SRDS1_CH0_XGMII_TX_DIV_CLK_SRC 20 30 + #define NSS_CC_MAC1_SRDS1_CH0_TX_CLK 21 31 + #define NSS_CC_MAC1_RX_CLK 22 32 + #define NSS_CC_MAC1_GEPHY0_RX_CLK 23 33 + #define NSS_CC_MAC1_SRDS1_CH0_XGMII_TX_CLK 24 34 + #define NSS_CC_MAC2_TX_CLK_SRC 25 35 + #define NSS_CC_MAC2_TX_DIV_CLK_SRC 26 36 + #define NSS_CC_MAC2_SRDS1_CH1_XGMII_RX_DIV_CLK_SRC 27 37 + #define NSS_CC_MAC2_SRDS1_CH1_RX_CLK 28 38 + #define NSS_CC_MAC2_TX_CLK 29 39 + #define NSS_CC_MAC2_GEPHY1_TX_CLK 30 40 + #define NSS_CC_MAC2_SRDS1_CH1_XGMII_RX_CLK 31 41 + #define NSS_CC_MAC2_RX_CLK_SRC 32 42 + #define NSS_CC_MAC2_RX_DIV_CLK_SRC 33 43 + #define NSS_CC_MAC2_SRDS1_CH1_XGMII_TX_DIV_CLK_SRC 34 44 + #define NSS_CC_MAC2_SRDS1_CH1_TX_CLK 35 45 + #define NSS_CC_MAC2_RX_CLK 36 46 + #define NSS_CC_MAC2_GEPHY1_RX_CLK 37 47 + #define NSS_CC_MAC2_SRDS1_CH1_XGMII_TX_CLK 38 48 + #define NSS_CC_MAC3_TX_CLK_SRC 39 49 + #define NSS_CC_MAC3_TX_DIV_CLK_SRC 40 50 + #define NSS_CC_MAC3_SRDS1_CH2_XGMII_RX_DIV_CLK_SRC 41 51 + #define NSS_CC_MAC3_SRDS1_CH2_RX_CLK 42 52 + #define NSS_CC_MAC3_TX_CLK 43 53 + #define NSS_CC_MAC3_GEPHY2_TX_CLK 44 54 + #define NSS_CC_MAC3_SRDS1_CH2_XGMII_RX_CLK 45 55 + #define NSS_CC_MAC3_RX_CLK_SRC 46 56 + #define NSS_CC_MAC3_RX_DIV_CLK_SRC 47 57 + #define NSS_CC_MAC3_SRDS1_CH2_XGMII_TX_DIV_CLK_SRC 48 58 + #define NSS_CC_MAC3_SRDS1_CH2_TX_CLK 49 59 + #define NSS_CC_MAC3_RX_CLK 50 60 + #define NSS_CC_MAC3_GEPHY2_RX_CLK 51 61 + #define NSS_CC_MAC3_SRDS1_CH2_XGMII_TX_CLK 52 62 + #define NSS_CC_MAC4_TX_CLK_SRC 53 63 + #define NSS_CC_MAC4_TX_DIV_CLK_SRC 54 64 + #define NSS_CC_MAC4_SRDS1_CH3_XGMII_RX_DIV_CLK_SRC 55 65 + #define NSS_CC_MAC4_SRDS1_CH3_RX_CLK 56 66 + #define NSS_CC_MAC4_TX_CLK 57 67 + #define NSS_CC_MAC4_GEPHY3_TX_CLK 58 68 + #define NSS_CC_MAC4_SRDS1_CH3_XGMII_RX_CLK 59 69 + #define NSS_CC_MAC4_RX_CLK_SRC 60 70 + #define NSS_CC_MAC4_RX_DIV_CLK_SRC 61 71 + #define NSS_CC_MAC4_SRDS1_CH3_XGMII_TX_DIV_CLK_SRC 62 72 + #define NSS_CC_MAC4_SRDS1_CH3_TX_CLK 63 73 + #define NSS_CC_MAC4_RX_CLK 64 74 + #define NSS_CC_MAC4_GEPHY3_RX_CLK 65 75 + #define NSS_CC_MAC4_SRDS1_CH3_XGMII_TX_CLK 66 76 + #define NSS_CC_MAC5_TX_CLK_SRC 67 77 + #define NSS_CC_MAC5_TX_DIV_CLK_SRC 68 78 + #define NSS_CC_MAC5_TX_SRDS0_CLK 69 79 + #define NSS_CC_MAC5_TX_CLK 70 80 + #define NSS_CC_MAC5_RX_CLK_SRC 71 81 + #define NSS_CC_MAC5_RX_DIV_CLK_SRC 72 82 + #define NSS_CC_MAC5_RX_SRDS0_CLK 73 83 + #define NSS_CC_MAC5_RX_CLK 74 84 + #define NSS_CC_MAC5_TX_SRDS0_CLK_SRC 75 85 + #define NSS_CC_MAC5_RX_SRDS0_CLK_SRC 76 86 + #define NSS_CC_AHB_CLK_SRC 77 87 + #define NSS_CC_AHB_CLK 78 88 + #define NSS_CC_SEC_CTRL_AHB_CLK 79 89 + #define NSS_CC_TLMM_CLK 80 90 + #define NSS_CC_TLMM_AHB_CLK 81 91 + #define NSS_CC_CNOC_AHB_CLK 82 92 + #define NSS_CC_MDIO_AHB_CLK 83 93 + #define NSS_CC_MDIO_MASTER_AHB_CLK 84 94 + #define NSS_CC_SYS_CLK_SRC 85 95 + #define NSS_CC_SRDS0_SYS_CLK 86 96 + #define NSS_CC_SRDS1_SYS_CLK 87 97 + #define NSS_CC_GEPHY0_SYS_CLK 88 98 + #define NSS_CC_GEPHY1_SYS_CLK 89 99 + #define NSS_CC_GEPHY2_SYS_CLK 90 100 + #define NSS_CC_GEPHY3_SYS_CLK 91 101 + #endif
+76
include/dt-bindings/reset/qcom,qca8k-nsscc.h
··· 1 + /* SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) */ 2 + /* 3 + * Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved. 4 + */ 5 + 6 + #ifndef _DT_BINDINGS_RESET_QCOM_QCA8K_NSS_CC_H 7 + #define _DT_BINDINGS_RESET_QCOM_QCA8K_NSS_CC_H 8 + 9 + #define NSS_CC_SWITCH_CORE_ARES 1 10 + #define NSS_CC_APB_BRIDGE_ARES 2 11 + #define NSS_CC_MAC0_TX_ARES 3 12 + #define NSS_CC_MAC0_TX_SRDS1_ARES 4 13 + #define NSS_CC_MAC0_RX_ARES 5 14 + #define NSS_CC_MAC0_RX_SRDS1_ARES 6 15 + #define NSS_CC_MAC1_SRDS1_CH0_RX_ARES 7 16 + #define NSS_CC_MAC1_TX_ARES 8 17 + #define NSS_CC_MAC1_GEPHY0_TX_ARES 9 18 + #define NSS_CC_MAC1_SRDS1_CH0_XGMII_RX_ARES 10 19 + #define NSS_CC_MAC1_SRDS1_CH0_TX_ARES 11 20 + #define NSS_CC_MAC1_RX_ARES 12 21 + #define NSS_CC_MAC1_GEPHY0_RX_ARES 13 22 + #define NSS_CC_MAC1_SRDS1_CH0_XGMII_TX_ARES 14 23 + #define NSS_CC_MAC2_SRDS1_CH1_RX_ARES 15 24 + #define NSS_CC_MAC2_TX_ARES 16 25 + #define NSS_CC_MAC2_GEPHY1_TX_ARES 17 26 + #define NSS_CC_MAC2_SRDS1_CH1_XGMII_RX_ARES 18 27 + #define NSS_CC_MAC2_SRDS1_CH1_TX_ARES 19 28 + #define NSS_CC_MAC2_RX_ARES 20 29 + #define NSS_CC_MAC2_GEPHY1_RX_ARES 21 30 + #define NSS_CC_MAC2_SRDS1_CH1_XGMII_TX_ARES 22 31 + #define NSS_CC_MAC3_SRDS1_CH2_RX_ARES 23 32 + #define NSS_CC_MAC3_TX_ARES 24 33 + #define NSS_CC_MAC3_GEPHY2_TX_ARES 25 34 + #define NSS_CC_MAC3_SRDS1_CH2_XGMII_RX_ARES 26 35 + #define NSS_CC_MAC3_SRDS1_CH2_TX_ARES 27 36 + #define NSS_CC_MAC3_RX_ARES 28 37 + #define NSS_CC_MAC3_GEPHY2_RX_ARES 29 38 + #define NSS_CC_MAC3_SRDS1_CH2_XGMII_TX_ARES 30 39 + #define NSS_CC_MAC4_SRDS1_CH3_RX_ARES 31 40 + #define NSS_CC_MAC4_TX_ARES 32 41 + #define NSS_CC_MAC4_GEPHY3_TX_ARES 33 42 + #define NSS_CC_MAC4_SRDS1_CH3_XGMII_RX_ARES 34 43 + #define NSS_CC_MAC4_SRDS1_CH3_TX_ARES 35 44 + #define NSS_CC_MAC4_RX_ARES 36 45 + #define NSS_CC_MAC4_GEPHY3_RX_ARES 37 46 + #define NSS_CC_MAC4_SRDS1_CH3_XGMII_TX_ARES 38 47 + #define NSS_CC_MAC5_TX_ARES 39 48 + #define NSS_CC_MAC5_TX_SRDS0_ARES 40 49 + #define NSS_CC_MAC5_RX_ARES 41 50 + #define NSS_CC_MAC5_RX_SRDS0_ARES 42 51 + #define NSS_CC_AHB_ARES 43 52 + #define NSS_CC_SEC_CTRL_AHB_ARES 44 53 + #define NSS_CC_TLMM_ARES 45 54 + #define NSS_CC_TLMM_AHB_ARES 46 55 + #define NSS_CC_CNOC_AHB_ARES 47 56 + #define NSS_CC_MDIO_AHB_ARES 48 57 + #define NSS_CC_MDIO_MASTER_AHB_ARES 49 58 + #define NSS_CC_SRDS0_SYS_ARES 50 59 + #define NSS_CC_SRDS1_SYS_ARES 51 60 + #define NSS_CC_GEPHY0_SYS_ARES 52 61 + #define NSS_CC_GEPHY1_SYS_ARES 53 62 + #define NSS_CC_GEPHY2_SYS_ARES 54 63 + #define NSS_CC_GEPHY3_SYS_ARES 55 64 + #define NSS_CC_SEC_CTRL_ARES 56 65 + #define NSS_CC_SEC_CTRL_SENSE_ARES 57 66 + #define NSS_CC_SLEEP_ARES 58 67 + #define NSS_CC_DEBUG_ARES 59 68 + #define NSS_CC_GEPHY0_ARES 60 69 + #define NSS_CC_GEPHY1_ARES 61 70 + #define NSS_CC_GEPHY2_ARES 62 71 + #define NSS_CC_GEPHY3_ARES 63 72 + #define NSS_CC_DSP_ARES 64 73 + #define NSS_CC_GEPHY_FULL_ARES 65 74 + #define NSS_CC_GLOBAL_ARES 66 75 + #define NSS_CC_XPCS_ARES 67 76 + #endif