1 // SPDX-License-Identifier: GPL-2.0-only
3 * OMAP2XXX powerdomain definitions
5 * Copyright (C) 2007-2008, 2011 Texas Instruments, Inc.
6 * Copyright (C) 2007-2011 Nokia Corporation
8 * Paul Walmsley, Jouni Högander
11 #include <linux/kernel.h>
12 #include <linux/init.h>
15 #include "powerdomain.h"
16 #include "powerdomains2xxx_3xxx_data.h"
18 #include "prcm-common.h"
19 #include "prm2xxx_3xxx.h"
20 #include "prm-regbits-24xx.h"
22 /* 24XX powerdomains and dependencies */
26 static struct powerdomain dsp_pwrdm
= {
28 .prcm_offs
= OMAP24XX_DSP_MOD
,
29 .pwrsts
= PWRSTS_OFF_RET_ON
,
30 .pwrsts_logic_ret
= PWRSTS_RET
,
38 .voltdm
= { .name
= "core" },
41 static struct powerdomain mpu_24xx_pwrdm
= {
44 .pwrsts
= PWRSTS_OFF_RET_ON
,
45 .pwrsts_logic_ret
= PWRSTS_OFF_RET
,
53 .voltdm
= { .name
= "core" },
56 static struct powerdomain core_24xx_pwrdm
= {
58 .prcm_offs
= CORE_MOD
,
59 .pwrsts
= PWRSTS_OFF_RET_ON
,
60 .pwrsts_logic_ret
= PWRSTS_RET
,
63 [0] = PWRSTS_OFF_RET
, /* MEM1RETSTATE */
64 [1] = PWRSTS_OFF_RET
, /* MEM2RETSTATE */
65 [2] = PWRSTS_OFF_RET
, /* MEM3RETSTATE */
68 [0] = PWRSTS_OFF_RET_ON
, /* MEM1ONSTATE */
69 [1] = PWRSTS_OFF_RET_ON
, /* MEM2ONSTATE */
70 [2] = PWRSTS_OFF_RET_ON
, /* MEM3ONSTATE */
72 .voltdm
= { .name
= "core" },
77 * 2430-specific powerdomains
80 /* XXX 2430 KILLDOMAINWKUP bit? No current users apparently */
82 static struct powerdomain mdm_pwrdm
= {
84 .prcm_offs
= OMAP2430_MDM_MOD
,
85 .pwrsts
= PWRSTS_OFF_RET_ON
,
86 .pwrsts_logic_ret
= PWRSTS_RET
,
89 [0] = PWRSTS_RET
, /* MEMRETSTATE */
92 [0] = PWRSTS_ON
, /* MEMONSTATE */
94 .voltdm
= { .name
= "core" },
101 static struct powerdomain
*powerdomains_omap24xx
[] __initdata
= {
110 static struct powerdomain
*powerdomains_omap2430
[] __initdata
= {
115 void __init
omap242x_powerdomains_init(void)
117 if (!cpu_is_omap2420())
120 pwrdm_register_platform_funcs(&omap2_pwrdm_operations
);
121 pwrdm_register_pwrdms(powerdomains_omap24xx
);
122 pwrdm_complete_init();
125 void __init
omap243x_powerdomains_init(void)
127 if (!cpu_is_omap2430())
130 pwrdm_register_platform_funcs(&omap2_pwrdm_operations
);
131 pwrdm_register_pwrdms(powerdomains_omap24xx
);
132 pwrdm_register_pwrdms(powerdomains_omap2430
);
133 pwrdm_complete_init();