blob: 105cbcaefd3b687d4c38ffc6044452ff17b5e92c [file] [log] [blame]
Paul Walmsley97171002008-08-19 11:08:40 +03001/*
2 * OMAP2/3 common powerdomain definitions
3 *
Paul Walmsley55ed9692010-01-26 20:12:59 -07004 * Copyright (C) 2007-2008 Texas Instruments, Inc.
5 * Copyright (C) 2007-2009 Nokia Corporation
Paul Walmsley97171002008-08-19 11:08:40 +03006 *
7 * Written by Paul Walmsley
8 * Debugging and integration fixes by Jouni Högander
9 *
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License version 2 as
12 * published by the Free Software Foundation.
13 */
14
Abhijit Pagare38900c22010-01-26 20:12:52 -070015/*
16 * To Do List
17 * -> Move the Sleep/Wakeup dependencies from Power Domain framework to
18 * Clock Domain Framework
19 */
20
Paul Walmsley97171002008-08-19 11:08:40 +030021#ifndef ARCH_ARM_MACH_OMAP2_POWERDOMAINS
22#define ARCH_ARM_MACH_OMAP2_POWERDOMAINS
23
24/*
25 * This file contains all of the powerdomains that have some element
Paul Walmsley98fa3d82010-01-26 20:13:13 -070026 * of software control for the OMAP24xx and OMAP34xx chips.
Paul Walmsley97171002008-08-19 11:08:40 +030027 *
Paul Walmsley97171002008-08-19 11:08:40 +030028 * This is not an exhaustive listing of powerdomains on the chips; only
29 * powerdomains that can be controlled in software.
Paul Walmsley97171002008-08-19 11:08:40 +030030 */
31
32/*
33 * The names for the DSP/IVA2 powerdomains are confusing.
34 *
35 * Most OMAP chips have an on-board DSP.
36 *
37 * On the 2420, this is a 'C55 DSP called, simply, the DSP. Its
38 * powerdomain is called the "DSP power domain." On the 2430, the
Paul Walmsley55ed9692010-01-26 20:12:59 -070039 * on-board DSP is a 'C64 DSP, now called (along with its hardware
40 * accelerators) the IVA2 or IVA2.1. Its powerdomain is still called
41 * the "DSP power domain." On the 3430, the DSP is a 'C64 DSP like the
42 * 2430, also known as the IVA2; but its powerdomain is now called the
43 * "IVA2 power domain."
Paul Walmsley97171002008-08-19 11:08:40 +030044 *
45 * The 2420 also has something called the IVA, which is a separate ARM
46 * core, and has nothing to do with the DSP/IVA2.
47 *
48 * Ideally the DSP/IVA2 could just be the same powerdomain, but the PRCM
49 * address offset is different between the C55 and C64 DSPs.
Paul Walmsley97171002008-08-19 11:08:40 +030050 */
51
Tony Lindgrence491cf2009-10-20 09:40:47 -070052#include <plat/powerdomain.h>
Paul Walmsley97171002008-08-19 11:08:40 +030053
54#include "prcm-common.h"
55#include "prm.h"
56#include "cm.h"
Paul Walmsleyfe6a58f2008-08-19 11:08:42 +030057#include "powerdomains24xx.h"
Paul Walmsleyecb24aa2008-08-19 11:08:43 +030058#include "powerdomains34xx.h"
Abhijit Pagare38900c22010-01-26 20:12:52 -070059#include "powerdomains44xx.h"
Paul Walmsleyfe6a58f2008-08-19 11:08:42 +030060
Paul Walmsley55ed9692010-01-26 20:12:59 -070061/* OMAP2/3-common powerdomains */
Paul Walmsley97171002008-08-19 11:08:40 +030062
Paul Walmsley98fa3d82010-01-26 20:13:13 -070063#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
Abhijit Pagare38900c22010-01-26 20:12:52 -070064
Paul Walmsley97171002008-08-19 11:08:40 +030065/*
66 * The GFX powerdomain is not present on 3430ES2, but currently we do not
67 * have a macro to filter it out at compile-time.
68 */
Abhijit Pagare38900c22010-01-26 20:12:52 -070069static struct powerdomain gfx_omap2_pwrdm = {
Paul Walmsley97171002008-08-19 11:08:40 +030070 .name = "gfx_pwrdm",
71 .prcm_offs = GFX_MOD,
72 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX |
73 CHIP_IS_OMAP3430ES1),
Paul Walmsley97171002008-08-19 11:08:40 +030074 .pwrsts = PWRSTS_OFF_RET_ON,
75 .pwrsts_logic_ret = PWRDM_POWER_RET,
76 .banks = 1,
77 .pwrsts_mem_ret = {
78 [0] = PWRDM_POWER_RET, /* MEMRETSTATE */
79 },
80 .pwrsts_mem_on = {
81 [0] = PWRDM_POWER_ON, /* MEMONSTATE */
82 },
83};
84
Abhijit Pagare38900c22010-01-26 20:12:52 -070085static struct powerdomain wkup_omap2_pwrdm = {
Paul Walmsley97171002008-08-19 11:08:40 +030086 .name = "wkup_pwrdm",
87 .prcm_offs = WKUP_MOD,
88 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX | CHIP_IS_OMAP3430),
Paul Walmsley97171002008-08-19 11:08:40 +030089};
90
Abhijit Pagare38900c22010-01-26 20:12:52 -070091#endif
Paul Walmsley97171002008-08-19 11:08:40 +030092
93
94/* As powerdomains are added or removed above, this list must also be changed */
95static struct powerdomain *powerdomains_omap[] __initdata = {
96
Paul Walmsley98fa3d82010-01-26 20:13:13 -070097#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
Abhijit Pagare38900c22010-01-26 20:12:52 -070098 &wkup_omap2_pwrdm,
99 &gfx_omap2_pwrdm,
100#endif
Paul Walmsley97171002008-08-19 11:08:40 +0300101
Paul Walmsley98fa3d82010-01-26 20:13:13 -0700102#ifdef CONFIG_ARCH_OMAP2
Paul Walmsleyfe6a58f2008-08-19 11:08:42 +0300103 &dsp_pwrdm,
104 &mpu_24xx_pwrdm,
105 &core_24xx_pwrdm,
106#endif
107
108#ifdef CONFIG_ARCH_OMAP2430
109 &mdm_pwrdm,
110#endif
111
Paul Walmsley98fa3d82010-01-26 20:13:13 -0700112#ifdef CONFIG_ARCH_OMAP3
Paul Walmsleyecb24aa2008-08-19 11:08:43 +0300113 &iva2_pwrdm,
Paul Walmsley98fa3d82010-01-26 20:13:13 -0700114 &mpu_3xxx_pwrdm,
Paul Walmsleyecb24aa2008-08-19 11:08:43 +0300115 &neon_pwrdm,
Paul Walmsley98fa3d82010-01-26 20:13:13 -0700116 &core_3xxx_pre_es3_1_pwrdm,
117 &core_3xxx_es3_1_pwrdm,
Paul Walmsleyecb24aa2008-08-19 11:08:43 +0300118 &cam_pwrdm,
119 &dss_pwrdm,
120 &per_pwrdm,
121 &emu_pwrdm,
122 &sgx_pwrdm,
123 &usbhost_pwrdm,
Paul Walmsley46e0ccf2009-01-27 19:44:18 -0700124 &dpll1_pwrdm,
125 &dpll2_pwrdm,
126 &dpll3_pwrdm,
127 &dpll4_pwrdm,
128 &dpll5_pwrdm,
Paul Walmsleyecb24aa2008-08-19 11:08:43 +0300129#endif
130
Abhijit Pagare38900c22010-01-26 20:12:52 -0700131#ifdef CONFIG_ARCH_OMAP4
132 &core_44xx_pwrdm,
133 &gfx_44xx_pwrdm,
134 &abe_44xx_pwrdm,
135 &dss_44xx_pwrdm,
136 &tesla_44xx_pwrdm,
137 &wkup_44xx_pwrdm,
138 &cpu0_44xx_pwrdm,
139 &cpu1_44xx_pwrdm,
140 &emu_44xx_pwrdm,
141 &mpu_44xx_pwrdm,
142 &ivahd_44xx_pwrdm,
143 &cam_44xx_pwrdm,
144 &l3init_44xx_pwrdm,
145 &l4per_44xx_pwrdm,
146 &always_on_core_44xx_pwrdm,
147 &cefuse_44xx_pwrdm,
148#endif
Paul Walmsley97171002008-08-19 11:08:40 +0300149 NULL
150};
151
152
153#endif