1 /* SPDX-License-Identifier: GPL-2.0-only */
3 #include <device/mmio.h>
4 #include <soc/infracfg.h>
5 #include <soc/mtcmos.h>
9 DISP_PROT_STEP_2_MASK
= 0x00000C06,
10 DISP_PROT_STEP_1_MASK
= 0x00001800,
14 TOP_AXI_PROT_EN_3_ADSP_TOP_STEP1
= 0x00001800,
15 TOP_AXI_PROT_EN_3_ADSP_TOP_STEP2
= 0x00000003,
18 void mtcmos_adsp_power_on(void)
22 for (i
= 0; i
< ARRAY_SIZE(adsp
); i
++)
23 mtcmos_power_on(&adsp
[i
]);
26 void mtcmos_protect_display_bus(void)
28 write32(&mt8186_infracfg_ao
->infra_topaxi_protecten_clr
,
29 DISP_PROT_STEP_2_MASK
);
30 write32(&mt8186_infracfg_ao
->infra_topaxi_protecten_1_clr
,
31 DISP_PROT_STEP_1_MASK
);
34 void mtcmos_protect_audio_bus(void)
36 /* No need to do protection since MT8186 doesn't have audio mtcmos. */
39 void mtcmos_protect_adsp_bus(void)
41 write32(&mt8186_infracfg_ao
->infra_topaxi_protecten_3_clr
,
42 TOP_AXI_PROT_EN_3_ADSP_TOP_STEP2
);
43 write32(&mt8186_infracfg_ao
->infra_topaxi_protecten_3_clr
,
44 TOP_AXI_PROT_EN_3_ADSP_TOP_STEP1
);