18c2ecf20Sopenharmony_ci/*
28c2ecf20Sopenharmony_ci *  BSD LICENSE
38c2ecf20Sopenharmony_ci *
48c2ecf20Sopenharmony_ci *  Copyright(c) 2016-2017 Broadcom.  All rights reserved.
58c2ecf20Sopenharmony_ci *
68c2ecf20Sopenharmony_ci *  Redistribution and use in source and binary forms, with or without
78c2ecf20Sopenharmony_ci *  modification, are permitted provided that the following conditions
88c2ecf20Sopenharmony_ci *  are met:
98c2ecf20Sopenharmony_ci *
108c2ecf20Sopenharmony_ci *    * Redistributions of source code must retain the above copyright
118c2ecf20Sopenharmony_ci *      notice, this list of conditions and the following disclaimer.
128c2ecf20Sopenharmony_ci *    * Redistributions in binary form must reproduce the above copyright
138c2ecf20Sopenharmony_ci *      notice, this list of conditions and the following disclaimer in
148c2ecf20Sopenharmony_ci *      the documentation and/or other materials provided with the
158c2ecf20Sopenharmony_ci *      distribution.
168c2ecf20Sopenharmony_ci *    * Neither the name of Broadcom nor the names of its
178c2ecf20Sopenharmony_ci *      contributors may be used to endorse or promote products derived
188c2ecf20Sopenharmony_ci *      from this software without specific prior written permission.
198c2ecf20Sopenharmony_ci *
208c2ecf20Sopenharmony_ci *  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
218c2ecf20Sopenharmony_ci *  "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
228c2ecf20Sopenharmony_ci *  LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
238c2ecf20Sopenharmony_ci *  A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
248c2ecf20Sopenharmony_ci *  OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
258c2ecf20Sopenharmony_ci *  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
268c2ecf20Sopenharmony_ci *  LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
278c2ecf20Sopenharmony_ci *  DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
288c2ecf20Sopenharmony_ci *  THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
298c2ecf20Sopenharmony_ci *  (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
308c2ecf20Sopenharmony_ci *  OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
318c2ecf20Sopenharmony_ci */
328c2ecf20Sopenharmony_ci
338c2ecf20Sopenharmony_ci#include <dt-bindings/clock/bcm-sr.h>
348c2ecf20Sopenharmony_ci
358c2ecf20Sopenharmony_ci		osc: oscillator {
368c2ecf20Sopenharmony_ci			#clock-cells = <0>;
378c2ecf20Sopenharmony_ci			compatible = "fixed-clock";
388c2ecf20Sopenharmony_ci			clock-frequency = <50000000>;
398c2ecf20Sopenharmony_ci		};
408c2ecf20Sopenharmony_ci
418c2ecf20Sopenharmony_ci		crmu_ref25m: crmu_ref25m {
428c2ecf20Sopenharmony_ci			#clock-cells = <0>;
438c2ecf20Sopenharmony_ci			compatible = "fixed-factor-clock";
448c2ecf20Sopenharmony_ci			clocks = <&osc>;
458c2ecf20Sopenharmony_ci			clock-div = <2>;
468c2ecf20Sopenharmony_ci			clock-mult = <1>;
478c2ecf20Sopenharmony_ci		};
488c2ecf20Sopenharmony_ci
498c2ecf20Sopenharmony_ci		genpll0: genpll0@1d104 {
508c2ecf20Sopenharmony_ci			#clock-cells = <1>;
518c2ecf20Sopenharmony_ci			compatible = "brcm,sr-genpll0";
528c2ecf20Sopenharmony_ci			reg = <0x0001d104 0x32>,
538c2ecf20Sopenharmony_ci			      <0x0001c854 0x4>;
548c2ecf20Sopenharmony_ci			clocks = <&osc>;
558c2ecf20Sopenharmony_ci			clock-output-names = "genpll0", "clk_125m", "clk_scr",
568c2ecf20Sopenharmony_ci					     "clk_250", "clk_pcie_axi",
578c2ecf20Sopenharmony_ci					     "clk_paxc_axi_x2",
588c2ecf20Sopenharmony_ci					     "clk_paxc_axi";
598c2ecf20Sopenharmony_ci		};
608c2ecf20Sopenharmony_ci
618c2ecf20Sopenharmony_ci		genpll2: genpll2@1d1ac {
628c2ecf20Sopenharmony_ci			#clock-cells = <1>;
638c2ecf20Sopenharmony_ci			compatible = "brcm,sr-genpll2";
648c2ecf20Sopenharmony_ci			reg = <0x0001d1ac 0x32>,
658c2ecf20Sopenharmony_ci			      <0x0001c854 0x4>;
668c2ecf20Sopenharmony_ci			clocks = <&osc>;
678c2ecf20Sopenharmony_ci			clock-output-names = "genpll2", "clk_nic",
688c2ecf20Sopenharmony_ci					     "clk_ts_500_ref", "clk_125_nitro",
698c2ecf20Sopenharmony_ci					     "clk_chimp", "clk_nic_flash",
708c2ecf20Sopenharmony_ci					     "clk_fs";
718c2ecf20Sopenharmony_ci		};
728c2ecf20Sopenharmony_ci
738c2ecf20Sopenharmony_ci		genpll3: genpll3@1d1e0 {
748c2ecf20Sopenharmony_ci			#clock-cells = <1>;
758c2ecf20Sopenharmony_ci			compatible = "brcm,sr-genpll3";
768c2ecf20Sopenharmony_ci			reg = <0x0001d1e0 0x32>,
778c2ecf20Sopenharmony_ci			      <0x0001c854 0x4>;
788c2ecf20Sopenharmony_ci			clocks = <&osc>;
798c2ecf20Sopenharmony_ci			clock-output-names = "genpll3", "clk_hsls",
808c2ecf20Sopenharmony_ci					     "clk_sdio";
818c2ecf20Sopenharmony_ci		};
828c2ecf20Sopenharmony_ci
838c2ecf20Sopenharmony_ci		genpll4: genpll4@1d214 {
848c2ecf20Sopenharmony_ci			#clock-cells = <1>;
858c2ecf20Sopenharmony_ci			compatible = "brcm,sr-genpll4";
868c2ecf20Sopenharmony_ci			reg = <0x0001d214 0x32>,
878c2ecf20Sopenharmony_ci			      <0x0001c854 0x4>;
888c2ecf20Sopenharmony_ci			clocks = <&osc>;
898c2ecf20Sopenharmony_ci			clock-output-names = "genpll4", "clk_ccn",
908c2ecf20Sopenharmony_ci					     "clk_tpiu_pll", "clk_noc",
918c2ecf20Sopenharmony_ci					     "clk_chclk_fs4",
928c2ecf20Sopenharmony_ci					     "clk_bridge_fscpu";
938c2ecf20Sopenharmony_ci		};
948c2ecf20Sopenharmony_ci
958c2ecf20Sopenharmony_ci		genpll5: genpll5@1d248 {
968c2ecf20Sopenharmony_ci			#clock-cells = <1>;
978c2ecf20Sopenharmony_ci			compatible = "brcm,sr-genpll5";
988c2ecf20Sopenharmony_ci			reg = <0x0001d248 0x32>,
998c2ecf20Sopenharmony_ci			      <0x0001c870 0x4>;
1008c2ecf20Sopenharmony_ci			clocks = <&osc>;
1018c2ecf20Sopenharmony_ci			clock-output-names = "genpll5", "clk_fs4_hf",
1028c2ecf20Sopenharmony_ci					     "clk_crypto_ae", "clk_raid_ae";
1038c2ecf20Sopenharmony_ci		};
1048c2ecf20Sopenharmony_ci
1058c2ecf20Sopenharmony_ci		lcpll0: lcpll0@1d0c4 {
1068c2ecf20Sopenharmony_ci			#clock-cells = <1>;
1078c2ecf20Sopenharmony_ci			compatible = "brcm,sr-lcpll0";
1088c2ecf20Sopenharmony_ci			reg = <0x0001d0c4 0x3c>,
1098c2ecf20Sopenharmony_ci			      <0x0001c870 0x4>;
1108c2ecf20Sopenharmony_ci			clocks = <&osc>;
1118c2ecf20Sopenharmony_ci			clock-output-names = "lcpll0", "clk_sata_refp",
1128c2ecf20Sopenharmony_ci					     "clk_sata_refn", "clk_sata_350",
1138c2ecf20Sopenharmony_ci					     "clk_sata_500";
1148c2ecf20Sopenharmony_ci		};
1158c2ecf20Sopenharmony_ci
1168c2ecf20Sopenharmony_ci		lcpll1: lcpll1@1d138 {
1178c2ecf20Sopenharmony_ci			#clock-cells = <1>;
1188c2ecf20Sopenharmony_ci			compatible = "brcm,sr-lcpll1";
1198c2ecf20Sopenharmony_ci			reg = <0x0001d138 0x3c>,
1208c2ecf20Sopenharmony_ci			      <0x0001c870 0x4>;
1218c2ecf20Sopenharmony_ci			clocks = <&osc>;
1228c2ecf20Sopenharmony_ci			clock-output-names = "lcpll1", "clk_wan",
1238c2ecf20Sopenharmony_ci					     "clk_usb_ref",
1248c2ecf20Sopenharmony_ci					     "clk_crmu_ts";
1258c2ecf20Sopenharmony_ci		};
1268c2ecf20Sopenharmony_ci
1278c2ecf20Sopenharmony_ci		hsls_clk: hsls_clk {
1288c2ecf20Sopenharmony_ci			#clock-cells = <0>;
1298c2ecf20Sopenharmony_ci			compatible = "fixed-factor-clock";
1308c2ecf20Sopenharmony_ci			clocks = <&genpll3 1>;
1318c2ecf20Sopenharmony_ci			clock-div = <1>;
1328c2ecf20Sopenharmony_ci			clock-mult = <1>;
1338c2ecf20Sopenharmony_ci		};
1348c2ecf20Sopenharmony_ci
1358c2ecf20Sopenharmony_ci		hsls_div2_clk: hsls_div2_clk {
1368c2ecf20Sopenharmony_ci			#clock-cells = <0>;
1378c2ecf20Sopenharmony_ci			compatible = "fixed-factor-clock";
1388c2ecf20Sopenharmony_ci			clocks = <&genpll3 BCM_SR_GENPLL3_HSLS_CLK>;
1398c2ecf20Sopenharmony_ci			clock-div = <2>;
1408c2ecf20Sopenharmony_ci			clock-mult = <1>;
1418c2ecf20Sopenharmony_ci
1428c2ecf20Sopenharmony_ci		};
1438c2ecf20Sopenharmony_ci
1448c2ecf20Sopenharmony_ci		hsls_div4_clk: hsls_div4_clk {
1458c2ecf20Sopenharmony_ci			#clock-cells = <0>;
1468c2ecf20Sopenharmony_ci			compatible = "fixed-factor-clock";
1478c2ecf20Sopenharmony_ci			clocks = <&genpll3 BCM_SR_GENPLL3_HSLS_CLK>;
1488c2ecf20Sopenharmony_ci			clock-div = <4>;
1498c2ecf20Sopenharmony_ci			clock-mult = <1>;
1508c2ecf20Sopenharmony_ci		};
1518c2ecf20Sopenharmony_ci
1528c2ecf20Sopenharmony_ci		hsls_25m_clk: hsls_25m_clk {
1538c2ecf20Sopenharmony_ci			#clock-cells = <0>;
1548c2ecf20Sopenharmony_ci			compatible = "fixed-factor-clock";
1558c2ecf20Sopenharmony_ci			clocks = <&crmu_ref25m>;
1568c2ecf20Sopenharmony_ci			clock-div = <1>;
1578c2ecf20Sopenharmony_ci			clock-mult = <1>;
1588c2ecf20Sopenharmony_ci		};
1598c2ecf20Sopenharmony_ci
1608c2ecf20Sopenharmony_ci		hsls_25m_div2_clk: hsls_25m_div2_clk {
1618c2ecf20Sopenharmony_ci			#clock-cells = <0>;
1628c2ecf20Sopenharmony_ci			compatible = "fixed-factor-clock";
1638c2ecf20Sopenharmony_ci			clocks = <&hsls_25m_clk>;
1648c2ecf20Sopenharmony_ci			clock-div = <2>;
1658c2ecf20Sopenharmony_ci			clock-mult = <1>;
1668c2ecf20Sopenharmony_ci		};
1678c2ecf20Sopenharmony_ci
1688c2ecf20Sopenharmony_ci		sdio0_clk: sdio0_clk {
1698c2ecf20Sopenharmony_ci			#clock-cells = <0>;
1708c2ecf20Sopenharmony_ci			compatible = "fixed-factor-clock";
1718c2ecf20Sopenharmony_ci			clocks = <&genpll3 BCM_SR_GENPLL3_SDIO_CLK>;
1728c2ecf20Sopenharmony_ci			clock-div = <1>;
1738c2ecf20Sopenharmony_ci			clock-mult = <1>;
1748c2ecf20Sopenharmony_ci		};
1758c2ecf20Sopenharmony_ci
1768c2ecf20Sopenharmony_ci		sdio1_clk: sdio1_clk {
1778c2ecf20Sopenharmony_ci			#clock-cells = <0>;
1788c2ecf20Sopenharmony_ci			compatible = "fixed-factor-clock";
1798c2ecf20Sopenharmony_ci			clocks = <&genpll3 BCM_SR_GENPLL3_SDIO_CLK>;
1808c2ecf20Sopenharmony_ci			clock-div = <1>;
1818c2ecf20Sopenharmony_ci			clock-mult = <1>;
1828c2ecf20Sopenharmony_ci		};
183