162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0-only */
262306a36Sopenharmony_ci
362306a36Sopenharmony_ci#ifndef __SOC_MEDIATEK_MT8192_PM_DOMAINS_H
462306a36Sopenharmony_ci#define __SOC_MEDIATEK_MT8192_PM_DOMAINS_H
562306a36Sopenharmony_ci
662306a36Sopenharmony_ci#include "mtk-pm-domains.h"
762306a36Sopenharmony_ci#include <dt-bindings/power/mt8192-power.h>
862306a36Sopenharmony_ci
962306a36Sopenharmony_ci/*
1062306a36Sopenharmony_ci * MT8192 power domain support
1162306a36Sopenharmony_ci */
1262306a36Sopenharmony_ci
1362306a36Sopenharmony_cistatic const struct scpsys_domain_data scpsys_domain_data_mt8192[] = {
1462306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_AUDIO] = {
1562306a36Sopenharmony_ci		.name = "audio",
1662306a36Sopenharmony_ci		.sta_mask = BIT(21),
1762306a36Sopenharmony_ci		.ctl_offs = 0x0354,
1862306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
1962306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
2062306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
2162306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
2262306a36Sopenharmony_ci		.bp_infracfg = {
2362306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_2_AUDIO,
2462306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_SET,
2562306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_CLR,
2662306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_STA1),
2762306a36Sopenharmony_ci		},
2862306a36Sopenharmony_ci	},
2962306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_CONN] = {
3062306a36Sopenharmony_ci		.name = "conn",
3162306a36Sopenharmony_ci		.sta_mask = PWR_STATUS_CONN,
3262306a36Sopenharmony_ci		.ctl_offs = 0x0304,
3362306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
3462306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
3562306a36Sopenharmony_ci		.sram_pdn_bits = 0,
3662306a36Sopenharmony_ci		.sram_pdn_ack_bits = 0,
3762306a36Sopenharmony_ci		.bp_infracfg = {
3862306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_CONN,
3962306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_SET,
4062306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_CLR,
4162306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_STA1),
4262306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_CONN_2ND,
4362306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_SET,
4462306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_CLR,
4562306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_STA1),
4662306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_1_CONN,
4762306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_1_SET,
4862306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_1_CLR,
4962306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_1_STA1),
5062306a36Sopenharmony_ci		},
5162306a36Sopenharmony_ci		.caps = MTK_SCPD_KEEP_DEFAULT_OFF,
5262306a36Sopenharmony_ci	},
5362306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_MFG0] = {
5462306a36Sopenharmony_ci		.name = "mfg0",
5562306a36Sopenharmony_ci		.sta_mask = BIT(2),
5662306a36Sopenharmony_ci		.ctl_offs = 0x0308,
5762306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
5862306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
5962306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
6062306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
6162306a36Sopenharmony_ci		.caps = MTK_SCPD_DOMAIN_SUPPLY,
6262306a36Sopenharmony_ci	},
6362306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_MFG1] = {
6462306a36Sopenharmony_ci		.name = "mfg1",
6562306a36Sopenharmony_ci		.sta_mask = BIT(3),
6662306a36Sopenharmony_ci		.ctl_offs = 0x030c,
6762306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
6862306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
6962306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
7062306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
7162306a36Sopenharmony_ci		.bp_infracfg = {
7262306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_1_MFG1,
7362306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_1_SET,
7462306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_1_CLR,
7562306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_1_STA1),
7662306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_2_MFG1,
7762306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_SET,
7862306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_CLR,
7962306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_STA1),
8062306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MFG1,
8162306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_SET,
8262306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_CLR,
8362306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_STA1),
8462306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_2_MFG1_2ND,
8562306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_SET,
8662306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_CLR,
8762306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_STA1),
8862306a36Sopenharmony_ci		},
8962306a36Sopenharmony_ci		.caps = MTK_SCPD_DOMAIN_SUPPLY,
9062306a36Sopenharmony_ci	},
9162306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_MFG2] = {
9262306a36Sopenharmony_ci		.name = "mfg2",
9362306a36Sopenharmony_ci		.sta_mask = BIT(4),
9462306a36Sopenharmony_ci		.ctl_offs = 0x0310,
9562306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
9662306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
9762306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
9862306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
9962306a36Sopenharmony_ci	},
10062306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_MFG3] = {
10162306a36Sopenharmony_ci		.name = "mfg3",
10262306a36Sopenharmony_ci		.sta_mask = BIT(5),
10362306a36Sopenharmony_ci		.ctl_offs = 0x0314,
10462306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
10562306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
10662306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
10762306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
10862306a36Sopenharmony_ci	},
10962306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_MFG4] = {
11062306a36Sopenharmony_ci		.name = "mfg4",
11162306a36Sopenharmony_ci		.sta_mask = BIT(6),
11262306a36Sopenharmony_ci		.ctl_offs = 0x0318,
11362306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
11462306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
11562306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
11662306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
11762306a36Sopenharmony_ci	},
11862306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_MFG5] = {
11962306a36Sopenharmony_ci		.name = "mfg5",
12062306a36Sopenharmony_ci		.sta_mask = BIT(7),
12162306a36Sopenharmony_ci		.ctl_offs = 0x031c,
12262306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
12362306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
12462306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
12562306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
12662306a36Sopenharmony_ci	},
12762306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_MFG6] = {
12862306a36Sopenharmony_ci		.name = "mfg6",
12962306a36Sopenharmony_ci		.sta_mask = BIT(8),
13062306a36Sopenharmony_ci		.ctl_offs = 0x0320,
13162306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
13262306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
13362306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
13462306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
13562306a36Sopenharmony_ci	},
13662306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_DISP] = {
13762306a36Sopenharmony_ci		.name = "disp",
13862306a36Sopenharmony_ci		.sta_mask = BIT(20),
13962306a36Sopenharmony_ci		.ctl_offs = 0x0350,
14062306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
14162306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
14262306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
14362306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
14462306a36Sopenharmony_ci		.bp_infracfg = {
14562306a36Sopenharmony_ci			BUS_PROT_WR_IGN(MT8192_TOP_AXI_PROT_EN_MM_DISP,
14662306a36Sopenharmony_ci					MT8192_TOP_AXI_PROT_EN_MM_SET,
14762306a36Sopenharmony_ci					MT8192_TOP_AXI_PROT_EN_MM_CLR,
14862306a36Sopenharmony_ci					MT8192_TOP_AXI_PROT_EN_MM_STA1),
14962306a36Sopenharmony_ci			BUS_PROT_WR_IGN(MT8192_TOP_AXI_PROT_EN_MM_2_DISP,
15062306a36Sopenharmony_ci					MT8192_TOP_AXI_PROT_EN_MM_2_SET,
15162306a36Sopenharmony_ci					MT8192_TOP_AXI_PROT_EN_MM_2_CLR,
15262306a36Sopenharmony_ci					MT8192_TOP_AXI_PROT_EN_MM_2_STA1),
15362306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_DISP,
15462306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_SET,
15562306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_CLR,
15662306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_STA1),
15762306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_DISP_2ND,
15862306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_SET,
15962306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_CLR,
16062306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_STA1),
16162306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_2_DISP_2ND,
16262306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_SET,
16362306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_CLR,
16462306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_STA1),
16562306a36Sopenharmony_ci		},
16662306a36Sopenharmony_ci	},
16762306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_IPE] = {
16862306a36Sopenharmony_ci		.name = "ipe",
16962306a36Sopenharmony_ci		.sta_mask = BIT(14),
17062306a36Sopenharmony_ci		.ctl_offs = 0x0338,
17162306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
17262306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
17362306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
17462306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
17562306a36Sopenharmony_ci		.bp_infracfg = {
17662306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_IPE,
17762306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_SET,
17862306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_CLR,
17962306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_STA1),
18062306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_IPE_2ND,
18162306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_SET,
18262306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_CLR,
18362306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_STA1),
18462306a36Sopenharmony_ci		},
18562306a36Sopenharmony_ci	},
18662306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_ISP] = {
18762306a36Sopenharmony_ci		.name = "isp",
18862306a36Sopenharmony_ci		.sta_mask = BIT(12),
18962306a36Sopenharmony_ci		.ctl_offs = 0x0330,
19062306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
19162306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
19262306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
19362306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
19462306a36Sopenharmony_ci		.bp_infracfg = {
19562306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_2_ISP,
19662306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_SET,
19762306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_CLR,
19862306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_STA1),
19962306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_2_ISP_2ND,
20062306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_SET,
20162306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_CLR,
20262306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_STA1),
20362306a36Sopenharmony_ci		},
20462306a36Sopenharmony_ci	},
20562306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_ISP2] = {
20662306a36Sopenharmony_ci		.name = "isp2",
20762306a36Sopenharmony_ci		.sta_mask = BIT(13),
20862306a36Sopenharmony_ci		.ctl_offs = 0x0334,
20962306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
21062306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
21162306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
21262306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
21362306a36Sopenharmony_ci		.bp_infracfg = {
21462306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_ISP2,
21562306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_SET,
21662306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_CLR,
21762306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_STA1),
21862306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_ISP2_2ND,
21962306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_SET,
22062306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_CLR,
22162306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_STA1),
22262306a36Sopenharmony_ci		},
22362306a36Sopenharmony_ci	},
22462306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_MDP] = {
22562306a36Sopenharmony_ci		.name = "mdp",
22662306a36Sopenharmony_ci		.sta_mask = BIT(19),
22762306a36Sopenharmony_ci		.ctl_offs = 0x034c,
22862306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
22962306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
23062306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
23162306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
23262306a36Sopenharmony_ci		.bp_infracfg = {
23362306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_2_MDP,
23462306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_SET,
23562306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_CLR,
23662306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_STA1),
23762306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_2_MDP_2ND,
23862306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_SET,
23962306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_CLR,
24062306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_2_STA1),
24162306a36Sopenharmony_ci		},
24262306a36Sopenharmony_ci	},
24362306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_VENC] = {
24462306a36Sopenharmony_ci		.name = "venc",
24562306a36Sopenharmony_ci		.sta_mask = BIT(17),
24662306a36Sopenharmony_ci		.ctl_offs = 0x0344,
24762306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
24862306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
24962306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
25062306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
25162306a36Sopenharmony_ci		.bp_infracfg = {
25262306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_VENC,
25362306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_SET,
25462306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_CLR,
25562306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_STA1),
25662306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_VENC_2ND,
25762306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_SET,
25862306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_CLR,
25962306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_STA1),
26062306a36Sopenharmony_ci		},
26162306a36Sopenharmony_ci	},
26262306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_VDEC] = {
26362306a36Sopenharmony_ci		.name = "vdec",
26462306a36Sopenharmony_ci		.sta_mask = BIT(15),
26562306a36Sopenharmony_ci		.ctl_offs = 0x033c,
26662306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
26762306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
26862306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
26962306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
27062306a36Sopenharmony_ci		.bp_infracfg = {
27162306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_VDEC,
27262306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_SET,
27362306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_CLR,
27462306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_STA1),
27562306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_VDEC_2ND,
27662306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_SET,
27762306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_CLR,
27862306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_STA1),
27962306a36Sopenharmony_ci		},
28062306a36Sopenharmony_ci	},
28162306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_VDEC2] = {
28262306a36Sopenharmony_ci		.name = "vdec2",
28362306a36Sopenharmony_ci		.sta_mask = BIT(16),
28462306a36Sopenharmony_ci		.ctl_offs = 0x0340,
28562306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
28662306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
28762306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
28862306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
28962306a36Sopenharmony_ci	},
29062306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_CAM] = {
29162306a36Sopenharmony_ci		.name = "cam",
29262306a36Sopenharmony_ci		.sta_mask = BIT(23),
29362306a36Sopenharmony_ci		.ctl_offs = 0x035c,
29462306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
29562306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
29662306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
29762306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
29862306a36Sopenharmony_ci		.bp_infracfg = {
29962306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_2_CAM,
30062306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_SET,
30162306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_CLR,
30262306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_2_STA1),
30362306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_CAM,
30462306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_SET,
30562306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_CLR,
30662306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_STA1),
30762306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_1_CAM,
30862306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_1_SET,
30962306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_1_CLR,
31062306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_1_STA1),
31162306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_MM_CAM_2ND,
31262306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_SET,
31362306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_CLR,
31462306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_MM_STA1),
31562306a36Sopenharmony_ci			BUS_PROT_WR(MT8192_TOP_AXI_PROT_EN_VDNR_CAM,
31662306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_VDNR_SET,
31762306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_VDNR_CLR,
31862306a36Sopenharmony_ci				    MT8192_TOP_AXI_PROT_EN_VDNR_STA1),
31962306a36Sopenharmony_ci		},
32062306a36Sopenharmony_ci	},
32162306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_CAM_RAWA] = {
32262306a36Sopenharmony_ci		.name = "cam_rawa",
32362306a36Sopenharmony_ci		.sta_mask = BIT(24),
32462306a36Sopenharmony_ci		.ctl_offs = 0x0360,
32562306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
32662306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
32762306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
32862306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
32962306a36Sopenharmony_ci	},
33062306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_CAM_RAWB] = {
33162306a36Sopenharmony_ci		.name = "cam_rawb",
33262306a36Sopenharmony_ci		.sta_mask = BIT(25),
33362306a36Sopenharmony_ci		.ctl_offs = 0x0364,
33462306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
33562306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
33662306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
33762306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
33862306a36Sopenharmony_ci	},
33962306a36Sopenharmony_ci	[MT8192_POWER_DOMAIN_CAM_RAWC] = {
34062306a36Sopenharmony_ci		.name = "cam_rawc",
34162306a36Sopenharmony_ci		.sta_mask = BIT(26),
34262306a36Sopenharmony_ci		.ctl_offs = 0x0368,
34362306a36Sopenharmony_ci		.pwr_sta_offs = 0x016c,
34462306a36Sopenharmony_ci		.pwr_sta2nd_offs = 0x0170,
34562306a36Sopenharmony_ci		.sram_pdn_bits = GENMASK(8, 8),
34662306a36Sopenharmony_ci		.sram_pdn_ack_bits = GENMASK(12, 12),
34762306a36Sopenharmony_ci	},
34862306a36Sopenharmony_ci};
34962306a36Sopenharmony_ci
35062306a36Sopenharmony_cistatic const struct scpsys_soc_data mt8192_scpsys_data = {
35162306a36Sopenharmony_ci	.domains_data = scpsys_domain_data_mt8192,
35262306a36Sopenharmony_ci	.num_domains = ARRAY_SIZE(scpsys_domain_data_mt8192),
35362306a36Sopenharmony_ci};
35462306a36Sopenharmony_ci
35562306a36Sopenharmony_ci#endif /* __SOC_MEDIATEK_MT8192_PM_DOMAINS_H */
356