Linux 4.19.133
[linux/fpc-iii.git] / drivers / clk / qcom / gcc-msm8996.c
blobbea55c461cee97bb8ac794cde09a18e731df87dc
1 /*
2 * Copyright (c) 2015, The Linux Foundation. All rights reserved.
4 * This software is licensed under the terms of the GNU General Public
5 * License version 2, as published by the Free Software Foundation, and
6 * may be copied, distributed, and modified under those terms.
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
14 #include <linux/kernel.h>
15 #include <linux/bitops.h>
16 #include <linux/err.h>
17 #include <linux/platform_device.h>
18 #include <linux/module.h>
19 #include <linux/of.h>
20 #include <linux/of_device.h>
21 #include <linux/clk-provider.h>
22 #include <linux/regmap.h>
23 #include <linux/reset-controller.h>
25 #include <dt-bindings/clock/qcom,gcc-msm8996.h>
27 #include "common.h"
28 #include "clk-regmap.h"
29 #include "clk-alpha-pll.h"
30 #include "clk-rcg.h"
31 #include "clk-branch.h"
32 #include "reset.h"
33 #include "gdsc.h"
35 enum {
36 P_XO,
37 P_GPLL0,
38 P_GPLL2,
39 P_GPLL3,
40 P_GPLL1,
41 P_GPLL2_EARLY,
42 P_GPLL0_EARLY_DIV,
43 P_SLEEP_CLK,
44 P_GPLL4,
45 P_AUD_REF_CLK,
46 P_GPLL1_EARLY_DIV
49 static const struct parent_map gcc_sleep_clk_map[] = {
50 { P_SLEEP_CLK, 5 }
53 static const char * const gcc_sleep_clk[] = {
54 "sleep_clk"
57 static const struct parent_map gcc_xo_gpll0_map[] = {
58 { P_XO, 0 },
59 { P_GPLL0, 1 }
62 static const char * const gcc_xo_gpll0[] = {
63 "xo",
64 "gpll0"
67 static const struct parent_map gcc_xo_sleep_clk_map[] = {
68 { P_XO, 0 },
69 { P_SLEEP_CLK, 5 }
72 static const char * const gcc_xo_sleep_clk[] = {
73 "xo",
74 "sleep_clk"
77 static const struct parent_map gcc_xo_gpll0_gpll0_early_div_map[] = {
78 { P_XO, 0 },
79 { P_GPLL0, 1 },
80 { P_GPLL0_EARLY_DIV, 6 }
83 static const char * const gcc_xo_gpll0_gpll0_early_div[] = {
84 "xo",
85 "gpll0",
86 "gpll0_early_div"
89 static const struct parent_map gcc_xo_gpll0_gpll4_map[] = {
90 { P_XO, 0 },
91 { P_GPLL0, 1 },
92 { P_GPLL4, 5 }
95 static const char * const gcc_xo_gpll0_gpll4[] = {
96 "xo",
97 "gpll0",
98 "gpll4"
101 static const struct parent_map gcc_xo_gpll0_aud_ref_clk_map[] = {
102 { P_XO, 0 },
103 { P_GPLL0, 1 },
104 { P_AUD_REF_CLK, 2 }
107 static const char * const gcc_xo_gpll0_aud_ref_clk[] = {
108 "xo",
109 "gpll0",
110 "aud_ref_clk"
113 static const struct parent_map gcc_xo_gpll0_sleep_clk_gpll0_early_div_map[] = {
114 { P_XO, 0 },
115 { P_GPLL0, 1 },
116 { P_SLEEP_CLK, 5 },
117 { P_GPLL0_EARLY_DIV, 6 }
120 static const char * const gcc_xo_gpll0_sleep_clk_gpll0_early_div[] = {
121 "xo",
122 "gpll0",
123 "sleep_clk",
124 "gpll0_early_div"
127 static const struct parent_map gcc_xo_gpll0_gpll4_gpll0_early_div_map[] = {
128 { P_XO, 0 },
129 { P_GPLL0, 1 },
130 { P_GPLL4, 5 },
131 { P_GPLL0_EARLY_DIV, 6 }
134 static const char * const gcc_xo_gpll0_gpll4_gpll0_early_div[] = {
135 "xo",
136 "gpll0",
137 "gpll4",
138 "gpll0_early_div"
141 static const struct parent_map gcc_xo_gpll0_gpll1_early_div_gpll1_gpll4_gpll0_early_div_map[] = {
142 { P_XO, 0 },
143 { P_GPLL0, 1 },
144 { P_GPLL1_EARLY_DIV, 3 },
145 { P_GPLL1, 4 },
146 { P_GPLL4, 5 },
147 { P_GPLL0_EARLY_DIV, 6 }
150 static const char * const gcc_xo_gpll0_gpll1_early_div_gpll1_gpll4_gpll0_early_div[] = {
151 "xo",
152 "gpll0",
153 "gpll1_early_div",
154 "gpll1",
155 "gpll4",
156 "gpll0_early_div"
159 static const struct parent_map gcc_xo_gpll0_gpll2_gpll3_gpll1_gpll2_early_gpll0_early_div_map[] = {
160 { P_XO, 0 },
161 { P_GPLL0, 1 },
162 { P_GPLL2, 2 },
163 { P_GPLL3, 3 },
164 { P_GPLL1, 4 },
165 { P_GPLL2_EARLY, 5 },
166 { P_GPLL0_EARLY_DIV, 6 }
169 static const char * const gcc_xo_gpll0_gpll2_gpll3_gpll1_gpll2_early_gpll0_early_div[] = {
170 "xo",
171 "gpll0",
172 "gpll2",
173 "gpll3",
174 "gpll1",
175 "gpll2_early",
176 "gpll0_early_div"
179 static struct clk_fixed_factor xo = {
180 .mult = 1,
181 .div = 1,
182 .hw.init = &(struct clk_init_data){
183 .name = "xo",
184 .parent_names = (const char *[]){ "xo_board" },
185 .num_parents = 1,
186 .ops = &clk_fixed_factor_ops,
190 static struct clk_alpha_pll gpll0_early = {
191 .offset = 0x00000,
192 .regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_DEFAULT],
193 .clkr = {
194 .enable_reg = 0x52000,
195 .enable_mask = BIT(0),
196 .hw.init = &(struct clk_init_data){
197 .name = "gpll0_early",
198 .parent_names = (const char *[]){ "xo" },
199 .num_parents = 1,
200 .ops = &clk_alpha_pll_ops,
205 static struct clk_fixed_factor gpll0_early_div = {
206 .mult = 1,
207 .div = 2,
208 .hw.init = &(struct clk_init_data){
209 .name = "gpll0_early_div",
210 .parent_names = (const char *[]){ "gpll0_early" },
211 .num_parents = 1,
212 .ops = &clk_fixed_factor_ops,
216 static struct clk_alpha_pll_postdiv gpll0 = {
217 .offset = 0x00000,
218 .regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_DEFAULT],
219 .clkr.hw.init = &(struct clk_init_data){
220 .name = "gpll0",
221 .parent_names = (const char *[]){ "gpll0_early" },
222 .num_parents = 1,
223 .ops = &clk_alpha_pll_postdiv_ops,
227 static struct clk_alpha_pll gpll4_early = {
228 .offset = 0x77000,
229 .regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_DEFAULT],
230 .clkr = {
231 .enable_reg = 0x52000,
232 .enable_mask = BIT(4),
233 .hw.init = &(struct clk_init_data){
234 .name = "gpll4_early",
235 .parent_names = (const char *[]){ "xo" },
236 .num_parents = 1,
237 .ops = &clk_alpha_pll_ops,
242 static struct clk_alpha_pll_postdiv gpll4 = {
243 .offset = 0x77000,
244 .regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_DEFAULT],
245 .clkr.hw.init = &(struct clk_init_data){
246 .name = "gpll4",
247 .parent_names = (const char *[]){ "gpll4_early" },
248 .num_parents = 1,
249 .ops = &clk_alpha_pll_postdiv_ops,
253 static const struct freq_tbl ftbl_system_noc_clk_src[] = {
254 F(19200000, P_XO, 1, 0, 0),
255 F(50000000, P_GPLL0_EARLY_DIV, 6, 0, 0),
256 F(100000000, P_GPLL0, 6, 0, 0),
257 F(150000000, P_GPLL0, 4, 0, 0),
258 F(200000000, P_GPLL0, 3, 0, 0),
259 F(240000000, P_GPLL0, 2.5, 0, 0),
263 static struct clk_rcg2 system_noc_clk_src = {
264 .cmd_rcgr = 0x0401c,
265 .hid_width = 5,
266 .parent_map = gcc_xo_gpll0_gpll2_gpll3_gpll1_gpll2_early_gpll0_early_div_map,
267 .freq_tbl = ftbl_system_noc_clk_src,
268 .clkr.hw.init = &(struct clk_init_data){
269 .name = "system_noc_clk_src",
270 .parent_names = gcc_xo_gpll0_gpll2_gpll3_gpll1_gpll2_early_gpll0_early_div,
271 .num_parents = 7,
272 .ops = &clk_rcg2_ops,
276 static const struct freq_tbl ftbl_config_noc_clk_src[] = {
277 F(19200000, P_XO, 1, 0, 0),
278 F(37500000, P_GPLL0, 16, 0, 0),
279 F(75000000, P_GPLL0, 8, 0, 0),
283 static struct clk_rcg2 config_noc_clk_src = {
284 .cmd_rcgr = 0x0500c,
285 .hid_width = 5,
286 .parent_map = gcc_xo_gpll0_map,
287 .freq_tbl = ftbl_config_noc_clk_src,
288 .clkr.hw.init = &(struct clk_init_data){
289 .name = "config_noc_clk_src",
290 .parent_names = gcc_xo_gpll0,
291 .num_parents = 2,
292 .ops = &clk_rcg2_ops,
296 static const struct freq_tbl ftbl_periph_noc_clk_src[] = {
297 F(19200000, P_XO, 1, 0, 0),
298 F(37500000, P_GPLL0, 16, 0, 0),
299 F(50000000, P_GPLL0, 12, 0, 0),
300 F(75000000, P_GPLL0, 8, 0, 0),
301 F(100000000, P_GPLL0, 6, 0, 0),
305 static struct clk_rcg2 periph_noc_clk_src = {
306 .cmd_rcgr = 0x06014,
307 .hid_width = 5,
308 .parent_map = gcc_xo_gpll0_map,
309 .freq_tbl = ftbl_periph_noc_clk_src,
310 .clkr.hw.init = &(struct clk_init_data){
311 .name = "periph_noc_clk_src",
312 .parent_names = gcc_xo_gpll0,
313 .num_parents = 2,
314 .ops = &clk_rcg2_ops,
318 static const struct freq_tbl ftbl_usb30_master_clk_src[] = {
319 F(19200000, P_XO, 1, 0, 0),
320 F(120000000, P_GPLL0, 5, 0, 0),
321 F(150000000, P_GPLL0, 4, 0, 0),
325 static struct clk_rcg2 usb30_master_clk_src = {
326 .cmd_rcgr = 0x0f014,
327 .mnd_width = 8,
328 .hid_width = 5,
329 .parent_map = gcc_xo_gpll0_gpll0_early_div_map,
330 .freq_tbl = ftbl_usb30_master_clk_src,
331 .clkr.hw.init = &(struct clk_init_data){
332 .name = "usb30_master_clk_src",
333 .parent_names = gcc_xo_gpll0_gpll0_early_div,
334 .num_parents = 3,
335 .ops = &clk_rcg2_ops,
339 static const struct freq_tbl ftbl_usb30_mock_utmi_clk_src[] = {
340 F(19200000, P_XO, 1, 0, 0),
344 static struct clk_rcg2 usb30_mock_utmi_clk_src = {
345 .cmd_rcgr = 0x0f028,
346 .hid_width = 5,
347 .parent_map = gcc_xo_gpll0_gpll0_early_div_map,
348 .freq_tbl = ftbl_usb30_mock_utmi_clk_src,
349 .clkr.hw.init = &(struct clk_init_data){
350 .name = "usb30_mock_utmi_clk_src",
351 .parent_names = gcc_xo_gpll0_gpll0_early_div,
352 .num_parents = 3,
353 .ops = &clk_rcg2_ops,
357 static const struct freq_tbl ftbl_usb3_phy_aux_clk_src[] = {
358 F(1200000, P_XO, 16, 0, 0),
362 static struct clk_rcg2 usb3_phy_aux_clk_src = {
363 .cmd_rcgr = 0x5000c,
364 .hid_width = 5,
365 .parent_map = gcc_xo_sleep_clk_map,
366 .freq_tbl = ftbl_usb3_phy_aux_clk_src,
367 .clkr.hw.init = &(struct clk_init_data){
368 .name = "usb3_phy_aux_clk_src",
369 .parent_names = gcc_xo_sleep_clk,
370 .num_parents = 2,
371 .ops = &clk_rcg2_ops,
375 static const struct freq_tbl ftbl_usb20_master_clk_src[] = {
376 F(120000000, P_GPLL0, 5, 0, 0),
380 static struct clk_rcg2 usb20_master_clk_src = {
381 .cmd_rcgr = 0x12010,
382 .mnd_width = 8,
383 .hid_width = 5,
384 .parent_map = gcc_xo_gpll0_gpll0_early_div_map,
385 .freq_tbl = ftbl_usb20_master_clk_src,
386 .clkr.hw.init = &(struct clk_init_data){
387 .name = "usb20_master_clk_src",
388 .parent_names = gcc_xo_gpll0_gpll0_early_div,
389 .num_parents = 3,
390 .ops = &clk_rcg2_ops,
394 static struct clk_rcg2 usb20_mock_utmi_clk_src = {
395 .cmd_rcgr = 0x12024,
396 .hid_width = 5,
397 .parent_map = gcc_xo_gpll0_gpll0_early_div_map,
398 .freq_tbl = ftbl_usb30_mock_utmi_clk_src,
399 .clkr.hw.init = &(struct clk_init_data){
400 .name = "usb20_mock_utmi_clk_src",
401 .parent_names = gcc_xo_gpll0_gpll0_early_div,
402 .num_parents = 3,
403 .ops = &clk_rcg2_ops,
407 static const struct freq_tbl ftbl_sdcc1_apps_clk_src[] = {
408 F(144000, P_XO, 16, 3, 25),
409 F(400000, P_XO, 12, 1, 4),
410 F(20000000, P_GPLL0, 15, 1, 2),
411 F(25000000, P_GPLL0, 12, 1, 2),
412 F(50000000, P_GPLL0, 12, 0, 0),
413 F(96000000, P_GPLL4, 4, 0, 0),
414 F(192000000, P_GPLL4, 2, 0, 0),
415 F(384000000, P_GPLL4, 1, 0, 0),
419 static struct clk_rcg2 sdcc1_apps_clk_src = {
420 .cmd_rcgr = 0x13010,
421 .mnd_width = 8,
422 .hid_width = 5,
423 .parent_map = gcc_xo_gpll0_gpll4_gpll0_early_div_map,
424 .freq_tbl = ftbl_sdcc1_apps_clk_src,
425 .clkr.hw.init = &(struct clk_init_data){
426 .name = "sdcc1_apps_clk_src",
427 .parent_names = gcc_xo_gpll0_gpll4_gpll0_early_div,
428 .num_parents = 4,
429 .ops = &clk_rcg2_floor_ops,
433 static struct freq_tbl ftbl_sdcc1_ice_core_clk_src[] = {
434 F(19200000, P_XO, 1, 0, 0),
435 F(150000000, P_GPLL0, 4, 0, 0),
436 F(300000000, P_GPLL0, 2, 0, 0),
440 static struct clk_rcg2 sdcc1_ice_core_clk_src = {
441 .cmd_rcgr = 0x13024,
442 .hid_width = 5,
443 .parent_map = gcc_xo_gpll0_gpll4_gpll0_early_div_map,
444 .freq_tbl = ftbl_sdcc1_ice_core_clk_src,
445 .clkr.hw.init = &(struct clk_init_data){
446 .name = "sdcc1_ice_core_clk_src",
447 .parent_names = gcc_xo_gpll0_gpll4_gpll0_early_div,
448 .num_parents = 4,
449 .ops = &clk_rcg2_ops,
453 static const struct freq_tbl ftbl_sdcc2_apps_clk_src[] = {
454 F(144000, P_XO, 16, 3, 25),
455 F(400000, P_XO, 12, 1, 4),
456 F(20000000, P_GPLL0, 15, 1, 2),
457 F(25000000, P_GPLL0, 12, 1, 2),
458 F(50000000, P_GPLL0, 12, 0, 0),
459 F(100000000, P_GPLL0, 6, 0, 0),
460 F(200000000, P_GPLL0, 3, 0, 0),
464 static struct clk_rcg2 sdcc2_apps_clk_src = {
465 .cmd_rcgr = 0x14010,
466 .mnd_width = 8,
467 .hid_width = 5,
468 .parent_map = gcc_xo_gpll0_gpll4_map,
469 .freq_tbl = ftbl_sdcc2_apps_clk_src,
470 .clkr.hw.init = &(struct clk_init_data){
471 .name = "sdcc2_apps_clk_src",
472 .parent_names = gcc_xo_gpll0_gpll4,
473 .num_parents = 3,
474 .ops = &clk_rcg2_floor_ops,
478 static struct clk_rcg2 sdcc3_apps_clk_src = {
479 .cmd_rcgr = 0x15010,
480 .mnd_width = 8,
481 .hid_width = 5,
482 .parent_map = gcc_xo_gpll0_gpll4_map,
483 .freq_tbl = ftbl_sdcc2_apps_clk_src,
484 .clkr.hw.init = &(struct clk_init_data){
485 .name = "sdcc3_apps_clk_src",
486 .parent_names = gcc_xo_gpll0_gpll4,
487 .num_parents = 3,
488 .ops = &clk_rcg2_floor_ops,
492 static const struct freq_tbl ftbl_sdcc4_apps_clk_src[] = {
493 F(144000, P_XO, 16, 3, 25),
494 F(400000, P_XO, 12, 1, 4),
495 F(20000000, P_GPLL0, 15, 1, 2),
496 F(25000000, P_GPLL0, 12, 1, 2),
497 F(50000000, P_GPLL0, 12, 0, 0),
498 F(100000000, P_GPLL0, 6, 0, 0),
502 static struct clk_rcg2 sdcc4_apps_clk_src = {
503 .cmd_rcgr = 0x16010,
504 .mnd_width = 8,
505 .hid_width = 5,
506 .parent_map = gcc_xo_gpll0_map,
507 .freq_tbl = ftbl_sdcc4_apps_clk_src,
508 .clkr.hw.init = &(struct clk_init_data){
509 .name = "sdcc4_apps_clk_src",
510 .parent_names = gcc_xo_gpll0,
511 .num_parents = 2,
512 .ops = &clk_rcg2_floor_ops,
516 static const struct freq_tbl ftbl_blsp1_qup1_spi_apps_clk_src[] = {
517 F(960000, P_XO, 10, 1, 2),
518 F(4800000, P_XO, 4, 0, 0),
519 F(9600000, P_XO, 2, 0, 0),
520 F(15000000, P_GPLL0, 10, 1, 4),
521 F(19200000, P_XO, 1, 0, 0),
522 F(25000000, P_GPLL0, 12, 1, 2),
523 F(50000000, P_GPLL0, 12, 0, 0),
527 static struct clk_rcg2 blsp1_qup1_spi_apps_clk_src = {
528 .cmd_rcgr = 0x1900c,
529 .mnd_width = 8,
530 .hid_width = 5,
531 .parent_map = gcc_xo_gpll0_map,
532 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
533 .clkr.hw.init = &(struct clk_init_data){
534 .name = "blsp1_qup1_spi_apps_clk_src",
535 .parent_names = gcc_xo_gpll0,
536 .num_parents = 2,
537 .ops = &clk_rcg2_ops,
541 static const struct freq_tbl ftbl_blsp1_qup1_i2c_apps_clk_src[] = {
542 F(19200000, P_XO, 1, 0, 0),
543 F(50000000, P_GPLL0, 12, 0, 0),
547 static struct clk_rcg2 blsp1_qup1_i2c_apps_clk_src = {
548 .cmd_rcgr = 0x19020,
549 .hid_width = 5,
550 .parent_map = gcc_xo_gpll0_map,
551 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
552 .clkr.hw.init = &(struct clk_init_data){
553 .name = "blsp1_qup1_i2c_apps_clk_src",
554 .parent_names = gcc_xo_gpll0,
555 .num_parents = 2,
556 .ops = &clk_rcg2_ops,
560 static const struct freq_tbl ftbl_blsp1_uart1_apps_clk_src[] = {
561 F(3686400, P_GPLL0, 1, 96, 15625),
562 F(7372800, P_GPLL0, 1, 192, 15625),
563 F(14745600, P_GPLL0, 1, 384, 15625),
564 F(16000000, P_GPLL0, 5, 2, 15),
565 F(19200000, P_XO, 1, 0, 0),
566 F(24000000, P_GPLL0, 5, 1, 5),
567 F(32000000, P_GPLL0, 1, 4, 75),
568 F(40000000, P_GPLL0, 15, 0, 0),
569 F(46400000, P_GPLL0, 1, 29, 375),
570 F(48000000, P_GPLL0, 12.5, 0, 0),
571 F(51200000, P_GPLL0, 1, 32, 375),
572 F(56000000, P_GPLL0, 1, 7, 75),
573 F(58982400, P_GPLL0, 1, 1536, 15625),
574 F(60000000, P_GPLL0, 10, 0, 0),
575 F(63157895, P_GPLL0, 9.5, 0, 0),
579 static struct clk_rcg2 blsp1_uart1_apps_clk_src = {
580 .cmd_rcgr = 0x1a00c,
581 .mnd_width = 16,
582 .hid_width = 5,
583 .parent_map = gcc_xo_gpll0_map,
584 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
585 .clkr.hw.init = &(struct clk_init_data){
586 .name = "blsp1_uart1_apps_clk_src",
587 .parent_names = gcc_xo_gpll0,
588 .num_parents = 2,
589 .ops = &clk_rcg2_ops,
593 static struct clk_rcg2 blsp1_qup2_spi_apps_clk_src = {
594 .cmd_rcgr = 0x1b00c,
595 .mnd_width = 8,
596 .hid_width = 5,
597 .parent_map = gcc_xo_gpll0_map,
598 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
599 .clkr.hw.init = &(struct clk_init_data){
600 .name = "blsp1_qup2_spi_apps_clk_src",
601 .parent_names = gcc_xo_gpll0,
602 .num_parents = 2,
603 .ops = &clk_rcg2_ops,
607 static struct clk_rcg2 blsp1_qup2_i2c_apps_clk_src = {
608 .cmd_rcgr = 0x1b020,
609 .hid_width = 5,
610 .parent_map = gcc_xo_gpll0_map,
611 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
612 .clkr.hw.init = &(struct clk_init_data){
613 .name = "blsp1_qup2_i2c_apps_clk_src",
614 .parent_names = gcc_xo_gpll0,
615 .num_parents = 2,
616 .ops = &clk_rcg2_ops,
620 static struct clk_rcg2 blsp1_uart2_apps_clk_src = {
621 .cmd_rcgr = 0x1c00c,
622 .mnd_width = 16,
623 .hid_width = 5,
624 .parent_map = gcc_xo_gpll0_map,
625 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
626 .clkr.hw.init = &(struct clk_init_data){
627 .name = "blsp1_uart2_apps_clk_src",
628 .parent_names = gcc_xo_gpll0,
629 .num_parents = 2,
630 .ops = &clk_rcg2_ops,
634 static struct clk_rcg2 blsp1_qup3_spi_apps_clk_src = {
635 .cmd_rcgr = 0x1d00c,
636 .mnd_width = 8,
637 .hid_width = 5,
638 .parent_map = gcc_xo_gpll0_map,
639 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
640 .clkr.hw.init = &(struct clk_init_data){
641 .name = "blsp1_qup3_spi_apps_clk_src",
642 .parent_names = gcc_xo_gpll0,
643 .num_parents = 2,
644 .ops = &clk_rcg2_ops,
648 static struct clk_rcg2 blsp1_qup3_i2c_apps_clk_src = {
649 .cmd_rcgr = 0x1d020,
650 .hid_width = 5,
651 .parent_map = gcc_xo_gpll0_map,
652 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
653 .clkr.hw.init = &(struct clk_init_data){
654 .name = "blsp1_qup3_i2c_apps_clk_src",
655 .parent_names = gcc_xo_gpll0,
656 .num_parents = 2,
657 .ops = &clk_rcg2_ops,
661 static struct clk_rcg2 blsp1_uart3_apps_clk_src = {
662 .cmd_rcgr = 0x1e00c,
663 .mnd_width = 16,
664 .hid_width = 5,
665 .parent_map = gcc_xo_gpll0_map,
666 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
667 .clkr.hw.init = &(struct clk_init_data){
668 .name = "blsp1_uart3_apps_clk_src",
669 .parent_names = gcc_xo_gpll0,
670 .num_parents = 2,
671 .ops = &clk_rcg2_ops,
675 static struct clk_rcg2 blsp1_qup4_spi_apps_clk_src = {
676 .cmd_rcgr = 0x1f00c,
677 .mnd_width = 8,
678 .hid_width = 5,
679 .parent_map = gcc_xo_gpll0_map,
680 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
681 .clkr.hw.init = &(struct clk_init_data){
682 .name = "blsp1_qup4_spi_apps_clk_src",
683 .parent_names = gcc_xo_gpll0,
684 .num_parents = 2,
685 .ops = &clk_rcg2_ops,
689 static struct clk_rcg2 blsp1_qup4_i2c_apps_clk_src = {
690 .cmd_rcgr = 0x1f020,
691 .hid_width = 5,
692 .parent_map = gcc_xo_gpll0_map,
693 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
694 .clkr.hw.init = &(struct clk_init_data){
695 .name = "blsp1_qup4_i2c_apps_clk_src",
696 .parent_names = gcc_xo_gpll0,
697 .num_parents = 2,
698 .ops = &clk_rcg2_ops,
702 static struct clk_rcg2 blsp1_uart4_apps_clk_src = {
703 .cmd_rcgr = 0x2000c,
704 .mnd_width = 16,
705 .hid_width = 5,
706 .parent_map = gcc_xo_gpll0_map,
707 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
708 .clkr.hw.init = &(struct clk_init_data){
709 .name = "blsp1_uart4_apps_clk_src",
710 .parent_names = gcc_xo_gpll0,
711 .num_parents = 2,
712 .ops = &clk_rcg2_ops,
716 static struct clk_rcg2 blsp1_qup5_spi_apps_clk_src = {
717 .cmd_rcgr = 0x2100c,
718 .mnd_width = 8,
719 .hid_width = 5,
720 .parent_map = gcc_xo_gpll0_map,
721 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
722 .clkr.hw.init = &(struct clk_init_data){
723 .name = "blsp1_qup5_spi_apps_clk_src",
724 .parent_names = gcc_xo_gpll0,
725 .num_parents = 2,
726 .ops = &clk_rcg2_ops,
730 static struct clk_rcg2 blsp1_qup5_i2c_apps_clk_src = {
731 .cmd_rcgr = 0x21020,
732 .hid_width = 5,
733 .parent_map = gcc_xo_gpll0_map,
734 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
735 .clkr.hw.init = &(struct clk_init_data){
736 .name = "blsp1_qup5_i2c_apps_clk_src",
737 .parent_names = gcc_xo_gpll0,
738 .num_parents = 2,
739 .ops = &clk_rcg2_ops,
743 static struct clk_rcg2 blsp1_uart5_apps_clk_src = {
744 .cmd_rcgr = 0x2200c,
745 .mnd_width = 16,
746 .hid_width = 5,
747 .parent_map = gcc_xo_gpll0_map,
748 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
749 .clkr.hw.init = &(struct clk_init_data){
750 .name = "blsp1_uart5_apps_clk_src",
751 .parent_names = gcc_xo_gpll0,
752 .num_parents = 2,
753 .ops = &clk_rcg2_ops,
757 static struct clk_rcg2 blsp1_qup6_spi_apps_clk_src = {
758 .cmd_rcgr = 0x2300c,
759 .mnd_width = 8,
760 .hid_width = 5,
761 .parent_map = gcc_xo_gpll0_map,
762 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
763 .clkr.hw.init = &(struct clk_init_data){
764 .name = "blsp1_qup6_spi_apps_clk_src",
765 .parent_names = gcc_xo_gpll0,
766 .num_parents = 2,
767 .ops = &clk_rcg2_ops,
771 static struct clk_rcg2 blsp1_qup6_i2c_apps_clk_src = {
772 .cmd_rcgr = 0x23020,
773 .hid_width = 5,
774 .parent_map = gcc_xo_gpll0_map,
775 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
776 .clkr.hw.init = &(struct clk_init_data){
777 .name = "blsp1_qup6_i2c_apps_clk_src",
778 .parent_names = gcc_xo_gpll0,
779 .num_parents = 2,
780 .ops = &clk_rcg2_ops,
784 static struct clk_rcg2 blsp1_uart6_apps_clk_src = {
785 .cmd_rcgr = 0x2400c,
786 .mnd_width = 16,
787 .hid_width = 5,
788 .parent_map = gcc_xo_gpll0_map,
789 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
790 .clkr.hw.init = &(struct clk_init_data){
791 .name = "blsp1_uart6_apps_clk_src",
792 .parent_names = gcc_xo_gpll0,
793 .num_parents = 2,
794 .ops = &clk_rcg2_ops,
798 static struct clk_rcg2 blsp2_qup1_spi_apps_clk_src = {
799 .cmd_rcgr = 0x2600c,
800 .mnd_width = 8,
801 .hid_width = 5,
802 .parent_map = gcc_xo_gpll0_map,
803 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
804 .clkr.hw.init = &(struct clk_init_data){
805 .name = "blsp2_qup1_spi_apps_clk_src",
806 .parent_names = gcc_xo_gpll0,
807 .num_parents = 2,
808 .ops = &clk_rcg2_ops,
812 static struct clk_rcg2 blsp2_qup1_i2c_apps_clk_src = {
813 .cmd_rcgr = 0x26020,
814 .hid_width = 5,
815 .parent_map = gcc_xo_gpll0_map,
816 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
817 .clkr.hw.init = &(struct clk_init_data){
818 .name = "blsp2_qup1_i2c_apps_clk_src",
819 .parent_names = gcc_xo_gpll0,
820 .num_parents = 2,
821 .ops = &clk_rcg2_ops,
825 static struct clk_rcg2 blsp2_uart1_apps_clk_src = {
826 .cmd_rcgr = 0x2700c,
827 .mnd_width = 16,
828 .hid_width = 5,
829 .parent_map = gcc_xo_gpll0_map,
830 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
831 .clkr.hw.init = &(struct clk_init_data){
832 .name = "blsp2_uart1_apps_clk_src",
833 .parent_names = gcc_xo_gpll0,
834 .num_parents = 2,
835 .ops = &clk_rcg2_ops,
839 static struct clk_rcg2 blsp2_qup2_spi_apps_clk_src = {
840 .cmd_rcgr = 0x2800c,
841 .mnd_width = 8,
842 .hid_width = 5,
843 .parent_map = gcc_xo_gpll0_map,
844 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
845 .clkr.hw.init = &(struct clk_init_data){
846 .name = "blsp2_qup2_spi_apps_clk_src",
847 .parent_names = gcc_xo_gpll0,
848 .num_parents = 2,
849 .ops = &clk_rcg2_ops,
853 static struct clk_rcg2 blsp2_qup2_i2c_apps_clk_src = {
854 .cmd_rcgr = 0x28020,
855 .hid_width = 5,
856 .parent_map = gcc_xo_gpll0_map,
857 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
858 .clkr.hw.init = &(struct clk_init_data){
859 .name = "blsp2_qup2_i2c_apps_clk_src",
860 .parent_names = gcc_xo_gpll0,
861 .num_parents = 2,
862 .ops = &clk_rcg2_ops,
866 static struct clk_rcg2 blsp2_uart2_apps_clk_src = {
867 .cmd_rcgr = 0x2900c,
868 .mnd_width = 16,
869 .hid_width = 5,
870 .parent_map = gcc_xo_gpll0_map,
871 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
872 .clkr.hw.init = &(struct clk_init_data){
873 .name = "blsp2_uart2_apps_clk_src",
874 .parent_names = gcc_xo_gpll0,
875 .num_parents = 2,
876 .ops = &clk_rcg2_ops,
880 static struct clk_rcg2 blsp2_qup3_spi_apps_clk_src = {
881 .cmd_rcgr = 0x2a00c,
882 .mnd_width = 8,
883 .hid_width = 5,
884 .parent_map = gcc_xo_gpll0_map,
885 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
886 .clkr.hw.init = &(struct clk_init_data){
887 .name = "blsp2_qup3_spi_apps_clk_src",
888 .parent_names = gcc_xo_gpll0,
889 .num_parents = 2,
890 .ops = &clk_rcg2_ops,
894 static struct clk_rcg2 blsp2_qup3_i2c_apps_clk_src = {
895 .cmd_rcgr = 0x2a020,
896 .hid_width = 5,
897 .parent_map = gcc_xo_gpll0_map,
898 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
899 .clkr.hw.init = &(struct clk_init_data){
900 .name = "blsp2_qup3_i2c_apps_clk_src",
901 .parent_names = gcc_xo_gpll0,
902 .num_parents = 2,
903 .ops = &clk_rcg2_ops,
907 static struct clk_rcg2 blsp2_uart3_apps_clk_src = {
908 .cmd_rcgr = 0x2b00c,
909 .mnd_width = 16,
910 .hid_width = 5,
911 .parent_map = gcc_xo_gpll0_map,
912 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
913 .clkr.hw.init = &(struct clk_init_data){
914 .name = "blsp2_uart3_apps_clk_src",
915 .parent_names = gcc_xo_gpll0,
916 .num_parents = 2,
917 .ops = &clk_rcg2_ops,
921 static struct clk_rcg2 blsp2_qup4_spi_apps_clk_src = {
922 .cmd_rcgr = 0x2c00c,
923 .mnd_width = 8,
924 .hid_width = 5,
925 .parent_map = gcc_xo_gpll0_map,
926 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
927 .clkr.hw.init = &(struct clk_init_data){
928 .name = "blsp2_qup4_spi_apps_clk_src",
929 .parent_names = gcc_xo_gpll0,
930 .num_parents = 2,
931 .ops = &clk_rcg2_ops,
935 static struct clk_rcg2 blsp2_qup4_i2c_apps_clk_src = {
936 .cmd_rcgr = 0x2c020,
937 .hid_width = 5,
938 .parent_map = gcc_xo_gpll0_map,
939 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
940 .clkr.hw.init = &(struct clk_init_data){
941 .name = "blsp2_qup4_i2c_apps_clk_src",
942 .parent_names = gcc_xo_gpll0,
943 .num_parents = 2,
944 .ops = &clk_rcg2_ops,
948 static struct clk_rcg2 blsp2_uart4_apps_clk_src = {
949 .cmd_rcgr = 0x2d00c,
950 .mnd_width = 16,
951 .hid_width = 5,
952 .parent_map = gcc_xo_gpll0_map,
953 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
954 .clkr.hw.init = &(struct clk_init_data){
955 .name = "blsp2_uart4_apps_clk_src",
956 .parent_names = gcc_xo_gpll0,
957 .num_parents = 2,
958 .ops = &clk_rcg2_ops,
962 static struct clk_rcg2 blsp2_qup5_spi_apps_clk_src = {
963 .cmd_rcgr = 0x2e00c,
964 .mnd_width = 8,
965 .hid_width = 5,
966 .parent_map = gcc_xo_gpll0_map,
967 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
968 .clkr.hw.init = &(struct clk_init_data){
969 .name = "blsp2_qup5_spi_apps_clk_src",
970 .parent_names = gcc_xo_gpll0,
971 .num_parents = 2,
972 .ops = &clk_rcg2_ops,
976 static struct clk_rcg2 blsp2_qup5_i2c_apps_clk_src = {
977 .cmd_rcgr = 0x2e020,
978 .hid_width = 5,
979 .parent_map = gcc_xo_gpll0_map,
980 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
981 .clkr.hw.init = &(struct clk_init_data){
982 .name = "blsp2_qup5_i2c_apps_clk_src",
983 .parent_names = gcc_xo_gpll0,
984 .num_parents = 2,
985 .ops = &clk_rcg2_ops,
989 static struct clk_rcg2 blsp2_uart5_apps_clk_src = {
990 .cmd_rcgr = 0x2f00c,
991 .mnd_width = 16,
992 .hid_width = 5,
993 .parent_map = gcc_xo_gpll0_map,
994 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
995 .clkr.hw.init = &(struct clk_init_data){
996 .name = "blsp2_uart5_apps_clk_src",
997 .parent_names = gcc_xo_gpll0,
998 .num_parents = 2,
999 .ops = &clk_rcg2_ops,
1003 static struct clk_rcg2 blsp2_qup6_spi_apps_clk_src = {
1004 .cmd_rcgr = 0x3000c,
1005 .mnd_width = 8,
1006 .hid_width = 5,
1007 .parent_map = gcc_xo_gpll0_map,
1008 .freq_tbl = ftbl_blsp1_qup1_spi_apps_clk_src,
1009 .clkr.hw.init = &(struct clk_init_data){
1010 .name = "blsp2_qup6_spi_apps_clk_src",
1011 .parent_names = gcc_xo_gpll0,
1012 .num_parents = 2,
1013 .ops = &clk_rcg2_ops,
1017 static struct clk_rcg2 blsp2_qup6_i2c_apps_clk_src = {
1018 .cmd_rcgr = 0x30020,
1019 .hid_width = 5,
1020 .parent_map = gcc_xo_gpll0_map,
1021 .freq_tbl = ftbl_blsp1_qup1_i2c_apps_clk_src,
1022 .clkr.hw.init = &(struct clk_init_data){
1023 .name = "blsp2_qup6_i2c_apps_clk_src",
1024 .parent_names = gcc_xo_gpll0,
1025 .num_parents = 2,
1026 .ops = &clk_rcg2_ops,
1030 static struct clk_rcg2 blsp2_uart6_apps_clk_src = {
1031 .cmd_rcgr = 0x3100c,
1032 .mnd_width = 16,
1033 .hid_width = 5,
1034 .parent_map = gcc_xo_gpll0_map,
1035 .freq_tbl = ftbl_blsp1_uart1_apps_clk_src,
1036 .clkr.hw.init = &(struct clk_init_data){
1037 .name = "blsp2_uart6_apps_clk_src",
1038 .parent_names = gcc_xo_gpll0,
1039 .num_parents = 2,
1040 .ops = &clk_rcg2_ops,
1044 static const struct freq_tbl ftbl_pdm2_clk_src[] = {
1045 F(60000000, P_GPLL0, 10, 0, 0),
1049 static struct clk_rcg2 pdm2_clk_src = {
1050 .cmd_rcgr = 0x33010,
1051 .hid_width = 5,
1052 .parent_map = gcc_xo_gpll0_map,
1053 .freq_tbl = ftbl_pdm2_clk_src,
1054 .clkr.hw.init = &(struct clk_init_data){
1055 .name = "pdm2_clk_src",
1056 .parent_names = gcc_xo_gpll0,
1057 .num_parents = 2,
1058 .ops = &clk_rcg2_ops,
1062 static const struct freq_tbl ftbl_tsif_ref_clk_src[] = {
1063 F(105495, P_XO, 1, 1, 182),
1067 static struct clk_rcg2 tsif_ref_clk_src = {
1068 .cmd_rcgr = 0x36010,
1069 .mnd_width = 8,
1070 .hid_width = 5,
1071 .parent_map = gcc_xo_gpll0_aud_ref_clk_map,
1072 .freq_tbl = ftbl_tsif_ref_clk_src,
1073 .clkr.hw.init = &(struct clk_init_data){
1074 .name = "tsif_ref_clk_src",
1075 .parent_names = gcc_xo_gpll0_aud_ref_clk,
1076 .num_parents = 3,
1077 .ops = &clk_rcg2_ops,
1081 static struct clk_rcg2 gcc_sleep_clk_src = {
1082 .cmd_rcgr = 0x43014,
1083 .hid_width = 5,
1084 .parent_map = gcc_sleep_clk_map,
1085 .clkr.hw.init = &(struct clk_init_data){
1086 .name = "gcc_sleep_clk_src",
1087 .parent_names = gcc_sleep_clk,
1088 .num_parents = 1,
1089 .ops = &clk_rcg2_ops,
1093 static struct clk_rcg2 hmss_rbcpr_clk_src = {
1094 .cmd_rcgr = 0x48040,
1095 .hid_width = 5,
1096 .parent_map = gcc_xo_gpll0_map,
1097 .freq_tbl = ftbl_usb30_mock_utmi_clk_src,
1098 .clkr.hw.init = &(struct clk_init_data){
1099 .name = "hmss_rbcpr_clk_src",
1100 .parent_names = gcc_xo_gpll0,
1101 .num_parents = 2,
1102 .ops = &clk_rcg2_ops,
1106 static struct clk_rcg2 hmss_gpll0_clk_src = {
1107 .cmd_rcgr = 0x48058,
1108 .hid_width = 5,
1109 .parent_map = gcc_xo_gpll0_map,
1110 .clkr.hw.init = &(struct clk_init_data){
1111 .name = "hmss_gpll0_clk_src",
1112 .parent_names = gcc_xo_gpll0,
1113 .num_parents = 2,
1114 .ops = &clk_rcg2_ops,
1118 static const struct freq_tbl ftbl_gp1_clk_src[] = {
1119 F(19200000, P_XO, 1, 0, 0),
1120 F(100000000, P_GPLL0, 6, 0, 0),
1121 F(200000000, P_GPLL0, 3, 0, 0),
1125 static struct clk_rcg2 gp1_clk_src = {
1126 .cmd_rcgr = 0x64004,
1127 .mnd_width = 8,
1128 .hid_width = 5,
1129 .parent_map = gcc_xo_gpll0_sleep_clk_gpll0_early_div_map,
1130 .freq_tbl = ftbl_gp1_clk_src,
1131 .clkr.hw.init = &(struct clk_init_data){
1132 .name = "gp1_clk_src",
1133 .parent_names = gcc_xo_gpll0_sleep_clk_gpll0_early_div,
1134 .num_parents = 4,
1135 .ops = &clk_rcg2_ops,
1139 static struct clk_rcg2 gp2_clk_src = {
1140 .cmd_rcgr = 0x65004,
1141 .mnd_width = 8,
1142 .hid_width = 5,
1143 .parent_map = gcc_xo_gpll0_sleep_clk_gpll0_early_div_map,
1144 .freq_tbl = ftbl_gp1_clk_src,
1145 .clkr.hw.init = &(struct clk_init_data){
1146 .name = "gp2_clk_src",
1147 .parent_names = gcc_xo_gpll0_sleep_clk_gpll0_early_div,
1148 .num_parents = 4,
1149 .ops = &clk_rcg2_ops,
1153 static struct clk_rcg2 gp3_clk_src = {
1154 .cmd_rcgr = 0x66004,
1155 .mnd_width = 8,
1156 .hid_width = 5,
1157 .parent_map = gcc_xo_gpll0_sleep_clk_gpll0_early_div_map,
1158 .freq_tbl = ftbl_gp1_clk_src,
1159 .clkr.hw.init = &(struct clk_init_data){
1160 .name = "gp3_clk_src",
1161 .parent_names = gcc_xo_gpll0_sleep_clk_gpll0_early_div,
1162 .num_parents = 4,
1163 .ops = &clk_rcg2_ops,
1167 static const struct freq_tbl ftbl_pcie_aux_clk_src[] = {
1168 F(1010526, P_XO, 1, 1, 19),
1172 static struct clk_rcg2 pcie_aux_clk_src = {
1173 .cmd_rcgr = 0x6c000,
1174 .mnd_width = 16,
1175 .hid_width = 5,
1176 .parent_map = gcc_xo_sleep_clk_map,
1177 .freq_tbl = ftbl_pcie_aux_clk_src,
1178 .clkr.hw.init = &(struct clk_init_data){
1179 .name = "pcie_aux_clk_src",
1180 .parent_names = gcc_xo_sleep_clk,
1181 .num_parents = 2,
1182 .ops = &clk_rcg2_ops,
1186 static const struct freq_tbl ftbl_ufs_axi_clk_src[] = {
1187 F(100000000, P_GPLL0, 6, 0, 0),
1188 F(200000000, P_GPLL0, 3, 0, 0),
1189 F(240000000, P_GPLL0, 2.5, 0, 0),
1193 static struct clk_rcg2 ufs_axi_clk_src = {
1194 .cmd_rcgr = 0x75024,
1195 .mnd_width = 8,
1196 .hid_width = 5,
1197 .parent_map = gcc_xo_gpll0_map,
1198 .freq_tbl = ftbl_ufs_axi_clk_src,
1199 .clkr.hw.init = &(struct clk_init_data){
1200 .name = "ufs_axi_clk_src",
1201 .parent_names = gcc_xo_gpll0,
1202 .num_parents = 2,
1203 .ops = &clk_rcg2_ops,
1207 static const struct freq_tbl ftbl_ufs_ice_core_clk_src[] = {
1208 F(19200000, P_XO, 1, 0, 0),
1209 F(150000000, P_GPLL0, 4, 0, 0),
1210 F(300000000, P_GPLL0, 2, 0, 0),
1214 static struct clk_rcg2 ufs_ice_core_clk_src = {
1215 .cmd_rcgr = 0x76014,
1216 .hid_width = 5,
1217 .parent_map = gcc_xo_gpll0_map,
1218 .freq_tbl = ftbl_ufs_ice_core_clk_src,
1219 .clkr.hw.init = &(struct clk_init_data){
1220 .name = "ufs_ice_core_clk_src",
1221 .parent_names = gcc_xo_gpll0,
1222 .num_parents = 2,
1223 .ops = &clk_rcg2_ops,
1227 static const struct freq_tbl ftbl_qspi_ser_clk_src[] = {
1228 F(75000000, P_GPLL0, 8, 0, 0),
1229 F(150000000, P_GPLL0, 4, 0, 0),
1230 F(256000000, P_GPLL4, 1.5, 0, 0),
1231 F(300000000, P_GPLL0, 2, 0, 0),
1235 static struct clk_rcg2 qspi_ser_clk_src = {
1236 .cmd_rcgr = 0x8b00c,
1237 .hid_width = 5,
1238 .parent_map = gcc_xo_gpll0_gpll1_early_div_gpll1_gpll4_gpll0_early_div_map,
1239 .freq_tbl = ftbl_qspi_ser_clk_src,
1240 .clkr.hw.init = &(struct clk_init_data){
1241 .name = "qspi_ser_clk_src",
1242 .parent_names = gcc_xo_gpll0_gpll1_early_div_gpll1_gpll4_gpll0_early_div,
1243 .num_parents = 6,
1244 .ops = &clk_rcg2_ops,
1248 static struct clk_branch gcc_sys_noc_usb3_axi_clk = {
1249 .halt_reg = 0x0f03c,
1250 .clkr = {
1251 .enable_reg = 0x0f03c,
1252 .enable_mask = BIT(0),
1253 .hw.init = &(struct clk_init_data){
1254 .name = "gcc_sys_noc_usb3_axi_clk",
1255 .parent_names = (const char *[]){ "usb30_master_clk_src" },
1256 .num_parents = 1,
1257 .flags = CLK_SET_RATE_PARENT,
1258 .ops = &clk_branch2_ops,
1263 static struct clk_branch gcc_sys_noc_ufs_axi_clk = {
1264 .halt_reg = 0x75038,
1265 .clkr = {
1266 .enable_reg = 0x75038,
1267 .enable_mask = BIT(0),
1268 .hw.init = &(struct clk_init_data){
1269 .name = "gcc_sys_noc_ufs_axi_clk",
1270 .parent_names = (const char *[]){ "ufs_axi_clk_src" },
1271 .num_parents = 1,
1272 .flags = CLK_SET_RATE_PARENT,
1273 .ops = &clk_branch2_ops,
1278 static struct clk_branch gcc_periph_noc_usb20_ahb_clk = {
1279 .halt_reg = 0x6010,
1280 .clkr = {
1281 .enable_reg = 0x6010,
1282 .enable_mask = BIT(0),
1283 .hw.init = &(struct clk_init_data){
1284 .name = "gcc_periph_noc_usb20_ahb_clk",
1285 .parent_names = (const char *[]){ "usb20_master_clk_src" },
1286 .num_parents = 1,
1287 .flags = CLK_SET_RATE_PARENT,
1288 .ops = &clk_branch2_ops,
1293 static struct clk_branch gcc_mmss_noc_cfg_ahb_clk = {
1294 .halt_reg = 0x9008,
1295 .clkr = {
1296 .enable_reg = 0x9008,
1297 .enable_mask = BIT(0),
1298 .hw.init = &(struct clk_init_data){
1299 .name = "gcc_mmss_noc_cfg_ahb_clk",
1300 .parent_names = (const char *[]){ "config_noc_clk_src" },
1301 .num_parents = 1,
1302 .flags = CLK_SET_RATE_PARENT | CLK_IGNORE_UNUSED,
1303 .ops = &clk_branch2_ops,
1308 static struct clk_branch gcc_mmss_bimc_gfx_clk = {
1309 .halt_reg = 0x9010,
1310 .clkr = {
1311 .enable_reg = 0x9010,
1312 .enable_mask = BIT(0),
1313 .hw.init = &(struct clk_init_data){
1314 .name = "gcc_mmss_bimc_gfx_clk",
1315 .flags = CLK_SET_RATE_PARENT,
1316 .ops = &clk_branch2_ops,
1321 static struct clk_branch gcc_usb30_master_clk = {
1322 .halt_reg = 0x0f008,
1323 .clkr = {
1324 .enable_reg = 0x0f008,
1325 .enable_mask = BIT(0),
1326 .hw.init = &(struct clk_init_data){
1327 .name = "gcc_usb30_master_clk",
1328 .parent_names = (const char *[]){ "usb30_master_clk_src" },
1329 .num_parents = 1,
1330 .flags = CLK_SET_RATE_PARENT,
1331 .ops = &clk_branch2_ops,
1336 static struct clk_branch gcc_usb30_sleep_clk = {
1337 .halt_reg = 0x0f00c,
1338 .clkr = {
1339 .enable_reg = 0x0f00c,
1340 .enable_mask = BIT(0),
1341 .hw.init = &(struct clk_init_data){
1342 .name = "gcc_usb30_sleep_clk",
1343 .parent_names = (const char *[]){ "gcc_sleep_clk_src" },
1344 .num_parents = 1,
1345 .flags = CLK_SET_RATE_PARENT,
1346 .ops = &clk_branch2_ops,
1351 static struct clk_branch gcc_usb30_mock_utmi_clk = {
1352 .halt_reg = 0x0f010,
1353 .clkr = {
1354 .enable_reg = 0x0f010,
1355 .enable_mask = BIT(0),
1356 .hw.init = &(struct clk_init_data){
1357 .name = "gcc_usb30_mock_utmi_clk",
1358 .parent_names = (const char *[]){ "usb30_mock_utmi_clk_src" },
1359 .num_parents = 1,
1360 .flags = CLK_SET_RATE_PARENT,
1361 .ops = &clk_branch2_ops,
1366 static struct clk_branch gcc_usb3_phy_aux_clk = {
1367 .halt_reg = 0x50000,
1368 .clkr = {
1369 .enable_reg = 0x50000,
1370 .enable_mask = BIT(0),
1371 .hw.init = &(struct clk_init_data){
1372 .name = "gcc_usb3_phy_aux_clk",
1373 .parent_names = (const char *[]){ "usb3_phy_aux_clk_src" },
1374 .num_parents = 1,
1375 .flags = CLK_SET_RATE_PARENT,
1376 .ops = &clk_branch2_ops,
1381 static struct clk_branch gcc_usb3_phy_pipe_clk = {
1382 .halt_reg = 0x50004,
1383 .halt_check = BRANCH_HALT_SKIP,
1384 .clkr = {
1385 .enable_reg = 0x50004,
1386 .enable_mask = BIT(0),
1387 .hw.init = &(struct clk_init_data){
1388 .name = "gcc_usb3_phy_pipe_clk",
1389 .parent_names = (const char *[]){ "usb3_phy_pipe_clk_src" },
1390 .num_parents = 1,
1391 .flags = CLK_SET_RATE_PARENT,
1392 .ops = &clk_branch2_ops,
1397 static struct clk_branch gcc_usb20_master_clk = {
1398 .halt_reg = 0x12004,
1399 .clkr = {
1400 .enable_reg = 0x12004,
1401 .enable_mask = BIT(0),
1402 .hw.init = &(struct clk_init_data){
1403 .name = "gcc_usb20_master_clk",
1404 .parent_names = (const char *[]){ "usb20_master_clk_src" },
1405 .num_parents = 1,
1406 .flags = CLK_SET_RATE_PARENT,
1407 .ops = &clk_branch2_ops,
1412 static struct clk_branch gcc_usb20_sleep_clk = {
1413 .halt_reg = 0x12008,
1414 .clkr = {
1415 .enable_reg = 0x12008,
1416 .enable_mask = BIT(0),
1417 .hw.init = &(struct clk_init_data){
1418 .name = "gcc_usb20_sleep_clk",
1419 .parent_names = (const char *[]){ "gcc_sleep_clk_src" },
1420 .num_parents = 1,
1421 .flags = CLK_SET_RATE_PARENT,
1422 .ops = &clk_branch2_ops,
1427 static struct clk_branch gcc_usb20_mock_utmi_clk = {
1428 .halt_reg = 0x1200c,
1429 .clkr = {
1430 .enable_reg = 0x1200c,
1431 .enable_mask = BIT(0),
1432 .hw.init = &(struct clk_init_data){
1433 .name = "gcc_usb20_mock_utmi_clk",
1434 .parent_names = (const char *[]){ "usb20_mock_utmi_clk_src" },
1435 .num_parents = 1,
1436 .flags = CLK_SET_RATE_PARENT,
1437 .ops = &clk_branch2_ops,
1442 static struct clk_branch gcc_usb_phy_cfg_ahb2phy_clk = {
1443 .halt_reg = 0x6a004,
1444 .clkr = {
1445 .enable_reg = 0x6a004,
1446 .enable_mask = BIT(0),
1447 .hw.init = &(struct clk_init_data){
1448 .name = "gcc_usb_phy_cfg_ahb2phy_clk",
1449 .parent_names = (const char *[]){ "periph_noc_clk_src" },
1450 .num_parents = 1,
1451 .flags = CLK_SET_RATE_PARENT,
1452 .ops = &clk_branch2_ops,
1457 static struct clk_branch gcc_sdcc1_apps_clk = {
1458 .halt_reg = 0x13004,
1459 .clkr = {
1460 .enable_reg = 0x13004,
1461 .enable_mask = BIT(0),
1462 .hw.init = &(struct clk_init_data){
1463 .name = "gcc_sdcc1_apps_clk",
1464 .parent_names = (const char *[]){ "sdcc1_apps_clk_src" },
1465 .num_parents = 1,
1466 .flags = CLK_SET_RATE_PARENT,
1467 .ops = &clk_branch2_ops,
1472 static struct clk_branch gcc_sdcc1_ahb_clk = {
1473 .halt_reg = 0x13008,
1474 .clkr = {
1475 .enable_reg = 0x13008,
1476 .enable_mask = BIT(0),
1477 .hw.init = &(struct clk_init_data){
1478 .name = "gcc_sdcc1_ahb_clk",
1479 .parent_names = (const char *[]){ "periph_noc_clk_src" },
1480 .num_parents = 1,
1481 .flags = CLK_SET_RATE_PARENT,
1482 .ops = &clk_branch2_ops,
1487 static struct clk_branch gcc_sdcc1_ice_core_clk = {
1488 .halt_reg = 0x13038,
1489 .clkr = {
1490 .enable_reg = 0x13038,
1491 .enable_mask = BIT(0),
1492 .hw.init = &(struct clk_init_data){
1493 .name = "gcc_sdcc1_ice_core_clk",
1494 .parent_names = (const char *[]){ "sdcc1_ice_core_clk_src" },
1495 .num_parents = 1,
1496 .flags = CLK_SET_RATE_PARENT,
1497 .ops = &clk_branch2_ops,
1502 static struct clk_branch gcc_sdcc2_apps_clk = {
1503 .halt_reg = 0x14004,
1504 .clkr = {
1505 .enable_reg = 0x14004,
1506 .enable_mask = BIT(0),
1507 .hw.init = &(struct clk_init_data){
1508 .name = "gcc_sdcc2_apps_clk",
1509 .parent_names = (const char *[]){ "sdcc2_apps_clk_src" },
1510 .num_parents = 1,
1511 .flags = CLK_SET_RATE_PARENT,
1512 .ops = &clk_branch2_ops,
1517 static struct clk_branch gcc_sdcc2_ahb_clk = {
1518 .halt_reg = 0x14008,
1519 .clkr = {
1520 .enable_reg = 0x14008,
1521 .enable_mask = BIT(0),
1522 .hw.init = &(struct clk_init_data){
1523 .name = "gcc_sdcc2_ahb_clk",
1524 .parent_names = (const char *[]){ "periph_noc_clk_src" },
1525 .num_parents = 1,
1526 .flags = CLK_SET_RATE_PARENT,
1527 .ops = &clk_branch2_ops,
1532 static struct clk_branch gcc_sdcc3_apps_clk = {
1533 .halt_reg = 0x15004,
1534 .clkr = {
1535 .enable_reg = 0x15004,
1536 .enable_mask = BIT(0),
1537 .hw.init = &(struct clk_init_data){
1538 .name = "gcc_sdcc3_apps_clk",
1539 .parent_names = (const char *[]){ "sdcc3_apps_clk_src" },
1540 .num_parents = 1,
1541 .flags = CLK_SET_RATE_PARENT,
1542 .ops = &clk_branch2_ops,
1547 static struct clk_branch gcc_sdcc3_ahb_clk = {
1548 .halt_reg = 0x15008,
1549 .clkr = {
1550 .enable_reg = 0x15008,
1551 .enable_mask = BIT(0),
1552 .hw.init = &(struct clk_init_data){
1553 .name = "gcc_sdcc3_ahb_clk",
1554 .parent_names = (const char *[]){ "periph_noc_clk_src" },
1555 .num_parents = 1,
1556 .flags = CLK_SET_RATE_PARENT,
1557 .ops = &clk_branch2_ops,
1562 static struct clk_branch gcc_sdcc4_apps_clk = {
1563 .halt_reg = 0x16004,
1564 .clkr = {
1565 .enable_reg = 0x16004,
1566 .enable_mask = BIT(0),
1567 .hw.init = &(struct clk_init_data){
1568 .name = "gcc_sdcc4_apps_clk",
1569 .parent_names = (const char *[]){ "sdcc4_apps_clk_src" },
1570 .num_parents = 1,
1571 .flags = CLK_SET_RATE_PARENT,
1572 .ops = &clk_branch2_ops,
1577 static struct clk_branch gcc_sdcc4_ahb_clk = {
1578 .halt_reg = 0x16008,
1579 .clkr = {
1580 .enable_reg = 0x16008,
1581 .enable_mask = BIT(0),
1582 .hw.init = &(struct clk_init_data){
1583 .name = "gcc_sdcc4_ahb_clk",
1584 .parent_names = (const char *[]){ "periph_noc_clk_src" },
1585 .num_parents = 1,
1586 .flags = CLK_SET_RATE_PARENT,
1587 .ops = &clk_branch2_ops,
1592 static struct clk_branch gcc_blsp1_ahb_clk = {
1593 .halt_reg = 0x17004,
1594 .halt_check = BRANCH_HALT_VOTED,
1595 .clkr = {
1596 .enable_reg = 0x52004,
1597 .enable_mask = BIT(17),
1598 .hw.init = &(struct clk_init_data){
1599 .name = "gcc_blsp1_ahb_clk",
1600 .parent_names = (const char *[]){ "periph_noc_clk_src" },
1601 .num_parents = 1,
1602 .flags = CLK_SET_RATE_PARENT,
1603 .ops = &clk_branch2_ops,
1608 static struct clk_branch gcc_blsp1_sleep_clk = {
1609 .halt_reg = 0x17008,
1610 .halt_check = BRANCH_HALT_VOTED,
1611 .clkr = {
1612 .enable_reg = 0x52004,
1613 .enable_mask = BIT(16),
1614 .hw.init = &(struct clk_init_data){
1615 .name = "gcc_blsp1_sleep_clk",
1616 .parent_names = (const char *[]){ "gcc_sleep_clk_src" },
1617 .num_parents = 1,
1618 .flags = CLK_SET_RATE_PARENT,
1619 .ops = &clk_branch2_ops,
1624 static struct clk_branch gcc_blsp1_qup1_spi_apps_clk = {
1625 .halt_reg = 0x19004,
1626 .clkr = {
1627 .enable_reg = 0x19004,
1628 .enable_mask = BIT(0),
1629 .hw.init = &(struct clk_init_data){
1630 .name = "gcc_blsp1_qup1_spi_apps_clk",
1631 .parent_names = (const char *[]){ "blsp1_qup1_spi_apps_clk_src" },
1632 .num_parents = 1,
1633 .flags = CLK_SET_RATE_PARENT,
1634 .ops = &clk_branch2_ops,
1639 static struct clk_branch gcc_blsp1_qup1_i2c_apps_clk = {
1640 .halt_reg = 0x19008,
1641 .clkr = {
1642 .enable_reg = 0x19008,
1643 .enable_mask = BIT(0),
1644 .hw.init = &(struct clk_init_data){
1645 .name = "gcc_blsp1_qup1_i2c_apps_clk",
1646 .parent_names = (const char *[]){ "blsp1_qup1_i2c_apps_clk_src" },
1647 .num_parents = 1,
1648 .flags = CLK_SET_RATE_PARENT,
1649 .ops = &clk_branch2_ops,
1654 static struct clk_branch gcc_blsp1_uart1_apps_clk = {
1655 .halt_reg = 0x1a004,
1656 .clkr = {
1657 .enable_reg = 0x1a004,
1658 .enable_mask = BIT(0),
1659 .hw.init = &(struct clk_init_data){
1660 .name = "gcc_blsp1_uart1_apps_clk",
1661 .parent_names = (const char *[]){ "blsp1_uart1_apps_clk_src" },
1662 .num_parents = 1,
1663 .flags = CLK_SET_RATE_PARENT,
1664 .ops = &clk_branch2_ops,
1669 static struct clk_branch gcc_blsp1_qup2_spi_apps_clk = {
1670 .halt_reg = 0x1b004,
1671 .clkr = {
1672 .enable_reg = 0x1b004,
1673 .enable_mask = BIT(0),
1674 .hw.init = &(struct clk_init_data){
1675 .name = "gcc_blsp1_qup2_spi_apps_clk",
1676 .parent_names = (const char *[]){ "blsp1_qup2_spi_apps_clk_src" },
1677 .num_parents = 1,
1678 .flags = CLK_SET_RATE_PARENT,
1679 .ops = &clk_branch2_ops,
1684 static struct clk_branch gcc_blsp1_qup2_i2c_apps_clk = {
1685 .halt_reg = 0x1b008,
1686 .clkr = {
1687 .enable_reg = 0x1b008,
1688 .enable_mask = BIT(0),
1689 .hw.init = &(struct clk_init_data){
1690 .name = "gcc_blsp1_qup2_i2c_apps_clk",
1691 .parent_names = (const char *[]){ "blsp1_qup2_i2c_apps_clk_src" },
1692 .num_parents = 1,
1693 .flags = CLK_SET_RATE_PARENT,
1694 .ops = &clk_branch2_ops,
1699 static struct clk_branch gcc_blsp1_uart2_apps_clk = {
1700 .halt_reg = 0x1c004,
1701 .clkr = {
1702 .enable_reg = 0x1c004,
1703 .enable_mask = BIT(0),
1704 .hw.init = &(struct clk_init_data){
1705 .name = "gcc_blsp1_uart2_apps_clk",
1706 .parent_names = (const char *[]){ "blsp1_uart2_apps_clk_src" },
1707 .num_parents = 1,
1708 .flags = CLK_SET_RATE_PARENT,
1709 .ops = &clk_branch2_ops,
1714 static struct clk_branch gcc_blsp1_qup3_spi_apps_clk = {
1715 .halt_reg = 0x1d004,
1716 .clkr = {
1717 .enable_reg = 0x1d004,
1718 .enable_mask = BIT(0),
1719 .hw.init = &(struct clk_init_data){
1720 .name = "gcc_blsp1_qup3_spi_apps_clk",
1721 .parent_names = (const char *[]){ "blsp1_qup3_spi_apps_clk_src" },
1722 .num_parents = 1,
1723 .flags = CLK_SET_RATE_PARENT,
1724 .ops = &clk_branch2_ops,
1729 static struct clk_branch gcc_blsp1_qup3_i2c_apps_clk = {
1730 .halt_reg = 0x1d008,
1731 .clkr = {
1732 .enable_reg = 0x1d008,
1733 .enable_mask = BIT(0),
1734 .hw.init = &(struct clk_init_data){
1735 .name = "gcc_blsp1_qup3_i2c_apps_clk",
1736 .parent_names = (const char *[]){ "blsp1_qup3_i2c_apps_clk_src" },
1737 .num_parents = 1,
1738 .flags = CLK_SET_RATE_PARENT,
1739 .ops = &clk_branch2_ops,
1744 static struct clk_branch gcc_blsp1_uart3_apps_clk = {
1745 .halt_reg = 0x1e004,
1746 .clkr = {
1747 .enable_reg = 0x1e004,
1748 .enable_mask = BIT(0),
1749 .hw.init = &(struct clk_init_data){
1750 .name = "gcc_blsp1_uart3_apps_clk",
1751 .parent_names = (const char *[]){ "blsp1_uart3_apps_clk_src" },
1752 .num_parents = 1,
1753 .flags = CLK_SET_RATE_PARENT,
1754 .ops = &clk_branch2_ops,
1759 static struct clk_branch gcc_blsp1_qup4_spi_apps_clk = {
1760 .halt_reg = 0x1f004,
1761 .clkr = {
1762 .enable_reg = 0x1f004,
1763 .enable_mask = BIT(0),
1764 .hw.init = &(struct clk_init_data){
1765 .name = "gcc_blsp1_qup4_spi_apps_clk",
1766 .parent_names = (const char *[]){ "blsp1_qup4_spi_apps_clk_src" },
1767 .num_parents = 1,
1768 .flags = CLK_SET_RATE_PARENT,
1769 .ops = &clk_branch2_ops,
1774 static struct clk_branch gcc_blsp1_qup4_i2c_apps_clk = {
1775 .halt_reg = 0x1f008,
1776 .clkr = {
1777 .enable_reg = 0x1f008,
1778 .enable_mask = BIT(0),
1779 .hw.init = &(struct clk_init_data){
1780 .name = "gcc_blsp1_qup4_i2c_apps_clk",
1781 .parent_names = (const char *[]){ "blsp1_qup4_i2c_apps_clk_src" },
1782 .num_parents = 1,
1783 .flags = CLK_SET_RATE_PARENT,
1784 .ops = &clk_branch2_ops,
1789 static struct clk_branch gcc_blsp1_uart4_apps_clk = {
1790 .halt_reg = 0x20004,
1791 .clkr = {
1792 .enable_reg = 0x20004,
1793 .enable_mask = BIT(0),
1794 .hw.init = &(struct clk_init_data){
1795 .name = "gcc_blsp1_uart4_apps_clk",
1796 .parent_names = (const char *[]){ "blsp1_uart4_apps_clk_src" },
1797 .num_parents = 1,
1798 .flags = CLK_SET_RATE_PARENT,
1799 .ops = &clk_branch2_ops,
1804 static struct clk_branch gcc_blsp1_qup5_spi_apps_clk = {
1805 .halt_reg = 0x21004,
1806 .clkr = {
1807 .enable_reg = 0x21004,
1808 .enable_mask = BIT(0),
1809 .hw.init = &(struct clk_init_data){
1810 .name = "gcc_blsp1_qup5_spi_apps_clk",
1811 .parent_names = (const char *[]){ "blsp1_qup5_spi_apps_clk_src" },
1812 .num_parents = 1,
1813 .flags = CLK_SET_RATE_PARENT,
1814 .ops = &clk_branch2_ops,
1819 static struct clk_branch gcc_blsp1_qup5_i2c_apps_clk = {
1820 .halt_reg = 0x21008,
1821 .clkr = {
1822 .enable_reg = 0x21008,
1823 .enable_mask = BIT(0),
1824 .hw.init = &(struct clk_init_data){
1825 .name = "gcc_blsp1_qup5_i2c_apps_clk",
1826 .parent_names = (const char *[]){ "blsp1_qup5_i2c_apps_clk_src" },
1827 .num_parents = 1,
1828 .flags = CLK_SET_RATE_PARENT,
1829 .ops = &clk_branch2_ops,
1834 static struct clk_branch gcc_blsp1_uart5_apps_clk = {
1835 .halt_reg = 0x22004,
1836 .clkr = {
1837 .enable_reg = 0x22004,
1838 .enable_mask = BIT(0),
1839 .hw.init = &(struct clk_init_data){
1840 .name = "gcc_blsp1_uart5_apps_clk",
1841 .parent_names = (const char *[]){ "blsp1_uart5_apps_clk_src" },
1842 .num_parents = 1,
1843 .flags = CLK_SET_RATE_PARENT,
1844 .ops = &clk_branch2_ops,
1849 static struct clk_branch gcc_blsp1_qup6_spi_apps_clk = {
1850 .halt_reg = 0x23004,
1851 .clkr = {
1852 .enable_reg = 0x23004,
1853 .enable_mask = BIT(0),
1854 .hw.init = &(struct clk_init_data){
1855 .name = "gcc_blsp1_qup6_spi_apps_clk",
1856 .parent_names = (const char *[]){ "blsp1_qup6_spi_apps_clk_src" },
1857 .num_parents = 1,
1858 .flags = CLK_SET_RATE_PARENT,
1859 .ops = &clk_branch2_ops,
1864 static struct clk_branch gcc_blsp1_qup6_i2c_apps_clk = {
1865 .halt_reg = 0x23008,
1866 .clkr = {
1867 .enable_reg = 0x23008,
1868 .enable_mask = BIT(0),
1869 .hw.init = &(struct clk_init_data){
1870 .name = "gcc_blsp1_qup6_i2c_apps_clk",
1871 .parent_names = (const char *[]){ "blsp1_qup6_i2c_apps_clk_src" },
1872 .num_parents = 1,
1873 .flags = CLK_SET_RATE_PARENT,
1874 .ops = &clk_branch2_ops,
1879 static struct clk_branch gcc_blsp1_uart6_apps_clk = {
1880 .halt_reg = 0x24004,
1881 .clkr = {
1882 .enable_reg = 0x24004,
1883 .enable_mask = BIT(0),
1884 .hw.init = &(struct clk_init_data){
1885 .name = "gcc_blsp1_uart6_apps_clk",
1886 .parent_names = (const char *[]){ "blsp1_uart6_apps_clk_src" },
1887 .num_parents = 1,
1888 .flags = CLK_SET_RATE_PARENT,
1889 .ops = &clk_branch2_ops,
1894 static struct clk_branch gcc_blsp2_ahb_clk = {
1895 .halt_reg = 0x25004,
1896 .halt_check = BRANCH_HALT_VOTED,
1897 .clkr = {
1898 .enable_reg = 0x52004,
1899 .enable_mask = BIT(15),
1900 .hw.init = &(struct clk_init_data){
1901 .name = "gcc_blsp2_ahb_clk",
1902 .parent_names = (const char *[]){ "periph_noc_clk_src" },
1903 .num_parents = 1,
1904 .flags = CLK_SET_RATE_PARENT,
1905 .ops = &clk_branch2_ops,
1910 static struct clk_branch gcc_blsp2_sleep_clk = {
1911 .halt_reg = 0x25008,
1912 .halt_check = BRANCH_HALT_VOTED,
1913 .clkr = {
1914 .enable_reg = 0x52004,
1915 .enable_mask = BIT(14),
1916 .hw.init = &(struct clk_init_data){
1917 .name = "gcc_blsp2_sleep_clk",
1918 .parent_names = (const char *[]){ "gcc_sleep_clk_src" },
1919 .num_parents = 1,
1920 .flags = CLK_SET_RATE_PARENT,
1921 .ops = &clk_branch2_ops,
1926 static struct clk_branch gcc_blsp2_qup1_spi_apps_clk = {
1927 .halt_reg = 0x26004,
1928 .clkr = {
1929 .enable_reg = 0x26004,
1930 .enable_mask = BIT(0),
1931 .hw.init = &(struct clk_init_data){
1932 .name = "gcc_blsp2_qup1_spi_apps_clk",
1933 .parent_names = (const char *[]){ "blsp2_qup1_spi_apps_clk_src" },
1934 .num_parents = 1,
1935 .flags = CLK_SET_RATE_PARENT,
1936 .ops = &clk_branch2_ops,
1941 static struct clk_branch gcc_blsp2_qup1_i2c_apps_clk = {
1942 .halt_reg = 0x26008,
1943 .clkr = {
1944 .enable_reg = 0x26008,
1945 .enable_mask = BIT(0),
1946 .hw.init = &(struct clk_init_data){
1947 .name = "gcc_blsp2_qup1_i2c_apps_clk",
1948 .parent_names = (const char *[]){ "blsp2_qup1_i2c_apps_clk_src" },
1949 .num_parents = 1,
1950 .flags = CLK_SET_RATE_PARENT,
1951 .ops = &clk_branch2_ops,
1956 static struct clk_branch gcc_blsp2_uart1_apps_clk = {
1957 .halt_reg = 0x27004,
1958 .clkr = {
1959 .enable_reg = 0x27004,
1960 .enable_mask = BIT(0),
1961 .hw.init = &(struct clk_init_data){
1962 .name = "gcc_blsp2_uart1_apps_clk",
1963 .parent_names = (const char *[]){ "blsp2_uart1_apps_clk_src" },
1964 .num_parents = 1,
1965 .flags = CLK_SET_RATE_PARENT,
1966 .ops = &clk_branch2_ops,
1971 static struct clk_branch gcc_blsp2_qup2_spi_apps_clk = {
1972 .halt_reg = 0x28004,
1973 .clkr = {
1974 .enable_reg = 0x28004,
1975 .enable_mask = BIT(0),
1976 .hw.init = &(struct clk_init_data){
1977 .name = "gcc_blsp2_qup2_spi_apps_clk",
1978 .parent_names = (const char *[]){ "blsp2_qup2_spi_apps_clk_src" },
1979 .num_parents = 1,
1980 .flags = CLK_SET_RATE_PARENT,
1981 .ops = &clk_branch2_ops,
1986 static struct clk_branch gcc_blsp2_qup2_i2c_apps_clk = {
1987 .halt_reg = 0x28008,
1988 .clkr = {
1989 .enable_reg = 0x28008,
1990 .enable_mask = BIT(0),
1991 .hw.init = &(struct clk_init_data){
1992 .name = "gcc_blsp2_qup2_i2c_apps_clk",
1993 .parent_names = (const char *[]){ "blsp2_qup2_i2c_apps_clk_src" },
1994 .num_parents = 1,
1995 .flags = CLK_SET_RATE_PARENT,
1996 .ops = &clk_branch2_ops,
2001 static struct clk_branch gcc_blsp2_uart2_apps_clk = {
2002 .halt_reg = 0x29004,
2003 .clkr = {
2004 .enable_reg = 0x29004,
2005 .enable_mask = BIT(0),
2006 .hw.init = &(struct clk_init_data){
2007 .name = "gcc_blsp2_uart2_apps_clk",
2008 .parent_names = (const char *[]){ "blsp2_uart2_apps_clk_src" },
2009 .num_parents = 1,
2010 .flags = CLK_SET_RATE_PARENT,
2011 .ops = &clk_branch2_ops,
2016 static struct clk_branch gcc_blsp2_qup3_spi_apps_clk = {
2017 .halt_reg = 0x2a004,
2018 .clkr = {
2019 .enable_reg = 0x2a004,
2020 .enable_mask = BIT(0),
2021 .hw.init = &(struct clk_init_data){
2022 .name = "gcc_blsp2_qup3_spi_apps_clk",
2023 .parent_names = (const char *[]){ "blsp2_qup3_spi_apps_clk_src" },
2024 .num_parents = 1,
2025 .flags = CLK_SET_RATE_PARENT,
2026 .ops = &clk_branch2_ops,
2031 static struct clk_branch gcc_blsp2_qup3_i2c_apps_clk = {
2032 .halt_reg = 0x2a008,
2033 .clkr = {
2034 .enable_reg = 0x2a008,
2035 .enable_mask = BIT(0),
2036 .hw.init = &(struct clk_init_data){
2037 .name = "gcc_blsp2_qup3_i2c_apps_clk",
2038 .parent_names = (const char *[]){ "blsp2_qup3_i2c_apps_clk_src" },
2039 .num_parents = 1,
2040 .flags = CLK_SET_RATE_PARENT,
2041 .ops = &clk_branch2_ops,
2046 static struct clk_branch gcc_blsp2_uart3_apps_clk = {
2047 .halt_reg = 0x2b004,
2048 .clkr = {
2049 .enable_reg = 0x2b004,
2050 .enable_mask = BIT(0),
2051 .hw.init = &(struct clk_init_data){
2052 .name = "gcc_blsp2_uart3_apps_clk",
2053 .parent_names = (const char *[]){ "blsp2_uart3_apps_clk_src" },
2054 .num_parents = 1,
2055 .flags = CLK_SET_RATE_PARENT,
2056 .ops = &clk_branch2_ops,
2061 static struct clk_branch gcc_blsp2_qup4_spi_apps_clk = {
2062 .halt_reg = 0x2c004,
2063 .clkr = {
2064 .enable_reg = 0x2c004,
2065 .enable_mask = BIT(0),
2066 .hw.init = &(struct clk_init_data){
2067 .name = "gcc_blsp2_qup4_spi_apps_clk",
2068 .parent_names = (const char *[]){ "blsp2_qup4_spi_apps_clk_src" },
2069 .num_parents = 1,
2070 .flags = CLK_SET_RATE_PARENT,
2071 .ops = &clk_branch2_ops,
2076 static struct clk_branch gcc_blsp2_qup4_i2c_apps_clk = {
2077 .halt_reg = 0x2c008,
2078 .clkr = {
2079 .enable_reg = 0x2c008,
2080 .enable_mask = BIT(0),
2081 .hw.init = &(struct clk_init_data){
2082 .name = "gcc_blsp2_qup4_i2c_apps_clk",
2083 .parent_names = (const char *[]){ "blsp2_qup4_i2c_apps_clk_src" },
2084 .num_parents = 1,
2085 .flags = CLK_SET_RATE_PARENT,
2086 .ops = &clk_branch2_ops,
2091 static struct clk_branch gcc_blsp2_uart4_apps_clk = {
2092 .halt_reg = 0x2d004,
2093 .clkr = {
2094 .enable_reg = 0x2d004,
2095 .enable_mask = BIT(0),
2096 .hw.init = &(struct clk_init_data){
2097 .name = "gcc_blsp2_uart4_apps_clk",
2098 .parent_names = (const char *[]){ "blsp2_uart4_apps_clk_src" },
2099 .num_parents = 1,
2100 .flags = CLK_SET_RATE_PARENT,
2101 .ops = &clk_branch2_ops,
2106 static struct clk_branch gcc_blsp2_qup5_spi_apps_clk = {
2107 .halt_reg = 0x2e004,
2108 .clkr = {
2109 .enable_reg = 0x2e004,
2110 .enable_mask = BIT(0),
2111 .hw.init = &(struct clk_init_data){
2112 .name = "gcc_blsp2_qup5_spi_apps_clk",
2113 .parent_names = (const char *[]){ "blsp2_qup5_spi_apps_clk_src" },
2114 .num_parents = 1,
2115 .flags = CLK_SET_RATE_PARENT,
2116 .ops = &clk_branch2_ops,
2121 static struct clk_branch gcc_blsp2_qup5_i2c_apps_clk = {
2122 .halt_reg = 0x2e008,
2123 .clkr = {
2124 .enable_reg = 0x2e008,
2125 .enable_mask = BIT(0),
2126 .hw.init = &(struct clk_init_data){
2127 .name = "gcc_blsp2_qup5_i2c_apps_clk",
2128 .parent_names = (const char *[]){ "blsp2_qup5_i2c_apps_clk_src" },
2129 .num_parents = 1,
2130 .flags = CLK_SET_RATE_PARENT,
2131 .ops = &clk_branch2_ops,
2136 static struct clk_branch gcc_blsp2_uart5_apps_clk = {
2137 .halt_reg = 0x2f004,
2138 .clkr = {
2139 .enable_reg = 0x2f004,
2140 .enable_mask = BIT(0),
2141 .hw.init = &(struct clk_init_data){
2142 .name = "gcc_blsp2_uart5_apps_clk",
2143 .parent_names = (const char *[]){ "blsp2_uart5_apps_clk_src" },
2144 .num_parents = 1,
2145 .flags = CLK_SET_RATE_PARENT,
2146 .ops = &clk_branch2_ops,
2151 static struct clk_branch gcc_blsp2_qup6_spi_apps_clk = {
2152 .halt_reg = 0x30004,
2153 .clkr = {
2154 .enable_reg = 0x30004,
2155 .enable_mask = BIT(0),
2156 .hw.init = &(struct clk_init_data){
2157 .name = "gcc_blsp2_qup6_spi_apps_clk",
2158 .parent_names = (const char *[]){ "blsp2_qup6_spi_apps_clk_src" },
2159 .num_parents = 1,
2160 .flags = CLK_SET_RATE_PARENT,
2161 .ops = &clk_branch2_ops,
2166 static struct clk_branch gcc_blsp2_qup6_i2c_apps_clk = {
2167 .halt_reg = 0x30008,
2168 .clkr = {
2169 .enable_reg = 0x30008,
2170 .enable_mask = BIT(0),
2171 .hw.init = &(struct clk_init_data){
2172 .name = "gcc_blsp2_qup6_i2c_apps_clk",
2173 .parent_names = (const char *[]){ "blsp2_qup6_i2c_apps_clk_src" },
2174 .num_parents = 1,
2175 .flags = CLK_SET_RATE_PARENT,
2176 .ops = &clk_branch2_ops,
2181 static struct clk_branch gcc_blsp2_uart6_apps_clk = {
2182 .halt_reg = 0x31004,
2183 .clkr = {
2184 .enable_reg = 0x31004,
2185 .enable_mask = BIT(0),
2186 .hw.init = &(struct clk_init_data){
2187 .name = "gcc_blsp2_uart6_apps_clk",
2188 .parent_names = (const char *[]){ "blsp2_uart6_apps_clk_src" },
2189 .num_parents = 1,
2190 .flags = CLK_SET_RATE_PARENT,
2191 .ops = &clk_branch2_ops,
2196 static struct clk_branch gcc_pdm_ahb_clk = {
2197 .halt_reg = 0x33004,
2198 .clkr = {
2199 .enable_reg = 0x33004,
2200 .enable_mask = BIT(0),
2201 .hw.init = &(struct clk_init_data){
2202 .name = "gcc_pdm_ahb_clk",
2203 .parent_names = (const char *[]){ "periph_noc_clk_src" },
2204 .num_parents = 1,
2205 .flags = CLK_SET_RATE_PARENT,
2206 .ops = &clk_branch2_ops,
2211 static struct clk_branch gcc_pdm2_clk = {
2212 .halt_reg = 0x3300c,
2213 .clkr = {
2214 .enable_reg = 0x3300c,
2215 .enable_mask = BIT(0),
2216 .hw.init = &(struct clk_init_data){
2217 .name = "gcc_pdm2_clk",
2218 .parent_names = (const char *[]){ "pdm2_clk_src" },
2219 .num_parents = 1,
2220 .flags = CLK_SET_RATE_PARENT,
2221 .ops = &clk_branch2_ops,
2226 static struct clk_branch gcc_prng_ahb_clk = {
2227 .halt_reg = 0x34004,
2228 .halt_check = BRANCH_HALT_VOTED,
2229 .clkr = {
2230 .enable_reg = 0x52004,
2231 .enable_mask = BIT(13),
2232 .hw.init = &(struct clk_init_data){
2233 .name = "gcc_prng_ahb_clk",
2234 .parent_names = (const char *[]){ "config_noc_clk_src" },
2235 .num_parents = 1,
2236 .flags = CLK_SET_RATE_PARENT,
2237 .ops = &clk_branch2_ops,
2242 static struct clk_branch gcc_tsif_ahb_clk = {
2243 .halt_reg = 0x36004,
2244 .clkr = {
2245 .enable_reg = 0x36004,
2246 .enable_mask = BIT(0),
2247 .hw.init = &(struct clk_init_data){
2248 .name = "gcc_tsif_ahb_clk",
2249 .parent_names = (const char *[]){ "periph_noc_clk_src" },
2250 .num_parents = 1,
2251 .flags = CLK_SET_RATE_PARENT,
2252 .ops = &clk_branch2_ops,
2257 static struct clk_branch gcc_tsif_ref_clk = {
2258 .halt_reg = 0x36008,
2259 .clkr = {
2260 .enable_reg = 0x36008,
2261 .enable_mask = BIT(0),
2262 .hw.init = &(struct clk_init_data){
2263 .name = "gcc_tsif_ref_clk",
2264 .parent_names = (const char *[]){ "tsif_ref_clk_src" },
2265 .num_parents = 1,
2266 .flags = CLK_SET_RATE_PARENT,
2267 .ops = &clk_branch2_ops,
2272 static struct clk_branch gcc_tsif_inactivity_timers_clk = {
2273 .halt_reg = 0x3600c,
2274 .clkr = {
2275 .enable_reg = 0x3600c,
2276 .enable_mask = BIT(0),
2277 .hw.init = &(struct clk_init_data){
2278 .name = "gcc_tsif_inactivity_timers_clk",
2279 .parent_names = (const char *[]){ "gcc_sleep_clk_src" },
2280 .num_parents = 1,
2281 .flags = CLK_SET_RATE_PARENT,
2282 .ops = &clk_branch2_ops,
2287 static struct clk_branch gcc_boot_rom_ahb_clk = {
2288 .halt_reg = 0x38004,
2289 .halt_check = BRANCH_HALT_VOTED,
2290 .clkr = {
2291 .enable_reg = 0x52004,
2292 .enable_mask = BIT(10),
2293 .hw.init = &(struct clk_init_data){
2294 .name = "gcc_boot_rom_ahb_clk",
2295 .parent_names = (const char *[]){ "config_noc_clk_src" },
2296 .num_parents = 1,
2297 .flags = CLK_SET_RATE_PARENT,
2298 .ops = &clk_branch2_ops,
2303 static struct clk_branch gcc_bimc_gfx_clk = {
2304 .halt_reg = 0x46018,
2305 .clkr = {
2306 .enable_reg = 0x46018,
2307 .enable_mask = BIT(0),
2308 .hw.init = &(struct clk_init_data){
2309 .name = "gcc_bimc_gfx_clk",
2310 .flags = CLK_SET_RATE_PARENT,
2311 .ops = &clk_branch2_ops,
2316 static struct clk_branch gcc_hmss_rbcpr_clk = {
2317 .halt_reg = 0x4800c,
2318 .clkr = {
2319 .enable_reg = 0x4800c,
2320 .enable_mask = BIT(0),
2321 .hw.init = &(struct clk_init_data){
2322 .name = "gcc_hmss_rbcpr_clk",
2323 .parent_names = (const char *[]){ "hmss_rbcpr_clk_src" },
2324 .num_parents = 1,
2325 .flags = CLK_SET_RATE_PARENT,
2326 .ops = &clk_branch2_ops,
2331 static struct clk_branch gcc_gp1_clk = {
2332 .halt_reg = 0x64000,
2333 .clkr = {
2334 .enable_reg = 0x64000,
2335 .enable_mask = BIT(0),
2336 .hw.init = &(struct clk_init_data){
2337 .name = "gcc_gp1_clk",
2338 .parent_names = (const char *[]){ "gp1_clk_src" },
2339 .num_parents = 1,
2340 .flags = CLK_SET_RATE_PARENT,
2341 .ops = &clk_branch2_ops,
2346 static struct clk_branch gcc_gp2_clk = {
2347 .halt_reg = 0x65000,
2348 .clkr = {
2349 .enable_reg = 0x65000,
2350 .enable_mask = BIT(0),
2351 .hw.init = &(struct clk_init_data){
2352 .name = "gcc_gp2_clk",
2353 .parent_names = (const char *[]){ "gp2_clk_src" },
2354 .num_parents = 1,
2355 .flags = CLK_SET_RATE_PARENT,
2356 .ops = &clk_branch2_ops,
2361 static struct clk_branch gcc_gp3_clk = {
2362 .halt_reg = 0x66000,
2363 .clkr = {
2364 .enable_reg = 0x66000,
2365 .enable_mask = BIT(0),
2366 .hw.init = &(struct clk_init_data){
2367 .name = "gcc_gp3_clk",
2368 .parent_names = (const char *[]){ "gp3_clk_src" },
2369 .num_parents = 1,
2370 .flags = CLK_SET_RATE_PARENT,
2371 .ops = &clk_branch2_ops,
2376 static struct clk_branch gcc_pcie_0_slv_axi_clk = {
2377 .halt_reg = 0x6b008,
2378 .clkr = {
2379 .enable_reg = 0x6b008,
2380 .enable_mask = BIT(0),
2381 .hw.init = &(struct clk_init_data){
2382 .name = "gcc_pcie_0_slv_axi_clk",
2383 .parent_names = (const char *[]){ "system_noc_clk_src" },
2384 .num_parents = 1,
2385 .flags = CLK_SET_RATE_PARENT,
2386 .ops = &clk_branch2_ops,
2391 static struct clk_branch gcc_pcie_0_mstr_axi_clk = {
2392 .halt_reg = 0x6b00c,
2393 .clkr = {
2394 .enable_reg = 0x6b00c,
2395 .enable_mask = BIT(0),
2396 .hw.init = &(struct clk_init_data){
2397 .name = "gcc_pcie_0_mstr_axi_clk",
2398 .parent_names = (const char *[]){ "system_noc_clk_src" },
2399 .num_parents = 1,
2400 .flags = CLK_SET_RATE_PARENT,
2401 .ops = &clk_branch2_ops,
2406 static struct clk_branch gcc_pcie_0_cfg_ahb_clk = {
2407 .halt_reg = 0x6b010,
2408 .clkr = {
2409 .enable_reg = 0x6b010,
2410 .enable_mask = BIT(0),
2411 .hw.init = &(struct clk_init_data){
2412 .name = "gcc_pcie_0_cfg_ahb_clk",
2413 .parent_names = (const char *[]){ "config_noc_clk_src" },
2414 .num_parents = 1,
2415 .flags = CLK_SET_RATE_PARENT,
2416 .ops = &clk_branch2_ops,
2421 static struct clk_branch gcc_pcie_0_aux_clk = {
2422 .halt_reg = 0x6b014,
2423 .clkr = {
2424 .enable_reg = 0x6b014,
2425 .enable_mask = BIT(0),
2426 .hw.init = &(struct clk_init_data){
2427 .name = "gcc_pcie_0_aux_clk",
2428 .parent_names = (const char *[]){ "pcie_aux_clk_src" },
2429 .num_parents = 1,
2430 .flags = CLK_SET_RATE_PARENT,
2431 .ops = &clk_branch2_ops,
2436 static struct clk_branch gcc_pcie_0_pipe_clk = {
2437 .halt_reg = 0x6b018,
2438 .halt_check = BRANCH_HALT_SKIP,
2439 .clkr = {
2440 .enable_reg = 0x6b018,
2441 .enable_mask = BIT(0),
2442 .hw.init = &(struct clk_init_data){
2443 .name = "gcc_pcie_0_pipe_clk",
2444 .parent_names = (const char *[]){ "pcie_0_pipe_clk_src" },
2445 .num_parents = 1,
2446 .flags = CLK_SET_RATE_PARENT,
2447 .ops = &clk_branch2_ops,
2452 static struct clk_branch gcc_pcie_1_slv_axi_clk = {
2453 .halt_reg = 0x6d008,
2454 .clkr = {
2455 .enable_reg = 0x6d008,
2456 .enable_mask = BIT(0),
2457 .hw.init = &(struct clk_init_data){
2458 .name = "gcc_pcie_1_slv_axi_clk",
2459 .parent_names = (const char *[]){ "system_noc_clk_src" },
2460 .num_parents = 1,
2461 .flags = CLK_SET_RATE_PARENT,
2462 .ops = &clk_branch2_ops,
2467 static struct clk_branch gcc_pcie_1_mstr_axi_clk = {
2468 .halt_reg = 0x6d00c,
2469 .clkr = {
2470 .enable_reg = 0x6d00c,
2471 .enable_mask = BIT(0),
2472 .hw.init = &(struct clk_init_data){
2473 .name = "gcc_pcie_1_mstr_axi_clk",
2474 .parent_names = (const char *[]){ "system_noc_clk_src" },
2475 .num_parents = 1,
2476 .flags = CLK_SET_RATE_PARENT,
2477 .ops = &clk_branch2_ops,
2482 static struct clk_branch gcc_pcie_1_cfg_ahb_clk = {
2483 .halt_reg = 0x6d010,
2484 .clkr = {
2485 .enable_reg = 0x6d010,
2486 .enable_mask = BIT(0),
2487 .hw.init = &(struct clk_init_data){
2488 .name = "gcc_pcie_1_cfg_ahb_clk",
2489 .parent_names = (const char *[]){ "config_noc_clk_src" },
2490 .num_parents = 1,
2491 .flags = CLK_SET_RATE_PARENT,
2492 .ops = &clk_branch2_ops,
2497 static struct clk_branch gcc_pcie_1_aux_clk = {
2498 .halt_reg = 0x6d014,
2499 .clkr = {
2500 .enable_reg = 0x6d014,
2501 .enable_mask = BIT(0),
2502 .hw.init = &(struct clk_init_data){
2503 .name = "gcc_pcie_1_aux_clk",
2504 .parent_names = (const char *[]){ "pcie_aux_clk_src" },
2505 .num_parents = 1,
2506 .flags = CLK_SET_RATE_PARENT,
2507 .ops = &clk_branch2_ops,
2512 static struct clk_branch gcc_pcie_1_pipe_clk = {
2513 .halt_reg = 0x6d018,
2514 .halt_check = BRANCH_HALT_SKIP,
2515 .clkr = {
2516 .enable_reg = 0x6d018,
2517 .enable_mask = BIT(0),
2518 .hw.init = &(struct clk_init_data){
2519 .name = "gcc_pcie_1_pipe_clk",
2520 .parent_names = (const char *[]){ "pcie_1_pipe_clk_src" },
2521 .num_parents = 1,
2522 .flags = CLK_SET_RATE_PARENT,
2523 .ops = &clk_branch2_ops,
2528 static struct clk_branch gcc_pcie_2_slv_axi_clk = {
2529 .halt_reg = 0x6e008,
2530 .clkr = {
2531 .enable_reg = 0x6e008,
2532 .enable_mask = BIT(0),
2533 .hw.init = &(struct clk_init_data){
2534 .name = "gcc_pcie_2_slv_axi_clk",
2535 .parent_names = (const char *[]){ "system_noc_clk_src" },
2536 .num_parents = 1,
2537 .flags = CLK_SET_RATE_PARENT,
2538 .ops = &clk_branch2_ops,
2543 static struct clk_branch gcc_pcie_2_mstr_axi_clk = {
2544 .halt_reg = 0x6e00c,
2545 .clkr = {
2546 .enable_reg = 0x6e00c,
2547 .enable_mask = BIT(0),
2548 .hw.init = &(struct clk_init_data){
2549 .name = "gcc_pcie_2_mstr_axi_clk",
2550 .parent_names = (const char *[]){ "system_noc_clk_src" },
2551 .num_parents = 1,
2552 .flags = CLK_SET_RATE_PARENT,
2553 .ops = &clk_branch2_ops,
2558 static struct clk_branch gcc_pcie_2_cfg_ahb_clk = {
2559 .halt_reg = 0x6e010,
2560 .clkr = {
2561 .enable_reg = 0x6e010,
2562 .enable_mask = BIT(0),
2563 .hw.init = &(struct clk_init_data){
2564 .name = "gcc_pcie_2_cfg_ahb_clk",
2565 .parent_names = (const char *[]){ "config_noc_clk_src" },
2566 .num_parents = 1,
2567 .flags = CLK_SET_RATE_PARENT,
2568 .ops = &clk_branch2_ops,
2573 static struct clk_branch gcc_pcie_2_aux_clk = {
2574 .halt_reg = 0x6e014,
2575 .clkr = {
2576 .enable_reg = 0x6e014,
2577 .enable_mask = BIT(0),
2578 .hw.init = &(struct clk_init_data){
2579 .name = "gcc_pcie_2_aux_clk",
2580 .parent_names = (const char *[]){ "pcie_aux_clk_src" },
2581 .num_parents = 1,
2582 .flags = CLK_SET_RATE_PARENT,
2583 .ops = &clk_branch2_ops,
2588 static struct clk_branch gcc_pcie_2_pipe_clk = {
2589 .halt_reg = 0x6e018,
2590 .halt_check = BRANCH_HALT_SKIP,
2591 .clkr = {
2592 .enable_reg = 0x6e018,
2593 .enable_mask = BIT(0),
2594 .hw.init = &(struct clk_init_data){
2595 .name = "gcc_pcie_2_pipe_clk",
2596 .parent_names = (const char *[]){ "pcie_2_pipe_clk_src" },
2597 .num_parents = 1,
2598 .flags = CLK_SET_RATE_PARENT,
2599 .ops = &clk_branch2_ops,
2604 static struct clk_branch gcc_pcie_phy_cfg_ahb_clk = {
2605 .halt_reg = 0x6f004,
2606 .clkr = {
2607 .enable_reg = 0x6f004,
2608 .enable_mask = BIT(0),
2609 .hw.init = &(struct clk_init_data){
2610 .name = "gcc_pcie_phy_cfg_ahb_clk",
2611 .parent_names = (const char *[]){ "config_noc_clk_src" },
2612 .num_parents = 1,
2613 .flags = CLK_SET_RATE_PARENT,
2614 .ops = &clk_branch2_ops,
2619 static struct clk_branch gcc_pcie_phy_aux_clk = {
2620 .halt_reg = 0x6f008,
2621 .clkr = {
2622 .enable_reg = 0x6f008,
2623 .enable_mask = BIT(0),
2624 .hw.init = &(struct clk_init_data){
2625 .name = "gcc_pcie_phy_aux_clk",
2626 .parent_names = (const char *[]){ "pcie_aux_clk_src" },
2627 .num_parents = 1,
2628 .flags = CLK_SET_RATE_PARENT,
2629 .ops = &clk_branch2_ops,
2634 static struct clk_branch gcc_ufs_axi_clk = {
2635 .halt_reg = 0x75008,
2636 .clkr = {
2637 .enable_reg = 0x75008,
2638 .enable_mask = BIT(0),
2639 .hw.init = &(struct clk_init_data){
2640 .name = "gcc_ufs_axi_clk",
2641 .parent_names = (const char *[]){ "ufs_axi_clk_src" },
2642 .num_parents = 1,
2643 .flags = CLK_SET_RATE_PARENT,
2644 .ops = &clk_branch2_ops,
2649 static struct clk_branch gcc_ufs_ahb_clk = {
2650 .halt_reg = 0x7500c,
2651 .clkr = {
2652 .enable_reg = 0x7500c,
2653 .enable_mask = BIT(0),
2654 .hw.init = &(struct clk_init_data){
2655 .name = "gcc_ufs_ahb_clk",
2656 .parent_names = (const char *[]){ "config_noc_clk_src" },
2657 .num_parents = 1,
2658 .flags = CLK_SET_RATE_PARENT,
2659 .ops = &clk_branch2_ops,
2664 static struct clk_fixed_factor ufs_tx_cfg_clk_src = {
2665 .mult = 1,
2666 .div = 16,
2667 .hw.init = &(struct clk_init_data){
2668 .name = "ufs_tx_cfg_clk_src",
2669 .parent_names = (const char *[]){ "ufs_axi_clk_src" },
2670 .num_parents = 1,
2671 .flags = CLK_SET_RATE_PARENT,
2672 .ops = &clk_fixed_factor_ops,
2676 static struct clk_branch gcc_ufs_tx_cfg_clk = {
2677 .halt_reg = 0x75010,
2678 .clkr = {
2679 .enable_reg = 0x75010,
2680 .enable_mask = BIT(0),
2681 .hw.init = &(struct clk_init_data){
2682 .name = "gcc_ufs_tx_cfg_clk",
2683 .parent_names = (const char *[]){ "ufs_tx_cfg_clk_src" },
2684 .num_parents = 1,
2685 .flags = CLK_SET_RATE_PARENT,
2686 .ops = &clk_branch2_ops,
2691 static struct clk_fixed_factor ufs_rx_cfg_clk_src = {
2692 .mult = 1,
2693 .div = 16,
2694 .hw.init = &(struct clk_init_data){
2695 .name = "ufs_rx_cfg_clk_src",
2696 .parent_names = (const char *[]){ "ufs_axi_clk_src" },
2697 .num_parents = 1,
2698 .flags = CLK_SET_RATE_PARENT,
2699 .ops = &clk_fixed_factor_ops,
2703 static struct clk_branch gcc_hlos1_vote_lpass_core_smmu_clk = {
2704 .halt_reg = 0x7d010,
2705 .halt_check = BRANCH_HALT_VOTED,
2706 .clkr = {
2707 .enable_reg = 0x7d010,
2708 .enable_mask = BIT(0),
2709 .hw.init = &(struct clk_init_data){
2710 .name = "hlos1_vote_lpass_core_smmu_clk",
2711 .ops = &clk_branch2_ops,
2716 static struct clk_branch gcc_hlos1_vote_lpass_adsp_smmu_clk = {
2717 .halt_reg = 0x7d014,
2718 .halt_check = BRANCH_HALT_VOTED,
2719 .clkr = {
2720 .enable_reg = 0x7d014,
2721 .enable_mask = BIT(0),
2722 .hw.init = &(struct clk_init_data){
2723 .name = "hlos1_vote_lpass_adsp_smmu_clk",
2724 .ops = &clk_branch2_ops,
2729 static struct clk_branch gcc_ufs_rx_cfg_clk = {
2730 .halt_reg = 0x75014,
2731 .clkr = {
2732 .enable_reg = 0x75014,
2733 .enable_mask = BIT(0),
2734 .hw.init = &(struct clk_init_data){
2735 .name = "gcc_ufs_rx_cfg_clk",
2736 .parent_names = (const char *[]){ "ufs_rx_cfg_clk_src" },
2737 .num_parents = 1,
2738 .flags = CLK_SET_RATE_PARENT,
2739 .ops = &clk_branch2_ops,
2744 static struct clk_branch gcc_ufs_tx_symbol_0_clk = {
2745 .halt_reg = 0x75018,
2746 .halt_check = BRANCH_HALT_SKIP,
2747 .clkr = {
2748 .enable_reg = 0x75018,
2749 .enable_mask = BIT(0),
2750 .hw.init = &(struct clk_init_data){
2751 .name = "gcc_ufs_tx_symbol_0_clk",
2752 .parent_names = (const char *[]){ "ufs_tx_symbol_0_clk_src" },
2753 .num_parents = 1,
2754 .flags = CLK_SET_RATE_PARENT,
2755 .ops = &clk_branch2_ops,
2760 static struct clk_branch gcc_ufs_rx_symbol_0_clk = {
2761 .halt_reg = 0x7501c,
2762 .halt_check = BRANCH_HALT_SKIP,
2763 .clkr = {
2764 .enable_reg = 0x7501c,
2765 .enable_mask = BIT(0),
2766 .hw.init = &(struct clk_init_data){
2767 .name = "gcc_ufs_rx_symbol_0_clk",
2768 .parent_names = (const char *[]){ "ufs_rx_symbol_0_clk_src" },
2769 .num_parents = 1,
2770 .flags = CLK_SET_RATE_PARENT,
2771 .ops = &clk_branch2_ops,
2776 static struct clk_branch gcc_ufs_rx_symbol_1_clk = {
2777 .halt_reg = 0x75020,
2778 .halt_check = BRANCH_HALT_SKIP,
2779 .clkr = {
2780 .enable_reg = 0x75020,
2781 .enable_mask = BIT(0),
2782 .hw.init = &(struct clk_init_data){
2783 .name = "gcc_ufs_rx_symbol_1_clk",
2784 .parent_names = (const char *[]){ "ufs_rx_symbol_1_clk_src" },
2785 .num_parents = 1,
2786 .flags = CLK_SET_RATE_PARENT,
2787 .ops = &clk_branch2_ops,
2792 static struct clk_fixed_factor ufs_ice_core_postdiv_clk_src = {
2793 .mult = 1,
2794 .div = 2,
2795 .hw.init = &(struct clk_init_data){
2796 .name = "ufs_ice_core_postdiv_clk_src",
2797 .parent_names = (const char *[]){ "ufs_ice_core_clk_src" },
2798 .num_parents = 1,
2799 .flags = CLK_SET_RATE_PARENT,
2800 .ops = &clk_fixed_factor_ops,
2804 static struct clk_branch gcc_ufs_unipro_core_clk = {
2805 .halt_reg = 0x7600c,
2806 .clkr = {
2807 .enable_reg = 0x7600c,
2808 .enable_mask = BIT(0),
2809 .hw.init = &(struct clk_init_data){
2810 .name = "gcc_ufs_unipro_core_clk",
2811 .parent_names = (const char *[]){ "ufs_ice_core_postdiv_clk_src" },
2812 .num_parents = 1,
2813 .flags = CLK_SET_RATE_PARENT,
2814 .ops = &clk_branch2_ops,
2819 static struct clk_branch gcc_ufs_ice_core_clk = {
2820 .halt_reg = 0x76010,
2821 .clkr = {
2822 .enable_reg = 0x76010,
2823 .enable_mask = BIT(0),
2824 .hw.init = &(struct clk_init_data){
2825 .name = "gcc_ufs_ice_core_clk",
2826 .parent_names = (const char *[]){ "ufs_ice_core_clk_src" },
2827 .num_parents = 1,
2828 .flags = CLK_SET_RATE_PARENT,
2829 .ops = &clk_branch2_ops,
2834 static struct clk_branch gcc_ufs_sys_clk_core_clk = {
2835 .halt_check = BRANCH_HALT_DELAY,
2836 .clkr = {
2837 .enable_reg = 0x76030,
2838 .enable_mask = BIT(0),
2839 .hw.init = &(struct clk_init_data){
2840 .name = "gcc_ufs_sys_clk_core_clk",
2841 .ops = &clk_branch2_ops,
2846 static struct clk_branch gcc_ufs_tx_symbol_clk_core_clk = {
2847 .halt_check = BRANCH_HALT_DELAY,
2848 .clkr = {
2849 .enable_reg = 0x76034,
2850 .enable_mask = BIT(0),
2851 .hw.init = &(struct clk_init_data){
2852 .name = "gcc_ufs_tx_symbol_clk_core_clk",
2853 .ops = &clk_branch2_ops,
2858 static struct clk_branch gcc_aggre0_snoc_axi_clk = {
2859 .halt_reg = 0x81008,
2860 .clkr = {
2861 .enable_reg = 0x81008,
2862 .enable_mask = BIT(0),
2863 .hw.init = &(struct clk_init_data){
2864 .name = "gcc_aggre0_snoc_axi_clk",
2865 .parent_names = (const char *[]){ "system_noc_clk_src" },
2866 .num_parents = 1,
2867 .flags = CLK_SET_RATE_PARENT | CLK_IS_CRITICAL,
2868 .ops = &clk_branch2_ops,
2873 static struct clk_branch gcc_aggre0_cnoc_ahb_clk = {
2874 .halt_reg = 0x8100c,
2875 .clkr = {
2876 .enable_reg = 0x8100c,
2877 .enable_mask = BIT(0),
2878 .hw.init = &(struct clk_init_data){
2879 .name = "gcc_aggre0_cnoc_ahb_clk",
2880 .parent_names = (const char *[]){ "config_noc_clk_src" },
2881 .num_parents = 1,
2882 .flags = CLK_SET_RATE_PARENT | CLK_IS_CRITICAL,
2883 .ops = &clk_branch2_ops,
2888 static struct clk_branch gcc_smmu_aggre0_axi_clk = {
2889 .halt_reg = 0x81014,
2890 .clkr = {
2891 .enable_reg = 0x81014,
2892 .enable_mask = BIT(0),
2893 .hw.init = &(struct clk_init_data){
2894 .name = "gcc_smmu_aggre0_axi_clk",
2895 .parent_names = (const char *[]){ "system_noc_clk_src" },
2896 .num_parents = 1,
2897 .flags = CLK_SET_RATE_PARENT | CLK_IS_CRITICAL,
2898 .ops = &clk_branch2_ops,
2903 static struct clk_branch gcc_smmu_aggre0_ahb_clk = {
2904 .halt_reg = 0x81018,
2905 .clkr = {
2906 .enable_reg = 0x81018,
2907 .enable_mask = BIT(0),
2908 .hw.init = &(struct clk_init_data){
2909 .name = "gcc_smmu_aggre0_ahb_clk",
2910 .parent_names = (const char *[]){ "config_noc_clk_src" },
2911 .num_parents = 1,
2912 .flags = CLK_SET_RATE_PARENT | CLK_IS_CRITICAL,
2913 .ops = &clk_branch2_ops,
2918 static struct clk_branch gcc_aggre2_ufs_axi_clk = {
2919 .halt_reg = 0x83014,
2920 .clkr = {
2921 .enable_reg = 0x83014,
2922 .enable_mask = BIT(0),
2923 .hw.init = &(struct clk_init_data){
2924 .name = "gcc_aggre2_ufs_axi_clk",
2925 .parent_names = (const char *[]){ "ufs_axi_clk_src" },
2926 .num_parents = 1,
2927 .flags = CLK_SET_RATE_PARENT,
2928 .ops = &clk_branch2_ops,
2933 static struct clk_branch gcc_aggre2_usb3_axi_clk = {
2934 .halt_reg = 0x83018,
2935 .clkr = {
2936 .enable_reg = 0x83018,
2937 .enable_mask = BIT(0),
2938 .hw.init = &(struct clk_init_data){
2939 .name = "gcc_aggre2_usb3_axi_clk",
2940 .parent_names = (const char *[]){ "usb30_master_clk_src" },
2941 .num_parents = 1,
2942 .flags = CLK_SET_RATE_PARENT,
2943 .ops = &clk_branch2_ops,
2948 static struct clk_branch gcc_qspi_ahb_clk = {
2949 .halt_reg = 0x8b004,
2950 .clkr = {
2951 .enable_reg = 0x8b004,
2952 .enable_mask = BIT(0),
2953 .hw.init = &(struct clk_init_data){
2954 .name = "gcc_qspi_ahb_clk",
2955 .parent_names = (const char *[]){ "periph_noc_clk_src" },
2956 .num_parents = 1,
2957 .flags = CLK_SET_RATE_PARENT,
2958 .ops = &clk_branch2_ops,
2963 static struct clk_branch gcc_qspi_ser_clk = {
2964 .halt_reg = 0x8b008,
2965 .clkr = {
2966 .enable_reg = 0x8b008,
2967 .enable_mask = BIT(0),
2968 .hw.init = &(struct clk_init_data){
2969 .name = "gcc_qspi_ser_clk",
2970 .parent_names = (const char *[]){ "qspi_ser_clk_src" },
2971 .num_parents = 1,
2972 .flags = CLK_SET_RATE_PARENT,
2973 .ops = &clk_branch2_ops,
2978 static struct clk_branch gcc_usb3_clkref_clk = {
2979 .halt_reg = 0x8800C,
2980 .clkr = {
2981 .enable_reg = 0x8800C,
2982 .enable_mask = BIT(0),
2983 .hw.init = &(struct clk_init_data){
2984 .name = "gcc_usb3_clkref_clk",
2985 .parent_names = (const char *[]){ "xo" },
2986 .num_parents = 1,
2987 .ops = &clk_branch2_ops,
2992 static struct clk_branch gcc_hdmi_clkref_clk = {
2993 .halt_reg = 0x88000,
2994 .clkr = {
2995 .enable_reg = 0x88000,
2996 .enable_mask = BIT(0),
2997 .hw.init = &(struct clk_init_data){
2998 .name = "gcc_hdmi_clkref_clk",
2999 .parent_names = (const char *[]){ "xo" },
3000 .num_parents = 1,
3001 .ops = &clk_branch2_ops,
3006 static struct clk_branch gcc_ufs_clkref_clk = {
3007 .halt_reg = 0x88008,
3008 .clkr = {
3009 .enable_reg = 0x88008,
3010 .enable_mask = BIT(0),
3011 .hw.init = &(struct clk_init_data){
3012 .name = "gcc_ufs_clkref_clk",
3013 .parent_names = (const char *[]){ "xo" },
3014 .num_parents = 1,
3015 .ops = &clk_branch2_ops,
3020 static struct clk_branch gcc_pcie_clkref_clk = {
3021 .halt_reg = 0x88010,
3022 .clkr = {
3023 .enable_reg = 0x88010,
3024 .enable_mask = BIT(0),
3025 .hw.init = &(struct clk_init_data){
3026 .name = "gcc_pcie_clkref_clk",
3027 .parent_names = (const char *[]){ "xo" },
3028 .num_parents = 1,
3029 .ops = &clk_branch2_ops,
3034 static struct clk_branch gcc_rx2_usb2_clkref_clk = {
3035 .halt_reg = 0x88014,
3036 .clkr = {
3037 .enable_reg = 0x88014,
3038 .enable_mask = BIT(0),
3039 .hw.init = &(struct clk_init_data){
3040 .name = "gcc_rx2_usb2_clkref_clk",
3041 .parent_names = (const char *[]){ "xo" },
3042 .num_parents = 1,
3043 .ops = &clk_branch2_ops,
3048 static struct clk_branch gcc_rx1_usb2_clkref_clk = {
3049 .halt_reg = 0x88018,
3050 .clkr = {
3051 .enable_reg = 0x88018,
3052 .enable_mask = BIT(0),
3053 .hw.init = &(struct clk_init_data){
3054 .name = "gcc_rx1_usb2_clkref_clk",
3055 .parent_names = (const char *[]){ "xo" },
3056 .num_parents = 1,
3057 .ops = &clk_branch2_ops,
3062 static struct clk_hw *gcc_msm8996_hws[] = {
3063 &xo.hw,
3064 &gpll0_early_div.hw,
3065 &ufs_tx_cfg_clk_src.hw,
3066 &ufs_rx_cfg_clk_src.hw,
3067 &ufs_ice_core_postdiv_clk_src.hw,
3070 static struct gdsc aggre0_noc_gdsc = {
3071 .gdscr = 0x81004,
3072 .gds_hw_ctrl = 0x81028,
3073 .pd = {
3074 .name = "aggre0_noc",
3076 .pwrsts = PWRSTS_OFF_ON,
3077 .flags = VOTABLE | ALWAYS_ON,
3080 static struct gdsc hlos1_vote_aggre0_noc_gdsc = {
3081 .gdscr = 0x7d024,
3082 .pd = {
3083 .name = "hlos1_vote_aggre0_noc",
3085 .pwrsts = PWRSTS_OFF_ON,
3086 .flags = VOTABLE,
3089 static struct gdsc hlos1_vote_lpass_adsp_gdsc = {
3090 .gdscr = 0x7d034,
3091 .pd = {
3092 .name = "hlos1_vote_lpass_adsp",
3094 .pwrsts = PWRSTS_OFF_ON,
3095 .flags = VOTABLE,
3098 static struct gdsc hlos1_vote_lpass_core_gdsc = {
3099 .gdscr = 0x7d038,
3100 .pd = {
3101 .name = "hlos1_vote_lpass_core",
3103 .pwrsts = PWRSTS_OFF_ON,
3104 .flags = VOTABLE,
3107 static struct gdsc usb30_gdsc = {
3108 .gdscr = 0xf004,
3109 .pd = {
3110 .name = "usb30",
3112 .pwrsts = PWRSTS_OFF_ON,
3115 static struct gdsc pcie0_gdsc = {
3116 .gdscr = 0x6b004,
3117 .pd = {
3118 .name = "pcie0",
3120 .pwrsts = PWRSTS_OFF_ON,
3123 static struct gdsc pcie1_gdsc = {
3124 .gdscr = 0x6d004,
3125 .pd = {
3126 .name = "pcie1",
3128 .pwrsts = PWRSTS_OFF_ON,
3131 static struct gdsc pcie2_gdsc = {
3132 .gdscr = 0x6e004,
3133 .pd = {
3134 .name = "pcie2",
3136 .pwrsts = PWRSTS_OFF_ON,
3139 static struct gdsc ufs_gdsc = {
3140 .gdscr = 0x75004,
3141 .pd = {
3142 .name = "ufs",
3144 .pwrsts = PWRSTS_OFF_ON,
3147 static struct clk_regmap *gcc_msm8996_clocks[] = {
3148 [GPLL0_EARLY] = &gpll0_early.clkr,
3149 [GPLL0] = &gpll0.clkr,
3150 [GPLL4_EARLY] = &gpll4_early.clkr,
3151 [GPLL4] = &gpll4.clkr,
3152 [SYSTEM_NOC_CLK_SRC] = &system_noc_clk_src.clkr,
3153 [CONFIG_NOC_CLK_SRC] = &config_noc_clk_src.clkr,
3154 [PERIPH_NOC_CLK_SRC] = &periph_noc_clk_src.clkr,
3155 [USB30_MASTER_CLK_SRC] = &usb30_master_clk_src.clkr,
3156 [USB30_MOCK_UTMI_CLK_SRC] = &usb30_mock_utmi_clk_src.clkr,
3157 [USB3_PHY_AUX_CLK_SRC] = &usb3_phy_aux_clk_src.clkr,
3158 [USB20_MASTER_CLK_SRC] = &usb20_master_clk_src.clkr,
3159 [USB20_MOCK_UTMI_CLK_SRC] = &usb20_mock_utmi_clk_src.clkr,
3160 [SDCC1_APPS_CLK_SRC] = &sdcc1_apps_clk_src.clkr,
3161 [SDCC1_ICE_CORE_CLK_SRC] = &sdcc1_ice_core_clk_src.clkr,
3162 [SDCC2_APPS_CLK_SRC] = &sdcc2_apps_clk_src.clkr,
3163 [SDCC3_APPS_CLK_SRC] = &sdcc3_apps_clk_src.clkr,
3164 [SDCC4_APPS_CLK_SRC] = &sdcc4_apps_clk_src.clkr,
3165 [BLSP1_QUP1_SPI_APPS_CLK_SRC] = &blsp1_qup1_spi_apps_clk_src.clkr,
3166 [BLSP1_QUP1_I2C_APPS_CLK_SRC] = &blsp1_qup1_i2c_apps_clk_src.clkr,
3167 [BLSP1_UART1_APPS_CLK_SRC] = &blsp1_uart1_apps_clk_src.clkr,
3168 [BLSP1_QUP2_SPI_APPS_CLK_SRC] = &blsp1_qup2_spi_apps_clk_src.clkr,
3169 [BLSP1_QUP2_I2C_APPS_CLK_SRC] = &blsp1_qup2_i2c_apps_clk_src.clkr,
3170 [BLSP1_UART2_APPS_CLK_SRC] = &blsp1_uart2_apps_clk_src.clkr,
3171 [BLSP1_QUP3_SPI_APPS_CLK_SRC] = &blsp1_qup3_spi_apps_clk_src.clkr,
3172 [BLSP1_QUP3_I2C_APPS_CLK_SRC] = &blsp1_qup3_i2c_apps_clk_src.clkr,
3173 [BLSP1_UART3_APPS_CLK_SRC] = &blsp1_uart3_apps_clk_src.clkr,
3174 [BLSP1_QUP4_SPI_APPS_CLK_SRC] = &blsp1_qup4_spi_apps_clk_src.clkr,
3175 [BLSP1_QUP4_I2C_APPS_CLK_SRC] = &blsp1_qup4_i2c_apps_clk_src.clkr,
3176 [BLSP1_UART4_APPS_CLK_SRC] = &blsp1_uart4_apps_clk_src.clkr,
3177 [BLSP1_QUP5_SPI_APPS_CLK_SRC] = &blsp1_qup5_spi_apps_clk_src.clkr,
3178 [BLSP1_QUP5_I2C_APPS_CLK_SRC] = &blsp1_qup5_i2c_apps_clk_src.clkr,
3179 [BLSP1_UART5_APPS_CLK_SRC] = &blsp1_uart5_apps_clk_src.clkr,
3180 [BLSP1_QUP6_SPI_APPS_CLK_SRC] = &blsp1_qup6_spi_apps_clk_src.clkr,
3181 [BLSP1_QUP6_I2C_APPS_CLK_SRC] = &blsp1_qup6_i2c_apps_clk_src.clkr,
3182 [BLSP1_UART6_APPS_CLK_SRC] = &blsp1_uart6_apps_clk_src.clkr,
3183 [BLSP2_QUP1_SPI_APPS_CLK_SRC] = &blsp2_qup1_spi_apps_clk_src.clkr,
3184 [BLSP2_QUP1_I2C_APPS_CLK_SRC] = &blsp2_qup1_i2c_apps_clk_src.clkr,
3185 [BLSP2_UART1_APPS_CLK_SRC] = &blsp2_uart1_apps_clk_src.clkr,
3186 [BLSP2_QUP2_SPI_APPS_CLK_SRC] = &blsp2_qup2_spi_apps_clk_src.clkr,
3187 [BLSP2_QUP2_I2C_APPS_CLK_SRC] = &blsp2_qup2_i2c_apps_clk_src.clkr,
3188 [BLSP2_UART2_APPS_CLK_SRC] = &blsp2_uart2_apps_clk_src.clkr,
3189 [BLSP2_QUP3_SPI_APPS_CLK_SRC] = &blsp2_qup3_spi_apps_clk_src.clkr,
3190 [BLSP2_QUP3_I2C_APPS_CLK_SRC] = &blsp2_qup3_i2c_apps_clk_src.clkr,
3191 [BLSP2_UART3_APPS_CLK_SRC] = &blsp2_uart3_apps_clk_src.clkr,
3192 [BLSP2_QUP4_SPI_APPS_CLK_SRC] = &blsp2_qup4_spi_apps_clk_src.clkr,
3193 [BLSP2_QUP4_I2C_APPS_CLK_SRC] = &blsp2_qup4_i2c_apps_clk_src.clkr,
3194 [BLSP2_UART4_APPS_CLK_SRC] = &blsp2_uart4_apps_clk_src.clkr,
3195 [BLSP2_QUP5_SPI_APPS_CLK_SRC] = &blsp2_qup5_spi_apps_clk_src.clkr,
3196 [BLSP2_QUP5_I2C_APPS_CLK_SRC] = &blsp2_qup5_i2c_apps_clk_src.clkr,
3197 [BLSP2_UART5_APPS_CLK_SRC] = &blsp2_uart5_apps_clk_src.clkr,
3198 [BLSP2_QUP6_SPI_APPS_CLK_SRC] = &blsp2_qup6_spi_apps_clk_src.clkr,
3199 [BLSP2_QUP6_I2C_APPS_CLK_SRC] = &blsp2_qup6_i2c_apps_clk_src.clkr,
3200 [BLSP2_UART6_APPS_CLK_SRC] = &blsp2_uart6_apps_clk_src.clkr,
3201 [PDM2_CLK_SRC] = &pdm2_clk_src.clkr,
3202 [TSIF_REF_CLK_SRC] = &tsif_ref_clk_src.clkr,
3203 [GCC_SLEEP_CLK_SRC] = &gcc_sleep_clk_src.clkr,
3204 [HMSS_RBCPR_CLK_SRC] = &hmss_rbcpr_clk_src.clkr,
3205 [HMSS_GPLL0_CLK_SRC] = &hmss_gpll0_clk_src.clkr,
3206 [GP1_CLK_SRC] = &gp1_clk_src.clkr,
3207 [GP2_CLK_SRC] = &gp2_clk_src.clkr,
3208 [GP3_CLK_SRC] = &gp3_clk_src.clkr,
3209 [PCIE_AUX_CLK_SRC] = &pcie_aux_clk_src.clkr,
3210 [UFS_AXI_CLK_SRC] = &ufs_axi_clk_src.clkr,
3211 [UFS_ICE_CORE_CLK_SRC] = &ufs_ice_core_clk_src.clkr,
3212 [QSPI_SER_CLK_SRC] = &qspi_ser_clk_src.clkr,
3213 [GCC_SYS_NOC_USB3_AXI_CLK] = &gcc_sys_noc_usb3_axi_clk.clkr,
3214 [GCC_SYS_NOC_UFS_AXI_CLK] = &gcc_sys_noc_ufs_axi_clk.clkr,
3215 [GCC_PERIPH_NOC_USB20_AHB_CLK] = &gcc_periph_noc_usb20_ahb_clk.clkr,
3216 [GCC_MMSS_NOC_CFG_AHB_CLK] = &gcc_mmss_noc_cfg_ahb_clk.clkr,
3217 [GCC_MMSS_BIMC_GFX_CLK] = &gcc_mmss_bimc_gfx_clk.clkr,
3218 [GCC_USB30_MASTER_CLK] = &gcc_usb30_master_clk.clkr,
3219 [GCC_USB30_SLEEP_CLK] = &gcc_usb30_sleep_clk.clkr,
3220 [GCC_USB30_MOCK_UTMI_CLK] = &gcc_usb30_mock_utmi_clk.clkr,
3221 [GCC_USB3_PHY_AUX_CLK] = &gcc_usb3_phy_aux_clk.clkr,
3222 [GCC_USB3_PHY_PIPE_CLK] = &gcc_usb3_phy_pipe_clk.clkr,
3223 [GCC_USB20_MASTER_CLK] = &gcc_usb20_master_clk.clkr,
3224 [GCC_USB20_SLEEP_CLK] = &gcc_usb20_sleep_clk.clkr,
3225 [GCC_USB20_MOCK_UTMI_CLK] = &gcc_usb20_mock_utmi_clk.clkr,
3226 [GCC_USB_PHY_CFG_AHB2PHY_CLK] = &gcc_usb_phy_cfg_ahb2phy_clk.clkr,
3227 [GCC_SDCC1_APPS_CLK] = &gcc_sdcc1_apps_clk.clkr,
3228 [GCC_SDCC1_AHB_CLK] = &gcc_sdcc1_ahb_clk.clkr,
3229 [GCC_SDCC1_ICE_CORE_CLK] = &gcc_sdcc1_ice_core_clk.clkr,
3230 [GCC_SDCC2_APPS_CLK] = &gcc_sdcc2_apps_clk.clkr,
3231 [GCC_SDCC2_AHB_CLK] = &gcc_sdcc2_ahb_clk.clkr,
3232 [GCC_SDCC3_APPS_CLK] = &gcc_sdcc3_apps_clk.clkr,
3233 [GCC_SDCC3_AHB_CLK] = &gcc_sdcc3_ahb_clk.clkr,
3234 [GCC_SDCC4_APPS_CLK] = &gcc_sdcc4_apps_clk.clkr,
3235 [GCC_SDCC4_AHB_CLK] = &gcc_sdcc4_ahb_clk.clkr,
3236 [GCC_BLSP1_AHB_CLK] = &gcc_blsp1_ahb_clk.clkr,
3237 [GCC_BLSP1_SLEEP_CLK] = &gcc_blsp1_sleep_clk.clkr,
3238 [GCC_BLSP1_QUP1_SPI_APPS_CLK] = &gcc_blsp1_qup1_spi_apps_clk.clkr,
3239 [GCC_BLSP1_QUP1_I2C_APPS_CLK] = &gcc_blsp1_qup1_i2c_apps_clk.clkr,
3240 [GCC_BLSP1_UART1_APPS_CLK] = &gcc_blsp1_uart1_apps_clk.clkr,
3241 [GCC_BLSP1_QUP2_SPI_APPS_CLK] = &gcc_blsp1_qup2_spi_apps_clk.clkr,
3242 [GCC_BLSP1_QUP2_I2C_APPS_CLK] = &gcc_blsp1_qup2_i2c_apps_clk.clkr,
3243 [GCC_BLSP1_UART2_APPS_CLK] = &gcc_blsp1_uart2_apps_clk.clkr,
3244 [GCC_BLSP1_QUP3_SPI_APPS_CLK] = &gcc_blsp1_qup3_spi_apps_clk.clkr,
3245 [GCC_BLSP1_QUP3_I2C_APPS_CLK] = &gcc_blsp1_qup3_i2c_apps_clk.clkr,
3246 [GCC_BLSP1_UART3_APPS_CLK] = &gcc_blsp1_uart3_apps_clk.clkr,
3247 [GCC_BLSP1_QUP4_SPI_APPS_CLK] = &gcc_blsp1_qup4_spi_apps_clk.clkr,
3248 [GCC_BLSP1_QUP4_I2C_APPS_CLK] = &gcc_blsp1_qup4_i2c_apps_clk.clkr,
3249 [GCC_BLSP1_UART4_APPS_CLK] = &gcc_blsp1_uart4_apps_clk.clkr,
3250 [GCC_BLSP1_QUP5_SPI_APPS_CLK] = &gcc_blsp1_qup5_spi_apps_clk.clkr,
3251 [GCC_BLSP1_QUP5_I2C_APPS_CLK] = &gcc_blsp1_qup5_i2c_apps_clk.clkr,
3252 [GCC_BLSP1_UART5_APPS_CLK] = &gcc_blsp1_uart5_apps_clk.clkr,
3253 [GCC_BLSP1_QUP6_SPI_APPS_CLK] = &gcc_blsp1_qup6_spi_apps_clk.clkr,
3254 [GCC_BLSP1_QUP6_I2C_APPS_CLK] = &gcc_blsp1_qup6_i2c_apps_clk.clkr,
3255 [GCC_BLSP1_UART6_APPS_CLK] = &gcc_blsp1_uart6_apps_clk.clkr,
3256 [GCC_BLSP2_AHB_CLK] = &gcc_blsp2_ahb_clk.clkr,
3257 [GCC_BLSP2_SLEEP_CLK] = &gcc_blsp2_sleep_clk.clkr,
3258 [GCC_BLSP2_QUP1_SPI_APPS_CLK] = &gcc_blsp2_qup1_spi_apps_clk.clkr,
3259 [GCC_BLSP2_QUP1_I2C_APPS_CLK] = &gcc_blsp2_qup1_i2c_apps_clk.clkr,
3260 [GCC_BLSP2_UART1_APPS_CLK] = &gcc_blsp2_uart1_apps_clk.clkr,
3261 [GCC_BLSP2_QUP2_SPI_APPS_CLK] = &gcc_blsp2_qup2_spi_apps_clk.clkr,
3262 [GCC_BLSP2_QUP2_I2C_APPS_CLK] = &gcc_blsp2_qup2_i2c_apps_clk.clkr,
3263 [GCC_BLSP2_UART2_APPS_CLK] = &gcc_blsp2_uart2_apps_clk.clkr,
3264 [GCC_BLSP2_QUP3_SPI_APPS_CLK] = &gcc_blsp2_qup3_spi_apps_clk.clkr,
3265 [GCC_BLSP2_QUP3_I2C_APPS_CLK] = &gcc_blsp2_qup3_i2c_apps_clk.clkr,
3266 [GCC_BLSP2_UART3_APPS_CLK] = &gcc_blsp2_uart3_apps_clk.clkr,
3267 [GCC_BLSP2_QUP4_SPI_APPS_CLK] = &gcc_blsp2_qup4_spi_apps_clk.clkr,
3268 [GCC_BLSP2_QUP4_I2C_APPS_CLK] = &gcc_blsp2_qup4_i2c_apps_clk.clkr,
3269 [GCC_BLSP2_UART4_APPS_CLK] = &gcc_blsp2_uart4_apps_clk.clkr,
3270 [GCC_BLSP2_QUP5_SPI_APPS_CLK] = &gcc_blsp2_qup5_spi_apps_clk.clkr,
3271 [GCC_BLSP2_QUP5_I2C_APPS_CLK] = &gcc_blsp2_qup5_i2c_apps_clk.clkr,
3272 [GCC_BLSP2_UART5_APPS_CLK] = &gcc_blsp2_uart5_apps_clk.clkr,
3273 [GCC_BLSP2_QUP6_SPI_APPS_CLK] = &gcc_blsp2_qup6_spi_apps_clk.clkr,
3274 [GCC_BLSP2_QUP6_I2C_APPS_CLK] = &gcc_blsp2_qup6_i2c_apps_clk.clkr,
3275 [GCC_BLSP2_UART6_APPS_CLK] = &gcc_blsp2_uart6_apps_clk.clkr,
3276 [GCC_PDM_AHB_CLK] = &gcc_pdm_ahb_clk.clkr,
3277 [GCC_PDM2_CLK] = &gcc_pdm2_clk.clkr,
3278 [GCC_PRNG_AHB_CLK] = &gcc_prng_ahb_clk.clkr,
3279 [GCC_TSIF_AHB_CLK] = &gcc_tsif_ahb_clk.clkr,
3280 [GCC_TSIF_REF_CLK] = &gcc_tsif_ref_clk.clkr,
3281 [GCC_TSIF_INACTIVITY_TIMERS_CLK] = &gcc_tsif_inactivity_timers_clk.clkr,
3282 [GCC_BOOT_ROM_AHB_CLK] = &gcc_boot_rom_ahb_clk.clkr,
3283 [GCC_BIMC_GFX_CLK] = &gcc_bimc_gfx_clk.clkr,
3284 [GCC_HMSS_RBCPR_CLK] = &gcc_hmss_rbcpr_clk.clkr,
3285 [GCC_GP1_CLK] = &gcc_gp1_clk.clkr,
3286 [GCC_GP2_CLK] = &gcc_gp2_clk.clkr,
3287 [GCC_GP3_CLK] = &gcc_gp3_clk.clkr,
3288 [GCC_PCIE_0_SLV_AXI_CLK] = &gcc_pcie_0_slv_axi_clk.clkr,
3289 [GCC_PCIE_0_MSTR_AXI_CLK] = &gcc_pcie_0_mstr_axi_clk.clkr,
3290 [GCC_PCIE_0_CFG_AHB_CLK] = &gcc_pcie_0_cfg_ahb_clk.clkr,
3291 [GCC_PCIE_0_AUX_CLK] = &gcc_pcie_0_aux_clk.clkr,
3292 [GCC_PCIE_0_PIPE_CLK] = &gcc_pcie_0_pipe_clk.clkr,
3293 [GCC_PCIE_1_SLV_AXI_CLK] = &gcc_pcie_1_slv_axi_clk.clkr,
3294 [GCC_PCIE_1_MSTR_AXI_CLK] = &gcc_pcie_1_mstr_axi_clk.clkr,
3295 [GCC_PCIE_1_CFG_AHB_CLK] = &gcc_pcie_1_cfg_ahb_clk.clkr,
3296 [GCC_PCIE_1_AUX_CLK] = &gcc_pcie_1_aux_clk.clkr,
3297 [GCC_PCIE_1_PIPE_CLK] = &gcc_pcie_1_pipe_clk.clkr,
3298 [GCC_PCIE_2_SLV_AXI_CLK] = &gcc_pcie_2_slv_axi_clk.clkr,
3299 [GCC_PCIE_2_MSTR_AXI_CLK] = &gcc_pcie_2_mstr_axi_clk.clkr,
3300 [GCC_PCIE_2_CFG_AHB_CLK] = &gcc_pcie_2_cfg_ahb_clk.clkr,
3301 [GCC_PCIE_2_AUX_CLK] = &gcc_pcie_2_aux_clk.clkr,
3302 [GCC_PCIE_2_PIPE_CLK] = &gcc_pcie_2_pipe_clk.clkr,
3303 [GCC_PCIE_PHY_CFG_AHB_CLK] = &gcc_pcie_phy_cfg_ahb_clk.clkr,
3304 [GCC_PCIE_PHY_AUX_CLK] = &gcc_pcie_phy_aux_clk.clkr,
3305 [GCC_UFS_AXI_CLK] = &gcc_ufs_axi_clk.clkr,
3306 [GCC_UFS_AHB_CLK] = &gcc_ufs_ahb_clk.clkr,
3307 [GCC_UFS_TX_CFG_CLK] = &gcc_ufs_tx_cfg_clk.clkr,
3308 [GCC_UFS_RX_CFG_CLK] = &gcc_ufs_rx_cfg_clk.clkr,
3309 [GCC_HLOS1_VOTE_LPASS_CORE_SMMU_CLK] = &gcc_hlos1_vote_lpass_core_smmu_clk.clkr,
3310 [GCC_HLOS1_VOTE_LPASS_ADSP_SMMU_CLK] = &gcc_hlos1_vote_lpass_adsp_smmu_clk.clkr,
3311 [GCC_UFS_TX_SYMBOL_0_CLK] = &gcc_ufs_tx_symbol_0_clk.clkr,
3312 [GCC_UFS_RX_SYMBOL_0_CLK] = &gcc_ufs_rx_symbol_0_clk.clkr,
3313 [GCC_UFS_RX_SYMBOL_1_CLK] = &gcc_ufs_rx_symbol_1_clk.clkr,
3314 [GCC_UFS_UNIPRO_CORE_CLK] = &gcc_ufs_unipro_core_clk.clkr,
3315 [GCC_UFS_ICE_CORE_CLK] = &gcc_ufs_ice_core_clk.clkr,
3316 [GCC_UFS_SYS_CLK_CORE_CLK] = &gcc_ufs_sys_clk_core_clk.clkr,
3317 [GCC_UFS_TX_SYMBOL_CLK_CORE_CLK] = &gcc_ufs_tx_symbol_clk_core_clk.clkr,
3318 [GCC_AGGRE0_SNOC_AXI_CLK] = &gcc_aggre0_snoc_axi_clk.clkr,
3319 [GCC_AGGRE0_CNOC_AHB_CLK] = &gcc_aggre0_cnoc_ahb_clk.clkr,
3320 [GCC_SMMU_AGGRE0_AXI_CLK] = &gcc_smmu_aggre0_axi_clk.clkr,
3321 [GCC_SMMU_AGGRE0_AHB_CLK] = &gcc_smmu_aggre0_ahb_clk.clkr,
3322 [GCC_AGGRE2_UFS_AXI_CLK] = &gcc_aggre2_ufs_axi_clk.clkr,
3323 [GCC_AGGRE2_USB3_AXI_CLK] = &gcc_aggre2_usb3_axi_clk.clkr,
3324 [GCC_QSPI_AHB_CLK] = &gcc_qspi_ahb_clk.clkr,
3325 [GCC_QSPI_SER_CLK] = &gcc_qspi_ser_clk.clkr,
3326 [GCC_USB3_CLKREF_CLK] = &gcc_usb3_clkref_clk.clkr,
3327 [GCC_HDMI_CLKREF_CLK] = &gcc_hdmi_clkref_clk.clkr,
3328 [GCC_UFS_CLKREF_CLK] = &gcc_ufs_clkref_clk.clkr,
3329 [GCC_PCIE_CLKREF_CLK] = &gcc_pcie_clkref_clk.clkr,
3330 [GCC_RX2_USB2_CLKREF_CLK] = &gcc_rx2_usb2_clkref_clk.clkr,
3331 [GCC_RX1_USB2_CLKREF_CLK] = &gcc_rx1_usb2_clkref_clk.clkr,
3334 static struct gdsc *gcc_msm8996_gdscs[] = {
3335 [AGGRE0_NOC_GDSC] = &aggre0_noc_gdsc,
3336 [HLOS1_VOTE_AGGRE0_NOC_GDSC] = &hlos1_vote_aggre0_noc_gdsc,
3337 [HLOS1_VOTE_LPASS_ADSP_GDSC] = &hlos1_vote_lpass_adsp_gdsc,
3338 [HLOS1_VOTE_LPASS_CORE_GDSC] = &hlos1_vote_lpass_core_gdsc,
3339 [USB30_GDSC] = &usb30_gdsc,
3340 [PCIE0_GDSC] = &pcie0_gdsc,
3341 [PCIE1_GDSC] = &pcie1_gdsc,
3342 [PCIE2_GDSC] = &pcie2_gdsc,
3343 [UFS_GDSC] = &ufs_gdsc,
3346 static const struct qcom_reset_map gcc_msm8996_resets[] = {
3347 [GCC_SYSTEM_NOC_BCR] = { 0x4000 },
3348 [GCC_CONFIG_NOC_BCR] = { 0x5000 },
3349 [GCC_PERIPH_NOC_BCR] = { 0x6000 },
3350 [GCC_IMEM_BCR] = { 0x8000 },
3351 [GCC_MMSS_BCR] = { 0x9000 },
3352 [GCC_PIMEM_BCR] = { 0x0a000 },
3353 [GCC_QDSS_BCR] = { 0x0c000 },
3354 [GCC_USB_30_BCR] = { 0x0f000 },
3355 [GCC_USB_20_BCR] = { 0x12000 },
3356 [GCC_QUSB2PHY_PRIM_BCR] = { 0x12038 },
3357 [GCC_QUSB2PHY_SEC_BCR] = { 0x1203c },
3358 [GCC_USB3_PHY_BCR] = { 0x50020 },
3359 [GCC_USB3PHY_PHY_BCR] = { 0x50024 },
3360 [GCC_USB_PHY_CFG_AHB2PHY_BCR] = { 0x6a000 },
3361 [GCC_SDCC1_BCR] = { 0x13000 },
3362 [GCC_SDCC2_BCR] = { 0x14000 },
3363 [GCC_SDCC3_BCR] = { 0x15000 },
3364 [GCC_SDCC4_BCR] = { 0x16000 },
3365 [GCC_BLSP1_BCR] = { 0x17000 },
3366 [GCC_BLSP1_QUP1_BCR] = { 0x19000 },
3367 [GCC_BLSP1_UART1_BCR] = { 0x1a000 },
3368 [GCC_BLSP1_QUP2_BCR] = { 0x1b000 },
3369 [GCC_BLSP1_UART2_BCR] = { 0x1c000 },
3370 [GCC_BLSP1_QUP3_BCR] = { 0x1d000 },
3371 [GCC_BLSP1_UART3_BCR] = { 0x1e000 },
3372 [GCC_BLSP1_QUP4_BCR] = { 0x1f000 },
3373 [GCC_BLSP1_UART4_BCR] = { 0x20000 },
3374 [GCC_BLSP1_QUP5_BCR] = { 0x21000 },
3375 [GCC_BLSP1_UART5_BCR] = { 0x22000 },
3376 [GCC_BLSP1_QUP6_BCR] = { 0x23000 },
3377 [GCC_BLSP1_UART6_BCR] = { 0x24000 },
3378 [GCC_BLSP2_BCR] = { 0x25000 },
3379 [GCC_BLSP2_QUP1_BCR] = { 0x26000 },
3380 [GCC_BLSP2_UART1_BCR] = { 0x27000 },
3381 [GCC_BLSP2_QUP2_BCR] = { 0x28000 },
3382 [GCC_BLSP2_UART2_BCR] = { 0x29000 },
3383 [GCC_BLSP2_QUP3_BCR] = { 0x2a000 },
3384 [GCC_BLSP2_UART3_BCR] = { 0x2b000 },
3385 [GCC_BLSP2_QUP4_BCR] = { 0x2c000 },
3386 [GCC_BLSP2_UART4_BCR] = { 0x2d000 },
3387 [GCC_BLSP2_QUP5_BCR] = { 0x2e000 },
3388 [GCC_BLSP2_UART5_BCR] = { 0x2f000 },
3389 [GCC_BLSP2_QUP6_BCR] = { 0x30000 },
3390 [GCC_BLSP2_UART6_BCR] = { 0x31000 },
3391 [GCC_PDM_BCR] = { 0x33000 },
3392 [GCC_PRNG_BCR] = { 0x34000 },
3393 [GCC_TSIF_BCR] = { 0x36000 },
3394 [GCC_TCSR_BCR] = { 0x37000 },
3395 [GCC_BOOT_ROM_BCR] = { 0x38000 },
3396 [GCC_MSG_RAM_BCR] = { 0x39000 },
3397 [GCC_TLMM_BCR] = { 0x3a000 },
3398 [GCC_MPM_BCR] = { 0x3b000 },
3399 [GCC_SEC_CTRL_BCR] = { 0x3d000 },
3400 [GCC_SPMI_BCR] = { 0x3f000 },
3401 [GCC_SPDM_BCR] = { 0x40000 },
3402 [GCC_CE1_BCR] = { 0x41000 },
3403 [GCC_BIMC_BCR] = { 0x44000 },
3404 [GCC_SNOC_BUS_TIMEOUT0_BCR] = { 0x49000 },
3405 [GCC_SNOC_BUS_TIMEOUT2_BCR] = { 0x49008 },
3406 [GCC_SNOC_BUS_TIMEOUT1_BCR] = { 0x49010 },
3407 [GCC_SNOC_BUS_TIMEOUT3_BCR] = { 0x49018 },
3408 [GCC_SNOC_BUS_TIMEOUT_EXTREF_BCR] = { 0x49020 },
3409 [GCC_PNOC_BUS_TIMEOUT0_BCR] = { 0x4a000 },
3410 [GCC_PNOC_BUS_TIMEOUT1_BCR] = { 0x4a008 },
3411 [GCC_PNOC_BUS_TIMEOUT2_BCR] = { 0x4a010 },
3412 [GCC_PNOC_BUS_TIMEOUT3_BCR] = { 0x4a018 },
3413 [GCC_PNOC_BUS_TIMEOUT4_BCR] = { 0x4a020 },
3414 [GCC_CNOC_BUS_TIMEOUT0_BCR] = { 0x4b000 },
3415 [GCC_CNOC_BUS_TIMEOUT1_BCR] = { 0x4b008 },
3416 [GCC_CNOC_BUS_TIMEOUT2_BCR] = { 0x4b010 },
3417 [GCC_CNOC_BUS_TIMEOUT3_BCR] = { 0x4b018 },
3418 [GCC_CNOC_BUS_TIMEOUT4_BCR] = { 0x4b020 },
3419 [GCC_CNOC_BUS_TIMEOUT5_BCR] = { 0x4b028 },
3420 [GCC_CNOC_BUS_TIMEOUT6_BCR] = { 0x4b030 },
3421 [GCC_CNOC_BUS_TIMEOUT7_BCR] = { 0x4b038 },
3422 [GCC_CNOC_BUS_TIMEOUT8_BCR] = { 0x80000 },
3423 [GCC_CNOC_BUS_TIMEOUT9_BCR] = { 0x80008 },
3424 [GCC_CNOC_BUS_TIMEOUT_EXTREF_BCR] = { 0x80010 },
3425 [GCC_APB2JTAG_BCR] = { 0x4c000 },
3426 [GCC_RBCPR_CX_BCR] = { 0x4e000 },
3427 [GCC_RBCPR_MX_BCR] = { 0x4f000 },
3428 [GCC_PCIE_0_BCR] = { 0x6b000 },
3429 [GCC_PCIE_0_PHY_BCR] = { 0x6c01c },
3430 [GCC_PCIE_1_BCR] = { 0x6d000 },
3431 [GCC_PCIE_1_PHY_BCR] = { 0x6d038 },
3432 [GCC_PCIE_2_BCR] = { 0x6e000 },
3433 [GCC_PCIE_2_PHY_BCR] = { 0x6e038 },
3434 [GCC_PCIE_PHY_BCR] = { 0x6f000 },
3435 [GCC_PCIE_PHY_COM_BCR] = { 0x6f014 },
3436 [GCC_PCIE_PHY_COM_NOCSR_BCR] = { 0x6f00c },
3437 [GCC_DCD_BCR] = { 0x70000 },
3438 [GCC_OBT_ODT_BCR] = { 0x73000 },
3439 [GCC_UFS_BCR] = { 0x75000 },
3440 [GCC_SSC_BCR] = { 0x63000 },
3441 [GCC_VS_BCR] = { 0x7a000 },
3442 [GCC_AGGRE0_NOC_BCR] = { 0x81000 },
3443 [GCC_AGGRE1_NOC_BCR] = { 0x82000 },
3444 [GCC_AGGRE2_NOC_BCR] = { 0x83000 },
3445 [GCC_DCC_BCR] = { 0x84000 },
3446 [GCC_IPA_BCR] = { 0x89000 },
3447 [GCC_QSPI_BCR] = { 0x8b000 },
3448 [GCC_SKL_BCR] = { 0x8c000 },
3449 [GCC_MSMPU_BCR] = { 0x8d000 },
3450 [GCC_MSS_Q6_BCR] = { 0x8e000 },
3451 [GCC_QREFS_VBG_CAL_BCR] = { 0x88020 },
3452 [GCC_MSS_RESTART] = { 0x8f008 },
3455 static const struct regmap_config gcc_msm8996_regmap_config = {
3456 .reg_bits = 32,
3457 .reg_stride = 4,
3458 .val_bits = 32,
3459 .max_register = 0x8f010,
3460 .fast_io = true,
3463 static const struct qcom_cc_desc gcc_msm8996_desc = {
3464 .config = &gcc_msm8996_regmap_config,
3465 .clks = gcc_msm8996_clocks,
3466 .num_clks = ARRAY_SIZE(gcc_msm8996_clocks),
3467 .resets = gcc_msm8996_resets,
3468 .num_resets = ARRAY_SIZE(gcc_msm8996_resets),
3469 .gdscs = gcc_msm8996_gdscs,
3470 .num_gdscs = ARRAY_SIZE(gcc_msm8996_gdscs),
3473 static const struct of_device_id gcc_msm8996_match_table[] = {
3474 { .compatible = "qcom,gcc-msm8996" },
3477 MODULE_DEVICE_TABLE(of, gcc_msm8996_match_table);
3479 static int gcc_msm8996_probe(struct platform_device *pdev)
3481 struct device *dev = &pdev->dev;
3482 int i, ret;
3483 struct regmap *regmap;
3485 regmap = qcom_cc_map(pdev, &gcc_msm8996_desc);
3486 if (IS_ERR(regmap))
3487 return PTR_ERR(regmap);
3490 * Set the HMSS_AHB_CLK_SLEEP_ENA bit to allow the hmss_ahb_clk to be
3491 * turned off by hardware during certain apps low power modes.
3493 regmap_update_bits(regmap, 0x52008, BIT(21), BIT(21));
3495 for (i = 0; i < ARRAY_SIZE(gcc_msm8996_hws); i++) {
3496 ret = devm_clk_hw_register(dev, gcc_msm8996_hws[i]);
3497 if (ret)
3498 return ret;
3501 return qcom_cc_really_probe(pdev, &gcc_msm8996_desc, regmap);
3504 static struct platform_driver gcc_msm8996_driver = {
3505 .probe = gcc_msm8996_probe,
3506 .driver = {
3507 .name = "gcc-msm8996",
3508 .of_match_table = gcc_msm8996_match_table,
3512 static int __init gcc_msm8996_init(void)
3514 return platform_driver_register(&gcc_msm8996_driver);
3516 core_initcall(gcc_msm8996_init);
3518 static void __exit gcc_msm8996_exit(void)
3520 platform_driver_unregister(&gcc_msm8996_driver);
3522 module_exit(gcc_msm8996_exit);
3524 MODULE_DESCRIPTION("QCOM GCC MSM8996 Driver");
3525 MODULE_LICENSE("GPL v2");
3526 MODULE_ALIAS("platform:gcc-msm8996");