1*83d290c5STom Rini // SPDX-License-Identifier: GPL-2.0
21251e490SNobuhiro Iwamatsu /*
31251e490SNobuhiro Iwamatsu * board/renesas/koelsch/qos.c
41251e490SNobuhiro Iwamatsu *
5ec9b386eSNobuhiro Iwamatsu * Copyright (C) 2013,2014 Renesas Electronics Corporation
61251e490SNobuhiro Iwamatsu *
71251e490SNobuhiro Iwamatsu */
81251e490SNobuhiro Iwamatsu
91251e490SNobuhiro Iwamatsu #include <common.h>
101251e490SNobuhiro Iwamatsu #include <asm/processor.h>
111251e490SNobuhiro Iwamatsu #include <asm/mach-types.h>
121251e490SNobuhiro Iwamatsu #include <asm/io.h>
131251e490SNobuhiro Iwamatsu #include <asm/arch/rmobile.h>
141251e490SNobuhiro Iwamatsu
15c56af554SNobuhiro Iwamatsu /* QoS version 0.240 for ES1 and version 0.411 for ES2 */
161cc95f6eSNobuhiro Iwamatsu #if defined(CONFIG_ARCH_RMOBILE_EXTRAM_BOOT)
171251e490SNobuhiro Iwamatsu enum {
181251e490SNobuhiro Iwamatsu DBSC3_00, DBSC3_01, DBSC3_02, DBSC3_03, DBSC3_04,
191251e490SNobuhiro Iwamatsu DBSC3_05, DBSC3_06, DBSC3_07, DBSC3_08, DBSC3_09,
201251e490SNobuhiro Iwamatsu DBSC3_10, DBSC3_11, DBSC3_12, DBSC3_13, DBSC3_14,
211251e490SNobuhiro Iwamatsu DBSC3_15,
221251e490SNobuhiro Iwamatsu DBSC3_NR,
231251e490SNobuhiro Iwamatsu };
241251e490SNobuhiro Iwamatsu
251251e490SNobuhiro Iwamatsu static u32 dbsc3_0_r_qos_addr[DBSC3_NR] = {
261251e490SNobuhiro Iwamatsu [DBSC3_00] = DBSC3_0_QOS_R0_BASE,
271251e490SNobuhiro Iwamatsu [DBSC3_01] = DBSC3_0_QOS_R1_BASE,
281251e490SNobuhiro Iwamatsu [DBSC3_02] = DBSC3_0_QOS_R2_BASE,
291251e490SNobuhiro Iwamatsu [DBSC3_03] = DBSC3_0_QOS_R3_BASE,
301251e490SNobuhiro Iwamatsu [DBSC3_04] = DBSC3_0_QOS_R4_BASE,
311251e490SNobuhiro Iwamatsu [DBSC3_05] = DBSC3_0_QOS_R5_BASE,
321251e490SNobuhiro Iwamatsu [DBSC3_06] = DBSC3_0_QOS_R6_BASE,
331251e490SNobuhiro Iwamatsu [DBSC3_07] = DBSC3_0_QOS_R7_BASE,
341251e490SNobuhiro Iwamatsu [DBSC3_08] = DBSC3_0_QOS_R8_BASE,
351251e490SNobuhiro Iwamatsu [DBSC3_09] = DBSC3_0_QOS_R9_BASE,
361251e490SNobuhiro Iwamatsu [DBSC3_10] = DBSC3_0_QOS_R10_BASE,
371251e490SNobuhiro Iwamatsu [DBSC3_11] = DBSC3_0_QOS_R11_BASE,
381251e490SNobuhiro Iwamatsu [DBSC3_12] = DBSC3_0_QOS_R12_BASE,
391251e490SNobuhiro Iwamatsu [DBSC3_13] = DBSC3_0_QOS_R13_BASE,
401251e490SNobuhiro Iwamatsu [DBSC3_14] = DBSC3_0_QOS_R14_BASE,
411251e490SNobuhiro Iwamatsu [DBSC3_15] = DBSC3_0_QOS_R15_BASE,
421251e490SNobuhiro Iwamatsu };
431251e490SNobuhiro Iwamatsu
441251e490SNobuhiro Iwamatsu static u32 dbsc3_0_w_qos_addr[DBSC3_NR] = {
451251e490SNobuhiro Iwamatsu [DBSC3_00] = DBSC3_0_QOS_W0_BASE,
461251e490SNobuhiro Iwamatsu [DBSC3_01] = DBSC3_0_QOS_W1_BASE,
471251e490SNobuhiro Iwamatsu [DBSC3_02] = DBSC3_0_QOS_W2_BASE,
481251e490SNobuhiro Iwamatsu [DBSC3_03] = DBSC3_0_QOS_W3_BASE,
491251e490SNobuhiro Iwamatsu [DBSC3_04] = DBSC3_0_QOS_W4_BASE,
501251e490SNobuhiro Iwamatsu [DBSC3_05] = DBSC3_0_QOS_W5_BASE,
511251e490SNobuhiro Iwamatsu [DBSC3_06] = DBSC3_0_QOS_W6_BASE,
521251e490SNobuhiro Iwamatsu [DBSC3_07] = DBSC3_0_QOS_W7_BASE,
531251e490SNobuhiro Iwamatsu [DBSC3_08] = DBSC3_0_QOS_W8_BASE,
541251e490SNobuhiro Iwamatsu [DBSC3_09] = DBSC3_0_QOS_W9_BASE,
551251e490SNobuhiro Iwamatsu [DBSC3_10] = DBSC3_0_QOS_W10_BASE,
561251e490SNobuhiro Iwamatsu [DBSC3_11] = DBSC3_0_QOS_W11_BASE,
571251e490SNobuhiro Iwamatsu [DBSC3_12] = DBSC3_0_QOS_W12_BASE,
581251e490SNobuhiro Iwamatsu [DBSC3_13] = DBSC3_0_QOS_W13_BASE,
591251e490SNobuhiro Iwamatsu [DBSC3_14] = DBSC3_0_QOS_W14_BASE,
601251e490SNobuhiro Iwamatsu [DBSC3_15] = DBSC3_0_QOS_W15_BASE,
611251e490SNobuhiro Iwamatsu };
621251e490SNobuhiro Iwamatsu
631251e490SNobuhiro Iwamatsu static u32 dbsc3_1_r_qos_addr[DBSC3_NR] = {
641251e490SNobuhiro Iwamatsu [DBSC3_00] = DBSC3_1_QOS_R0_BASE,
651251e490SNobuhiro Iwamatsu [DBSC3_01] = DBSC3_1_QOS_R1_BASE,
661251e490SNobuhiro Iwamatsu [DBSC3_02] = DBSC3_1_QOS_R2_BASE,
671251e490SNobuhiro Iwamatsu [DBSC3_03] = DBSC3_1_QOS_R3_BASE,
681251e490SNobuhiro Iwamatsu [DBSC3_04] = DBSC3_1_QOS_R4_BASE,
691251e490SNobuhiro Iwamatsu [DBSC3_05] = DBSC3_1_QOS_R5_BASE,
701251e490SNobuhiro Iwamatsu [DBSC3_06] = DBSC3_1_QOS_R6_BASE,
711251e490SNobuhiro Iwamatsu [DBSC3_07] = DBSC3_1_QOS_R7_BASE,
721251e490SNobuhiro Iwamatsu [DBSC3_08] = DBSC3_1_QOS_R8_BASE,
731251e490SNobuhiro Iwamatsu [DBSC3_09] = DBSC3_1_QOS_R9_BASE,
741251e490SNobuhiro Iwamatsu [DBSC3_10] = DBSC3_1_QOS_R10_BASE,
751251e490SNobuhiro Iwamatsu [DBSC3_11] = DBSC3_1_QOS_R11_BASE,
761251e490SNobuhiro Iwamatsu [DBSC3_12] = DBSC3_1_QOS_R12_BASE,
771251e490SNobuhiro Iwamatsu [DBSC3_13] = DBSC3_1_QOS_R13_BASE,
781251e490SNobuhiro Iwamatsu [DBSC3_14] = DBSC3_1_QOS_R14_BASE,
791251e490SNobuhiro Iwamatsu [DBSC3_15] = DBSC3_1_QOS_R15_BASE,
801251e490SNobuhiro Iwamatsu };
811251e490SNobuhiro Iwamatsu
821251e490SNobuhiro Iwamatsu static u32 dbsc3_1_w_qos_addr[DBSC3_NR] = {
831251e490SNobuhiro Iwamatsu [DBSC3_00] = DBSC3_1_QOS_W0_BASE,
841251e490SNobuhiro Iwamatsu [DBSC3_01] = DBSC3_1_QOS_W1_BASE,
851251e490SNobuhiro Iwamatsu [DBSC3_02] = DBSC3_1_QOS_W2_BASE,
861251e490SNobuhiro Iwamatsu [DBSC3_03] = DBSC3_1_QOS_W3_BASE,
871251e490SNobuhiro Iwamatsu [DBSC3_04] = DBSC3_1_QOS_W4_BASE,
881251e490SNobuhiro Iwamatsu [DBSC3_05] = DBSC3_1_QOS_W5_BASE,
891251e490SNobuhiro Iwamatsu [DBSC3_06] = DBSC3_1_QOS_W6_BASE,
901251e490SNobuhiro Iwamatsu [DBSC3_07] = DBSC3_1_QOS_W7_BASE,
911251e490SNobuhiro Iwamatsu [DBSC3_08] = DBSC3_1_QOS_W8_BASE,
921251e490SNobuhiro Iwamatsu [DBSC3_09] = DBSC3_1_QOS_W9_BASE,
931251e490SNobuhiro Iwamatsu [DBSC3_10] = DBSC3_1_QOS_W10_BASE,
941251e490SNobuhiro Iwamatsu [DBSC3_11] = DBSC3_1_QOS_W11_BASE,
951251e490SNobuhiro Iwamatsu [DBSC3_12] = DBSC3_1_QOS_W12_BASE,
961251e490SNobuhiro Iwamatsu [DBSC3_13] = DBSC3_1_QOS_W13_BASE,
971251e490SNobuhiro Iwamatsu [DBSC3_14] = DBSC3_1_QOS_W14_BASE,
981251e490SNobuhiro Iwamatsu [DBSC3_15] = DBSC3_1_QOS_W15_BASE,
991251e490SNobuhiro Iwamatsu };
1001251e490SNobuhiro Iwamatsu
101c56af554SNobuhiro Iwamatsu #if defined(CONFIG_QOS_PRI_MEDIA)
102c56af554SNobuhiro Iwamatsu #define is_qos_pri_media() 1
103c56af554SNobuhiro Iwamatsu #else
104c56af554SNobuhiro Iwamatsu #define is_qos_pri_media() 0
105c56af554SNobuhiro Iwamatsu #endif
106c56af554SNobuhiro Iwamatsu
107c56af554SNobuhiro Iwamatsu #if defined(CONFIG_QOS_PRI_NORMAL)
108c56af554SNobuhiro Iwamatsu #define is_qos_pri_normal() 1
109c56af554SNobuhiro Iwamatsu #else
110c56af554SNobuhiro Iwamatsu #define is_qos_pri_normal() 0
111c56af554SNobuhiro Iwamatsu #endif
112c56af554SNobuhiro Iwamatsu
113c56af554SNobuhiro Iwamatsu #if defined(CONFIG_QOS_PRI_GFX)
114c56af554SNobuhiro Iwamatsu #define is_qos_pri_gfx() 1
115c56af554SNobuhiro Iwamatsu #else
116c56af554SNobuhiro Iwamatsu #define is_qos_pri_gfx() 0
117c56af554SNobuhiro Iwamatsu #endif
118c56af554SNobuhiro Iwamatsu
qos_init(void)1191251e490SNobuhiro Iwamatsu void qos_init(void)
1201251e490SNobuhiro Iwamatsu {
1211251e490SNobuhiro Iwamatsu int i;
122ec9b386eSNobuhiro Iwamatsu struct rcar_s3c *s3c;
123ec9b386eSNobuhiro Iwamatsu struct rcar_s3c_qos *s3c_qos;
124ec9b386eSNobuhiro Iwamatsu struct rcar_dbsc3_qos *qos_addr;
125ec9b386eSNobuhiro Iwamatsu struct rcar_mxi *mxi;
126ec9b386eSNobuhiro Iwamatsu struct rcar_mxi_qos *mxi_qos;
127ec9b386eSNobuhiro Iwamatsu struct rcar_axi_qos *axi_qos;
1281251e490SNobuhiro Iwamatsu
1291251e490SNobuhiro Iwamatsu /* DBSC DBADJ2 */
1301251e490SNobuhiro Iwamatsu writel(0x20042004, DBSC3_0_DBADJ2);
131dbfd1159SNobuhiro Iwamatsu writel(0x20042004, DBSC3_1_DBADJ2);
1321251e490SNobuhiro Iwamatsu
1331251e490SNobuhiro Iwamatsu /* S3C -QoS */
134ec9b386eSNobuhiro Iwamatsu s3c = (struct rcar_s3c *)S3C_BASE;
135502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
13683335bdcSNobuhiro Iwamatsu /* Linear All mode */
13783335bdcSNobuhiro Iwamatsu /* writel(0x00000000, &s3c->s3cadsplcr); */
13883335bdcSNobuhiro Iwamatsu /* Linear Linear 0x7000 to 0x7800 mode */
13983335bdcSNobuhiro Iwamatsu writel(0x00BF1B0C, &s3c->s3cadsplcr);
14083335bdcSNobuhiro Iwamatsu /* Split Linear 0x6800 t 0x7000 mode */
14183335bdcSNobuhiro Iwamatsu /* writel(0x00DF1B0C, &s3c->s3cadsplcr); */
14283335bdcSNobuhiro Iwamatsu /* Ssplit All mode */
14383335bdcSNobuhiro Iwamatsu /* writel(0x00FF1B0C, &s3c->s3cadsplcr); */
144c56af554SNobuhiro Iwamatsu
145c56af554SNobuhiro Iwamatsu if (is_qos_pri_media()) {
146c56af554SNobuhiro Iwamatsu writel(0x1F0B0604, &s3c->s3crorr);
147c56af554SNobuhiro Iwamatsu writel(0x1F0E0705, &s3c->s3cworr);
148c56af554SNobuhiro Iwamatsu } else if (is_qos_pri_normal()) {
14983335bdcSNobuhiro Iwamatsu writel(0x1F0B0908, &s3c->s3crorr);
150c56af554SNobuhiro Iwamatsu writel(0x1F0E0A08, &s3c->s3cworr);
151c56af554SNobuhiro Iwamatsu } else if (is_qos_pri_gfx()) {
152c56af554SNobuhiro Iwamatsu writel(0x1F0B0B0B, &s3c->s3crorr);
153c56af554SNobuhiro Iwamatsu writel(0x1F0E0C0C, &s3c->s3cworr);
154c56af554SNobuhiro Iwamatsu }
155502b92c1SNobuhiro Iwamatsu } else {
1561251e490SNobuhiro Iwamatsu writel(0x00FF1B1D, &s3c->s3cadsplcr);
1571251e490SNobuhiro Iwamatsu writel(0x1F0D0C0C, &s3c->s3crorr);
1581251e490SNobuhiro Iwamatsu writel(0x1F0D0C0A, &s3c->s3cworr);
159502b92c1SNobuhiro Iwamatsu }
1601251e490SNobuhiro Iwamatsu /* QoS Control Registers */
161ec9b386eSNobuhiro Iwamatsu s3c_qos = (struct rcar_s3c_qos *)S3C_QOS_CCI0_BASE;
1621251e490SNobuhiro Iwamatsu writel(0x00890089, &s3c_qos->s3cqos0);
1631251e490SNobuhiro Iwamatsu writel(0x20960010, &s3c_qos->s3cqos1);
1641251e490SNobuhiro Iwamatsu writel(0x20302030, &s3c_qos->s3cqos2);
165c56af554SNobuhiro Iwamatsu
166c56af554SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
167c56af554SNobuhiro Iwamatsu if (is_qos_pri_media())
168c56af554SNobuhiro Iwamatsu writel(0x20AA2300, &s3c_qos->s3cqos3);
169c56af554SNobuhiro Iwamatsu else if (is_qos_pri_normal())
1701251e490SNobuhiro Iwamatsu writel(0x20AA2200, &s3c_qos->s3cqos3);
171c56af554SNobuhiro Iwamatsu else if (is_qos_pri_gfx())
172c56af554SNobuhiro Iwamatsu writel(0x20AA2100, &s3c_qos->s3cqos3);
173c56af554SNobuhiro Iwamatsu } else {
174c56af554SNobuhiro Iwamatsu writel(0x20AA2200, &s3c_qos->s3cqos3);
175c56af554SNobuhiro Iwamatsu }
1761251e490SNobuhiro Iwamatsu writel(0x00002032, &s3c_qos->s3cqos4);
1771251e490SNobuhiro Iwamatsu writel(0x20960010, &s3c_qos->s3cqos5);
1781251e490SNobuhiro Iwamatsu writel(0x20302030, &s3c_qos->s3cqos6);
179c56af554SNobuhiro Iwamatsu
180c56af554SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
181c56af554SNobuhiro Iwamatsu if (is_qos_pri_media())
182c56af554SNobuhiro Iwamatsu writel(0x20AA2300, &s3c_qos->s3cqos7);
183c56af554SNobuhiro Iwamatsu else if (is_qos_pri_normal())
1841251e490SNobuhiro Iwamatsu writel(0x20AA2200, &s3c_qos->s3cqos7);
185c56af554SNobuhiro Iwamatsu else if (is_qos_pri_gfx())
186c56af554SNobuhiro Iwamatsu writel(0x20AA2100, &s3c_qos->s3cqos7);
187c56af554SNobuhiro Iwamatsu } else {
188c56af554SNobuhiro Iwamatsu writel(0x20AA2200, &s3c_qos->s3cqos7);
189c56af554SNobuhiro Iwamatsu }
1901251e490SNobuhiro Iwamatsu writel(0x00002032, &s3c_qos->s3cqos8);
1911251e490SNobuhiro Iwamatsu
192ec9b386eSNobuhiro Iwamatsu s3c_qos = (struct rcar_s3c_qos *)S3C_QOS_CCI1_BASE;
1931251e490SNobuhiro Iwamatsu writel(0x00890089, &s3c_qos->s3cqos0);
1941251e490SNobuhiro Iwamatsu writel(0x20960010, &s3c_qos->s3cqos1);
1951251e490SNobuhiro Iwamatsu writel(0x20302030, &s3c_qos->s3cqos2);
196c56af554SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
197c56af554SNobuhiro Iwamatsu if (is_qos_pri_media())
198c56af554SNobuhiro Iwamatsu writel(0x20AA2300, &s3c_qos->s3cqos3);
199c56af554SNobuhiro Iwamatsu else if (is_qos_pri_normal())
2001251e490SNobuhiro Iwamatsu writel(0x20AA2200, &s3c_qos->s3cqos3);
201c56af554SNobuhiro Iwamatsu else if (is_qos_pri_gfx())
202c56af554SNobuhiro Iwamatsu writel(0x20AA2100, &s3c_qos->s3cqos3);
203c56af554SNobuhiro Iwamatsu } else {
204c56af554SNobuhiro Iwamatsu writel(0x20AA2200, &s3c_qos->s3cqos3);
205c56af554SNobuhiro Iwamatsu }
2061251e490SNobuhiro Iwamatsu writel(0x00002032, &s3c_qos->s3cqos4);
2071251e490SNobuhiro Iwamatsu writel(0x20960010, &s3c_qos->s3cqos5);
2081251e490SNobuhiro Iwamatsu writel(0x20302030, &s3c_qos->s3cqos6);
209c56af554SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
210c56af554SNobuhiro Iwamatsu if (is_qos_pri_media())
211c56af554SNobuhiro Iwamatsu writel(0x20AA2300, &s3c_qos->s3cqos7);
212c56af554SNobuhiro Iwamatsu else if (is_qos_pri_normal())
2131251e490SNobuhiro Iwamatsu writel(0x20AA2200, &s3c_qos->s3cqos7);
214c56af554SNobuhiro Iwamatsu else if (is_qos_pri_gfx())
215c56af554SNobuhiro Iwamatsu writel(0x20AA2100, &s3c_qos->s3cqos7);
216c56af554SNobuhiro Iwamatsu } else {
217c56af554SNobuhiro Iwamatsu writel(0x20AA2200, &s3c_qos->s3cqos7);
218c56af554SNobuhiro Iwamatsu }
2191251e490SNobuhiro Iwamatsu writel(0x00002032, &s3c_qos->s3cqos8);
2201251e490SNobuhiro Iwamatsu
221ec9b386eSNobuhiro Iwamatsu s3c_qos = (struct rcar_s3c_qos *)S3C_QOS_MXI_BASE;
222c56af554SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
223c56af554SNobuhiro Iwamatsu writel(0x80928092, &s3c_qos->s3cqos0);
224c56af554SNobuhiro Iwamatsu else
2251251e490SNobuhiro Iwamatsu writel(0x00820082, &s3c_qos->s3cqos0);
2261251e490SNobuhiro Iwamatsu writel(0x20960020, &s3c_qos->s3cqos1);
2271251e490SNobuhiro Iwamatsu writel(0x20302030, &s3c_qos->s3cqos2);
2281251e490SNobuhiro Iwamatsu writel(0x20AA20DC, &s3c_qos->s3cqos3);
2291251e490SNobuhiro Iwamatsu writel(0x00002032, &s3c_qos->s3cqos4);
2301251e490SNobuhiro Iwamatsu writel(0x20960020, &s3c_qos->s3cqos5);
2311251e490SNobuhiro Iwamatsu writel(0x20302030, &s3c_qos->s3cqos6);
2321251e490SNobuhiro Iwamatsu writel(0x20AA20DC, &s3c_qos->s3cqos7);
2331251e490SNobuhiro Iwamatsu writel(0x00002032, &s3c_qos->s3cqos8);
2341251e490SNobuhiro Iwamatsu
235ec9b386eSNobuhiro Iwamatsu s3c_qos = (struct rcar_s3c_qos *)S3C_QOS_AXI_BASE;
236c56af554SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
237c56af554SNobuhiro Iwamatsu writel(0x80928092, &s3c_qos->s3cqos0);
238c56af554SNobuhiro Iwamatsu else
2391251e490SNobuhiro Iwamatsu writel(0x00820082, &s3c_qos->s3cqos0);
2401251e490SNobuhiro Iwamatsu writel(0x20960020, &s3c_qos->s3cqos1);
2411251e490SNobuhiro Iwamatsu writel(0x20302030, &s3c_qos->s3cqos2);
2421251e490SNobuhiro Iwamatsu writel(0x20AA20FA, &s3c_qos->s3cqos3);
2431251e490SNobuhiro Iwamatsu writel(0x00002032, &s3c_qos->s3cqos4);
2441251e490SNobuhiro Iwamatsu writel(0x20960020, &s3c_qos->s3cqos5);
2451251e490SNobuhiro Iwamatsu writel(0x20302030, &s3c_qos->s3cqos6);
2461251e490SNobuhiro Iwamatsu writel(0x20AA20FA, &s3c_qos->s3cqos7);
2471251e490SNobuhiro Iwamatsu writel(0x00002032, &s3c_qos->s3cqos8);
2481251e490SNobuhiro Iwamatsu
2491251e490SNobuhiro Iwamatsu /* DBSC -QoS */
2501251e490SNobuhiro Iwamatsu /* DBSC0 - Read */
2511251e490SNobuhiro Iwamatsu for (i = DBSC3_00; i < DBSC3_NR; i++) {
252ec9b386eSNobuhiro Iwamatsu qos_addr = (struct rcar_dbsc3_qos *)dbsc3_0_r_qos_addr[i];
2531251e490SNobuhiro Iwamatsu writel(0x00000002, &qos_addr->dblgcnt);
2541251e490SNobuhiro Iwamatsu writel(0x00002096, &qos_addr->dbtmval0);
2551251e490SNobuhiro Iwamatsu writel(0x00002064, &qos_addr->dbtmval1);
2561251e490SNobuhiro Iwamatsu writel(0x00002032, &qos_addr->dbtmval2);
2571251e490SNobuhiro Iwamatsu writel(0x00001FB0, &qos_addr->dbtmval3);
2581251e490SNobuhiro Iwamatsu writel(0x00000001, &qos_addr->dbrqctr);
2591251e490SNobuhiro Iwamatsu writel(0x00002078, &qos_addr->dbthres0);
2601251e490SNobuhiro Iwamatsu writel(0x0000204B, &qos_addr->dbthres1);
26183335bdcSNobuhiro Iwamatsu writel(0x0000201E, &qos_addr->dbthres2);
2621251e490SNobuhiro Iwamatsu writel(0x00000001, &qos_addr->dblgqon);
2631251e490SNobuhiro Iwamatsu }
2641251e490SNobuhiro Iwamatsu
2651251e490SNobuhiro Iwamatsu /* DBSC0 - Write */
2661251e490SNobuhiro Iwamatsu for (i = DBSC3_00; i < DBSC3_NR; i++) {
267ec9b386eSNobuhiro Iwamatsu qos_addr = (struct rcar_dbsc3_qos *)dbsc3_0_w_qos_addr[i];
2681251e490SNobuhiro Iwamatsu writel(0x00000002, &qos_addr->dblgcnt);
26983335bdcSNobuhiro Iwamatsu writel(0x00002096, &qos_addr->dbtmval0);
27083335bdcSNobuhiro Iwamatsu writel(0x00002064, &qos_addr->dbtmval1);
2711251e490SNobuhiro Iwamatsu writel(0x00002050, &qos_addr->dbtmval2);
2721251e490SNobuhiro Iwamatsu writel(0x0000203A, &qos_addr->dbtmval3);
2731251e490SNobuhiro Iwamatsu writel(0x00000001, &qos_addr->dbrqctr);
2741251e490SNobuhiro Iwamatsu writel(0x00002078, &qos_addr->dbthres0);
27583335bdcSNobuhiro Iwamatsu writel(0x0000204B, &qos_addr->dbthres1);
2761251e490SNobuhiro Iwamatsu writel(0x0000203C, &qos_addr->dbthres2);
2771251e490SNobuhiro Iwamatsu writel(0x00000001, &qos_addr->dblgqon);
2781251e490SNobuhiro Iwamatsu }
2791251e490SNobuhiro Iwamatsu
2801251e490SNobuhiro Iwamatsu /* DBSC1 - Read */
2811251e490SNobuhiro Iwamatsu for (i = DBSC3_00; i < DBSC3_NR; i++) {
282ec9b386eSNobuhiro Iwamatsu qos_addr = (struct rcar_dbsc3_qos *)dbsc3_1_r_qos_addr[i];
2831251e490SNobuhiro Iwamatsu writel(0x00000002, &qos_addr->dblgcnt);
2841251e490SNobuhiro Iwamatsu writel(0x00002096, &qos_addr->dbtmval0);
2851251e490SNobuhiro Iwamatsu writel(0x00002064, &qos_addr->dbtmval1);
2861251e490SNobuhiro Iwamatsu writel(0x00002032, &qos_addr->dbtmval2);
2871251e490SNobuhiro Iwamatsu writel(0x00001FB0, &qos_addr->dbtmval3);
2881251e490SNobuhiro Iwamatsu writel(0x00000001, &qos_addr->dbrqctr);
2891251e490SNobuhiro Iwamatsu writel(0x00002078, &qos_addr->dbthres0);
2901251e490SNobuhiro Iwamatsu writel(0x0000204B, &qos_addr->dbthres1);
29183335bdcSNobuhiro Iwamatsu writel(0x0000201E, &qos_addr->dbthres2);
2921251e490SNobuhiro Iwamatsu writel(0x00000001, &qos_addr->dblgqon);
2931251e490SNobuhiro Iwamatsu }
2941251e490SNobuhiro Iwamatsu
2951251e490SNobuhiro Iwamatsu /* DBSC1 - Write */
2961251e490SNobuhiro Iwamatsu for (i = DBSC3_00; i < DBSC3_NR; i++) {
297ec9b386eSNobuhiro Iwamatsu qos_addr = (struct rcar_dbsc3_qos *)dbsc3_1_w_qos_addr[i];
2981251e490SNobuhiro Iwamatsu writel(0x00000002, &qos_addr->dblgcnt);
29983335bdcSNobuhiro Iwamatsu writel(0x00002096, &qos_addr->dbtmval0);
30083335bdcSNobuhiro Iwamatsu writel(0x00002064, &qos_addr->dbtmval1);
3011251e490SNobuhiro Iwamatsu writel(0x00002050, &qos_addr->dbtmval2);
3021251e490SNobuhiro Iwamatsu writel(0x0000203A, &qos_addr->dbtmval3);
3031251e490SNobuhiro Iwamatsu writel(0x00000001, &qos_addr->dbrqctr);
3041251e490SNobuhiro Iwamatsu writel(0x00002078, &qos_addr->dbthres0);
30583335bdcSNobuhiro Iwamatsu writel(0x0000204B, &qos_addr->dbthres1);
3061251e490SNobuhiro Iwamatsu writel(0x0000203C, &qos_addr->dbthres2);
3071251e490SNobuhiro Iwamatsu writel(0x00000001, &qos_addr->dblgqon);
3081251e490SNobuhiro Iwamatsu }
3091251e490SNobuhiro Iwamatsu
3101251e490SNobuhiro Iwamatsu /* CCI-400 -QoS */
3111251e490SNobuhiro Iwamatsu writel(0x20001000, CCI_400_MAXOT_1);
3121251e490SNobuhiro Iwamatsu writel(0x20001000, CCI_400_MAXOT_2);
3131251e490SNobuhiro Iwamatsu writel(0x0000000C, CCI_400_QOSCNTL_1);
3141251e490SNobuhiro Iwamatsu writel(0x0000000C, CCI_400_QOSCNTL_2);
3151251e490SNobuhiro Iwamatsu
3161251e490SNobuhiro Iwamatsu /* MXI -QoS */
3171251e490SNobuhiro Iwamatsu /* Transaction Control (MXI) */
318c56af554SNobuhiro Iwamatsu mxi = (struct rcar_mxi *)XI_BASE;
3191251e490SNobuhiro Iwamatsu writel(0x00000013, &mxi->mxrtcr);
320c56af554SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
321c56af554SNobuhiro Iwamatsu writel(0x00000016, &mxi->mxwtcr);
322c56af554SNobuhiro Iwamatsu writel(0x00780080, &mxi->mxsaar0);
323c56af554SNobuhiro Iwamatsu writel(0x02000800, &mxi->mxsaar1);
324c56af554SNobuhiro Iwamatsu } else {
3251251e490SNobuhiro Iwamatsu writel(0x00000013, &mxi->mxwtcr);
326c56af554SNobuhiro Iwamatsu }
3271251e490SNobuhiro Iwamatsu
3281251e490SNobuhiro Iwamatsu /* QoS Control (MXI) */
329ec9b386eSNobuhiro Iwamatsu mxi_qos = (struct rcar_mxi_qos *)MXI_QOS_BASE;
3301251e490SNobuhiro Iwamatsu writel(0x0000000C, &mxi_qos->vspdu0);
3311251e490SNobuhiro Iwamatsu writel(0x0000000C, &mxi_qos->vspdu1);
33283335bdcSNobuhiro Iwamatsu writel(0x0000000E, &mxi_qos->du0);
3331251e490SNobuhiro Iwamatsu writel(0x0000000D, &mxi_qos->du1);
3341251e490SNobuhiro Iwamatsu
3351251e490SNobuhiro Iwamatsu /* AXI -QoS */
3361251e490SNobuhiro Iwamatsu /* Transaction Control (MXI) */
337ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_SYX64TO128_BASE;
3381251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
3391251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
3401251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
3411251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
3421251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
3431251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
3441251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
3451251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
3461251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
3471251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
3481251e490SNobuhiro Iwamatsu
349ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_AVB_BASE;
3501251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
3511251e490SNobuhiro Iwamatsu writel(0x000020A6, &axi_qos->qosctset0);
3521251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
3531251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
3541251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
3551251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
3561251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
3571251e490SNobuhiro Iwamatsu
358ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_G2D_BASE;
3591251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
3601251e490SNobuhiro Iwamatsu writel(0x000020A6, &axi_qos->qosctset0);
3611251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
3621251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
3631251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
3641251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
3651251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
3661251e490SNobuhiro Iwamatsu
367ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_IMP0_BASE;
3681251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
3691251e490SNobuhiro Iwamatsu writel(0x00002021, &axi_qos->qosctset0);
3701251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
3711251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
3721251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
3731251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
3741251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
3751251e490SNobuhiro Iwamatsu
376ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_IMP1_BASE;
3771251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
3781251e490SNobuhiro Iwamatsu writel(0x00002037, &axi_qos->qosctset0);
3791251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
3801251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
3811251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
3821251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
3831251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
3841251e490SNobuhiro Iwamatsu
385ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_IMUX0_BASE;
3861251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
3871251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
3881251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
3891251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
3901251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
3911251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
3921251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
3931251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
3941251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
3951251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
3961251e490SNobuhiro Iwamatsu
397ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_IMUX1_BASE;
3981251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
3991251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
4001251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
4011251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
4021251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
4031251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
4041251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
4051251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
4061251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
4071251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
4081251e490SNobuhiro Iwamatsu
409ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_IMUX2_BASE;
4101251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
4111251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
4121251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
4131251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
4141251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
4151251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
4161251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
4171251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
4181251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
4191251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
4201251e490SNobuhiro Iwamatsu
421ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_LBS_BASE;
4221251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
4231251e490SNobuhiro Iwamatsu writel(0x0000214C, &axi_qos->qosctset0);
4241251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
4251251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
4261251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
4271251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
4281251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
4291251e490SNobuhiro Iwamatsu
430ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_MMUDS_BASE;
4311251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
4321251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
4331251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
4341251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
4351251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
4361251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
4371251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
4381251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
4391251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
4401251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
4411251e490SNobuhiro Iwamatsu
442ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_MMUM_BASE;
4431251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
4441251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
4451251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
4461251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
4471251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
4481251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
4491251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
4501251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
4511251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
4521251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
4531251e490SNobuhiro Iwamatsu
454ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_MMUR_BASE;
4551251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
4561251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
4571251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
4581251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
4591251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
4601251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
4611251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
4621251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
4631251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
4641251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
4651251e490SNobuhiro Iwamatsu
466ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_MMUS0_BASE;
4671251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
4681251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
4691251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
4701251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
4711251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
4721251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
4731251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
4741251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
4751251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
4761251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
4771251e490SNobuhiro Iwamatsu
478ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_MMUS1_BASE;
4791251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
4801251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
4811251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
4821251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
4831251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
4841251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
4851251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
4861251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
4871251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
4881251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
4891251e490SNobuhiro Iwamatsu
490ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_MTSB0_BASE;
4911251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
4921251e490SNobuhiro Iwamatsu writel(0x00002021, &axi_qos->qosctset0);
4931251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
4941251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
4951251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
4961251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
4971251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
4981251e490SNobuhiro Iwamatsu
499ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_MTSB1_BASE;
5001251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
5011251e490SNobuhiro Iwamatsu writel(0x00002021, &axi_qos->qosctset0);
5021251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
5031251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
5041251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
5051251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
5061251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
5071251e490SNobuhiro Iwamatsu
508ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_PCI_BASE;
5091251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
5101251e490SNobuhiro Iwamatsu writel(0x0000214C, &axi_qos->qosctset0);
5111251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
5121251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
5131251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
5141251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
5151251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
5161251e490SNobuhiro Iwamatsu
517ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_RTX_BASE;
5181251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
5191251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
5201251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
5211251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
5221251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
5231251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
5241251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
5251251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
5261251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
5271251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
5281251e490SNobuhiro Iwamatsu
529ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_SDS0_BASE;
5301251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
5311251e490SNobuhiro Iwamatsu writel(0x000020A6, &axi_qos->qosctset0);
5321251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
5331251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
5341251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
5351251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
5361251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
5371251e490SNobuhiro Iwamatsu
538ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_SDS1_BASE;
5391251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
5401251e490SNobuhiro Iwamatsu writel(0x000020A6, &axi_qos->qosctset0);
5411251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
5421251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
5431251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
5441251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
5451251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
5461251e490SNobuhiro Iwamatsu
547ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_USB20_BASE;
5481251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
5491251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
5501251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
5511251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
5521251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
5531251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
5541251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
5551251e490SNobuhiro Iwamatsu
556ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_USB21_BASE;
5571251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
5581251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
5591251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
5601251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
5611251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
5621251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
5631251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
5641251e490SNobuhiro Iwamatsu
565ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_USB22_BASE;
5661251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
5671251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
5681251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
5691251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
5701251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
5711251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
5721251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
5731251e490SNobuhiro Iwamatsu
574ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_USB30_BASE;
5751251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
5761251e490SNobuhiro Iwamatsu writel(0x0000214C, &axi_qos->qosctset0);
5771251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
5781251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
5791251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
5801251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
5811251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
5821251e490SNobuhiro Iwamatsu
583ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_AX2M_BASE;
5841251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
5851251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
5861251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
5871251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
5881251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
5891251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
5901251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
5911251e490SNobuhiro Iwamatsu
592ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_CC50_BASE;
5931251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
5941251e490SNobuhiro Iwamatsu writel(0x00002029, &axi_qos->qosctset0);
5951251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
5961251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
5971251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
5981251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
5991251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6001251e490SNobuhiro Iwamatsu
601ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_CCI_BASE;
6021251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
6031251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
6041251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
6051251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
6061251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
6071251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
6081251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6091251e490SNobuhiro Iwamatsu
610ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_CS_BASE;
6111251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
6121251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
6131251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
6141251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
6151251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
6161251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
6171251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6181251e490SNobuhiro Iwamatsu
619ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_DDM_BASE;
6201251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
6211251e490SNobuhiro Iwamatsu writel(0x000020A6, &axi_qos->qosctset0);
6221251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
6231251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
6241251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
6251251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
6261251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6271251e490SNobuhiro Iwamatsu
628ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_ETH_BASE;
6291251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
6301251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
6311251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
6321251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
6331251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
6341251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
6351251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6361251e490SNobuhiro Iwamatsu
637ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_MPXM_BASE;
6381251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
6391251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
6401251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
6411251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
6421251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
6431251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
6441251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6451251e490SNobuhiro Iwamatsu
646ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_SAT0_BASE;
6471251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
6481251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
6491251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
6501251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
6511251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
6521251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
6531251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6541251e490SNobuhiro Iwamatsu
655ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_SAT1_BASE;
6561251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
6571251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
6581251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
6591251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
6601251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
6611251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
6621251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6631251e490SNobuhiro Iwamatsu
664ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_SDM0_BASE;
6651251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
6661251e490SNobuhiro Iwamatsu writel(0x0000214C, &axi_qos->qosctset0);
6671251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
6681251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
6691251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
6701251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
6711251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6721251e490SNobuhiro Iwamatsu
673ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_SDM1_BASE;
6741251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
6751251e490SNobuhiro Iwamatsu writel(0x0000214C, &axi_qos->qosctset0);
6761251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
6771251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
6781251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
6791251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
6801251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6811251e490SNobuhiro Iwamatsu
682ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_TRAB_BASE;
6831251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
6841251e490SNobuhiro Iwamatsu writel(0x000020A6, &axi_qos->qosctset0);
6851251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
6861251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
6871251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
6881251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
6891251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6901251e490SNobuhiro Iwamatsu
691ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_UDM0_BASE;
6921251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
6931251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
6941251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
6951251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
6961251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
6971251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
6981251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
6991251e490SNobuhiro Iwamatsu
700ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI_UDM1_BASE;
7011251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
7021251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
7031251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
7041251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
7051251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
7061251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
7071251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
7081251e490SNobuhiro Iwamatsu
7091251e490SNobuhiro Iwamatsu /* QoS Register (RT-AXI) */
710ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)RT_AXI_SHX_BASE;
711c56af554SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
712c56af554SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
713c56af554SNobuhiro Iwamatsu else
7141251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
7151251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
7161251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
7171251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
7181251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
7191251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
7201251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
7211251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
7221251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
7231251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
7241251e490SNobuhiro Iwamatsu
725ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)RT_AXI_DBG_BASE;
7261251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
7271251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
7281251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
7291251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
7301251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
7311251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
7321251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
7331251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
7341251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
7351251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
7361251e490SNobuhiro Iwamatsu
737ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)RT_AXI_RDM_BASE;
7381251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
7391251e490SNobuhiro Iwamatsu writel(0x00002299, &axi_qos->qosctset0);
7401251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
7411251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
7421251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
7431251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
7441251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
7451251e490SNobuhiro Iwamatsu
746ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)RT_AXI_RDS_BASE;
7471251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
7481251e490SNobuhiro Iwamatsu writel(0x00002029, &axi_qos->qosctset0);
7491251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
7501251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
7511251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
7521251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
7531251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
7541251e490SNobuhiro Iwamatsu
755ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)RT_AXI_RTX64TO128_BASE;
7561251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
7571251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
7581251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
7591251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
7601251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
7611251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
7621251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
7631251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
7641251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
7651251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
7661251e490SNobuhiro Iwamatsu
767ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)RT_AXI_STPRO_BASE;
7681251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
7691251e490SNobuhiro Iwamatsu writel(0x00002029, &axi_qos->qosctset0);
7701251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
7711251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
7721251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
7731251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
7741251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
7751251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
7761251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
7771251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
7781251e490SNobuhiro Iwamatsu
779ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)RT_AXI_SY2RT_BASE;
7801251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
7811251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
7821251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
7831251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
7841251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
7851251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
7861251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
7871251e490SNobuhiro Iwamatsu
7881251e490SNobuhiro Iwamatsu /* QoS Register (MP-AXI) */
789ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MP_AXI_ADSP_BASE;
7901251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
7911251e490SNobuhiro Iwamatsu writel(0x00002037, &axi_qos->qosctset0);
7921251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
7931251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
7941251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
7951251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
7961251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
7971251e490SNobuhiro Iwamatsu
798ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MP_AXI_ASDS0_BASE;
7991251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
8001251e490SNobuhiro Iwamatsu writel(0x00002014, &axi_qos->qosctset0);
8014e626a35SNobuhiro Iwamatsu writel(0x00000040, &axi_qos->qosreqctr);
8021251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
8031251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
8041251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
8051251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
8061251e490SNobuhiro Iwamatsu
807ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MP_AXI_ASDS1_BASE;
8081251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
8091251e490SNobuhiro Iwamatsu writel(0x00002014, &axi_qos->qosctset0);
8104e626a35SNobuhiro Iwamatsu writel(0x00000040, &axi_qos->qosreqctr);
8111251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
8121251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
8131251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
8141251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
8151251e490SNobuhiro Iwamatsu
816ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MP_AXI_MLP_BASE;
8174e626a35SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
8184e626a35SNobuhiro Iwamatsu writel(0x00001FF0, &axi_qos->qosctset0);
8194e626a35SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
8201251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
8211251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
8224e626a35SNobuhiro Iwamatsu writel(0x00002001, &axi_qos->qosthres2);
8231251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
8241251e490SNobuhiro Iwamatsu
825ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MP_AXI_MMUMP_BASE;
8261251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
8271251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
8281251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
8291251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
8301251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
8311251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
8321251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
8331251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
8341251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
8351251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
8361251e490SNobuhiro Iwamatsu
837ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MP_AXI_SPU_BASE;
8381251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
8391251e490SNobuhiro Iwamatsu writel(0x00002053, &axi_qos->qosctset0);
8401251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
8411251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
8421251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
8431251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
8441251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
8451251e490SNobuhiro Iwamatsu
846ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MP_AXI_SPUC_BASE;
8471251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
8481251e490SNobuhiro Iwamatsu writel(0x0000206E, &axi_qos->qosctset0);
8491251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
8501251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
8511251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
8521251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
8531251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
8541251e490SNobuhiro Iwamatsu
8551251e490SNobuhiro Iwamatsu /* QoS Register (SYS-AXI256) */
856ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI256_AXI128TO256_BASE;
8571251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
858502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
859502b92c1SNobuhiro Iwamatsu writel(0x000020EB, &axi_qos->qosctset0);
860502b92c1SNobuhiro Iwamatsu else
8611251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
8621251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
8631251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
8641251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
8651251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
8661251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
8671251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
8681251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
8691251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
8701251e490SNobuhiro Iwamatsu
871ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI256_SYX_BASE;
8721251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
873502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
874502b92c1SNobuhiro Iwamatsu writel(0x000020EB, &axi_qos->qosctset0);
875502b92c1SNobuhiro Iwamatsu else
8761251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
8771251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
8781251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
8791251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
8801251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
8811251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
8821251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
8831251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
8841251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
8851251e490SNobuhiro Iwamatsu
886ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI256_MPX_BASE;
8871251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
888502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
889502b92c1SNobuhiro Iwamatsu writel(0x000020EB, &axi_qos->qosctset0);
890502b92c1SNobuhiro Iwamatsu else
8911251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
8921251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
8931251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
8941251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
8951251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
8961251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
8971251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
8981251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
8991251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
9001251e490SNobuhiro Iwamatsu
901ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)SYS_AXI256_MXI_BASE;
9021251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
9031251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
9041251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
9051251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
9061251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
9071251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
9081251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
9091251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
9101251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
9111251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
9121251e490SNobuhiro Iwamatsu
9131251e490SNobuhiro Iwamatsu /* QoS Register (CCI-AXI) */
914ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)CCI_AXI_MMUS0_BASE;
9151251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
9161251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
9171251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
9181251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
9191251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
9201251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
9211251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
9221251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
9231251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
9241251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
9251251e490SNobuhiro Iwamatsu
926ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)CCI_AXI_SYX2_BASE;
9271251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
9281251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
9291251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
9301251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
9311251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
9321251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
9331251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
9341251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
9351251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
9361251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
9371251e490SNobuhiro Iwamatsu
938ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)CCI_AXI_MMUR_BASE;
9391251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
9401251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
9411251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
9421251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
9431251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
9441251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
9451251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
9461251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
9471251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
9481251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
9491251e490SNobuhiro Iwamatsu
950ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)CCI_AXI_MMUDS_BASE;
9511251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
9521251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
9531251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
9541251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
9551251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
9561251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
9571251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
9581251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
9591251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
9601251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
9611251e490SNobuhiro Iwamatsu
962ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)CCI_AXI_MMUM_BASE;
9631251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
9641251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
9651251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
9661251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
9671251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
9681251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
9691251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
9701251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
9711251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
9721251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
9731251e490SNobuhiro Iwamatsu
974ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)CCI_AXI_MXI_BASE;
9751251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
9761251e490SNobuhiro Iwamatsu writel(0x00002245, &axi_qos->qosctset0);
9771251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
9781251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
9791251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
9801251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
9811251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
9821251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
9831251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
9841251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
9851251e490SNobuhiro Iwamatsu
986ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)CCI_AXI_MMUS1_BASE;
9871251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
9881251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
9891251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
9901251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
9911251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
9921251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
9931251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
9941251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
9951251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
9961251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
9971251e490SNobuhiro Iwamatsu
998ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)CCI_AXI_MMUMP_BASE;
9991251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
10001251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosctset0);
10011251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
10021251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
10031251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
10041251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
10051251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
10061251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
10071251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosthres2);
10081251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
10091251e490SNobuhiro Iwamatsu
10101251e490SNobuhiro Iwamatsu /* QoS Register (Media-AXI) */
1011ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_MXR_BASE;
10121251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
10131251e490SNobuhiro Iwamatsu writel(0x000020DC, &axi_qos->qosctset0);
10141251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
10151251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
10161251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
10171251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
10181251e490SNobuhiro Iwamatsu writel(0x000020AA, &axi_qos->qosthres0);
10191251e490SNobuhiro Iwamatsu writel(0x00002032, &axi_qos->qosthres1);
10201251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
10211251e490SNobuhiro Iwamatsu
1022ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_MXW_BASE;
10231251e490SNobuhiro Iwamatsu writel(0x00000002, &axi_qos->qosconf);
10241251e490SNobuhiro Iwamatsu writel(0x000020DC, &axi_qos->qosctset0);
10251251e490SNobuhiro Iwamatsu writel(0x00002096, &axi_qos->qosctset1);
10261251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset2);
10271251e490SNobuhiro Iwamatsu writel(0x00002030, &axi_qos->qosctset3);
10281251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
10291251e490SNobuhiro Iwamatsu writel(0x000020AA, &axi_qos->qosthres0);
10301251e490SNobuhiro Iwamatsu writel(0x00002032, &axi_qos->qosthres1);
10311251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
10321251e490SNobuhiro Iwamatsu
1033ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_JPR_BASE;
10341251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
10351251e490SNobuhiro Iwamatsu writel(0x00002190, &axi_qos->qosctset0);
10361251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
10371251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
10381251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
10391251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
10401251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
10411251e490SNobuhiro Iwamatsu
1042ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_JPW_BASE;
10431251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
10441251e490SNobuhiro Iwamatsu writel(0x00002190, &axi_qos->qosctset0);
10451251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
1046502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
1047502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres0);
1048502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres1);
1049502b92c1SNobuhiro Iwamatsu } else {
10501251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
10511251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
1052502b92c1SNobuhiro Iwamatsu }
10531251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
10541251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
10551251e490SNobuhiro Iwamatsu
1056ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_TDMR_BASE;
10571251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
10581251e490SNobuhiro Iwamatsu writel(0x00002190, &axi_qos->qosctset0);
10591251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
10601251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
10611251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
10621251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
10631251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
10641251e490SNobuhiro Iwamatsu
1065ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_TDMW_BASE;
10661251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
10671251e490SNobuhiro Iwamatsu writel(0x00002190, &axi_qos->qosctset0);
10681251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
10691251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
10701251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
10711251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
10721251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
10731251e490SNobuhiro Iwamatsu
1074ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSP1CR_BASE;
10751251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
10761251e490SNobuhiro Iwamatsu writel(0x00002190, &axi_qos->qosctset0);
10771251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
10781251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
10791251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
10801251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
10811251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
10821251e490SNobuhiro Iwamatsu
1083ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSP1CW_BASE;
10841251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
10851251e490SNobuhiro Iwamatsu writel(0x00002190, &axi_qos->qosctset0);
10861251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
1087502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
1088502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres0);
1089502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres1);
1090502b92c1SNobuhiro Iwamatsu } else {
10911251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
10921251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
1093502b92c1SNobuhiro Iwamatsu }
10941251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
10951251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
10961251e490SNobuhiro Iwamatsu
1097ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSPDU0CR_BASE;
10981251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
10991251e490SNobuhiro Iwamatsu writel(0x00002190, &axi_qos->qosctset0);
11001251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
11011251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
11021251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
11031251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
11041251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
11051251e490SNobuhiro Iwamatsu
1106ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSPDU0CW_BASE;
11071251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
11081251e490SNobuhiro Iwamatsu writel(0x00002190, &axi_qos->qosctset0);
11091251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
1110502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
1111502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres0);
1112502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres1);
1113502b92c1SNobuhiro Iwamatsu } else {
11141251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
11151251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
1116502b92c1SNobuhiro Iwamatsu }
11171251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
11181251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
11191251e490SNobuhiro Iwamatsu
1120ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSPDU1CR_BASE;
11211251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
11221251e490SNobuhiro Iwamatsu writel(0x00002190, &axi_qos->qosctset0);
11231251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
11241251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
11251251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
11261251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
11271251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
11281251e490SNobuhiro Iwamatsu
1129ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSPDU1CW_BASE;
11301251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
11311251e490SNobuhiro Iwamatsu writel(0x00002190, &axi_qos->qosctset0);
11321251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
1133502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
1134502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres0);
1135502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres1);
1136502b92c1SNobuhiro Iwamatsu } else {
11371251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
11381251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
1139502b92c1SNobuhiro Iwamatsu }
11401251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
11411251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
11421251e490SNobuhiro Iwamatsu
1143ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VIN0W_BASE;
11441251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
1145502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
1146502b92c1SNobuhiro Iwamatsu writel(0x00001FF0, &axi_qos->qosctset0);
1147502b92c1SNobuhiro Iwamatsu else
11481251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
11491251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
11501251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
11511251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
1152502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
1153502b92c1SNobuhiro Iwamatsu writel(0x00002001, &axi_qos->qosthres2);
1154502b92c1SNobuhiro Iwamatsu else
11551251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
11561251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
11571251e490SNobuhiro Iwamatsu
1158ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_FDP0R_BASE;
11591251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
11601251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
11611251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
11621251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
11631251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
11641251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
11651251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
11661251e490SNobuhiro Iwamatsu
1167ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_FDP0W_BASE;
11681251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
11691251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
11701251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
1171502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
1172502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres0);
1173502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres1);
1174502b92c1SNobuhiro Iwamatsu } else {
11751251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
11761251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
1177502b92c1SNobuhiro Iwamatsu }
11781251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
11791251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
11801251e490SNobuhiro Iwamatsu
1181ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_IMSR_BASE;
11821251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
11831251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
11841251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
11851251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
11861251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
11871251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
11881251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
11891251e490SNobuhiro Iwamatsu
1190ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_IMSW_BASE;
11911251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
11921251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
11931251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
11941251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
11951251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
11961251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
11971251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
11981251e490SNobuhiro Iwamatsu
1199ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSP1R_BASE;
12001251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
12011251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
12021251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
12031251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
12041251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
12051251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
12061251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
12071251e490SNobuhiro Iwamatsu
1208ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSP1W_BASE;
12091251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
12101251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
12111251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
1212502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
1213502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres0);
1214502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres1);
1215502b92c1SNobuhiro Iwamatsu } else {
12161251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
12171251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
1218502b92c1SNobuhiro Iwamatsu }
12191251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
12201251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
12211251e490SNobuhiro Iwamatsu
1222ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_FDP1R_BASE;
12231251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
12241251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
12251251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
12261251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
12271251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
12281251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
12291251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
12301251e490SNobuhiro Iwamatsu
1231ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_FDP1W_BASE;
12321251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
12331251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
12341251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
1235502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
1236502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres0);
1237502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres1);
1238502b92c1SNobuhiro Iwamatsu } else {
12391251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
12401251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
1241502b92c1SNobuhiro Iwamatsu }
12421251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
12431251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
12441251e490SNobuhiro Iwamatsu
1245ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_IMRR_BASE;
12461251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
12471251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
12481251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
12491251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
12501251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
12511251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
12521251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
12531251e490SNobuhiro Iwamatsu
1254ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_IMRW_BASE;
12551251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
12561251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
12571251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
12581251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
12591251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
12601251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
12611251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
12621251e490SNobuhiro Iwamatsu
1263ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSPD0R_BASE;
1264502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
1265502b92c1SNobuhiro Iwamatsu writel(0x00000003, &axi_qos->qosconf);
1266502b92c1SNobuhiro Iwamatsu else
12671251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
12681251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
12691251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
12701251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
12711251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
12721251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
12731251e490SNobuhiro Iwamatsu
1274ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSPD0W_BASE;
1275502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
1276502b92c1SNobuhiro Iwamatsu writel(0x00000003, &axi_qos->qosconf);
1277502b92c1SNobuhiro Iwamatsu else
12781251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
12791251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
12801251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
12811251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
12821251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
12831251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
12841251e490SNobuhiro Iwamatsu
1285ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSPD1R_BASE;
1286502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
1287502b92c1SNobuhiro Iwamatsu writel(0x00000003, &axi_qos->qosconf);
1288502b92c1SNobuhiro Iwamatsu else
12891251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
12901251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
12911251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
12921251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
12931251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
12941251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
12951251e490SNobuhiro Iwamatsu
1296ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VSPD1W_BASE;
1297502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
1298502b92c1SNobuhiro Iwamatsu writel(0x00000003, &axi_qos->qosconf);
1299502b92c1SNobuhiro Iwamatsu else
13001251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
13011251e490SNobuhiro Iwamatsu writel(0x000020C8, &axi_qos->qosctset0);
13021251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
13031251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
13041251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
13051251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
13061251e490SNobuhiro Iwamatsu
1307ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_DU0R_BASE;
1308502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
1309502b92c1SNobuhiro Iwamatsu writel(0x00000003, &axi_qos->qosconf);
1310502b92c1SNobuhiro Iwamatsu else
13111251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
13121251e490SNobuhiro Iwamatsu writel(0x00002063, &axi_qos->qosctset0);
13131251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
13141251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
13151251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
13161251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
13171251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
13181251e490SNobuhiro Iwamatsu
1319ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_DU0W_BASE;
1320502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2())
1321502b92c1SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
1322502b92c1SNobuhiro Iwamatsu else
13231251e490SNobuhiro Iwamatsu writel(0x00000000, &axi_qos->qosconf);
13241251e490SNobuhiro Iwamatsu writel(0x00002063, &axi_qos->qosctset0);
13251251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosreqctr);
13261251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
13271251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
13281251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
13291251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
13301251e490SNobuhiro Iwamatsu
1331ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VCP0CR_BASE;
13321251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
13331251e490SNobuhiro Iwamatsu writel(0x00002073, &axi_qos->qosctset0);
13341251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
13351251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
13361251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
13371251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
13381251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
13391251e490SNobuhiro Iwamatsu
1340ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VCP0CW_BASE;
13411251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
13421251e490SNobuhiro Iwamatsu writel(0x00002073, &axi_qos->qosctset0);
13431251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
1344502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
1345502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres0);
1346502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres1);
1347502b92c1SNobuhiro Iwamatsu } else {
13481251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
13491251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
1350502b92c1SNobuhiro Iwamatsu }
13511251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
13521251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
13531251e490SNobuhiro Iwamatsu
1354ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VCP0VR_BASE;
13551251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
13561251e490SNobuhiro Iwamatsu writel(0x00002073, &axi_qos->qosctset0);
13571251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
13581251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
13591251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
13601251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
13611251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
13621251e490SNobuhiro Iwamatsu
1363ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VCP0VW_BASE;
13641251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
13651251e490SNobuhiro Iwamatsu writel(0x00002073, &axi_qos->qosctset0);
13661251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
1367502b92c1SNobuhiro Iwamatsu if (IS_R8A7791_ES2()) {
1368502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres0);
1369502b92c1SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres1);
1370502b92c1SNobuhiro Iwamatsu } else {
13711251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
13721251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
1373502b92c1SNobuhiro Iwamatsu }
13741251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
13751251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
13761251e490SNobuhiro Iwamatsu
1377ec9b386eSNobuhiro Iwamatsu axi_qos = (struct rcar_axi_qos *)MEDIA_AXI_VPC0R_BASE;
13781251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosconf);
13791251e490SNobuhiro Iwamatsu writel(0x00002073, &axi_qos->qosctset0);
13801251e490SNobuhiro Iwamatsu writel(0x00000020, &axi_qos->qosreqctr);
13811251e490SNobuhiro Iwamatsu writel(0x00002064, &axi_qos->qosthres0);
13821251e490SNobuhiro Iwamatsu writel(0x00002004, &axi_qos->qosthres1);
13831251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosthres2);
13841251e490SNobuhiro Iwamatsu writel(0x00000001, &axi_qos->qosqon);
13851251e490SNobuhiro Iwamatsu }
13861cc95f6eSNobuhiro Iwamatsu #else /* CONFIG_ARCH_RMOBILE_EXTRAM_BOOT */
qos_init(void)138769191fedSNobuhiro Iwamatsu void qos_init(void)
138869191fedSNobuhiro Iwamatsu {
138969191fedSNobuhiro Iwamatsu }
13901cc95f6eSNobuhiro Iwamatsu #endif /* CONFIG_ARCH_RMOBILE_EXTRAM_BOOT */
1391