2008-08-19 16:08:44 +08:00
|
|
|
/*
|
2011-09-15 06:01:21 +08:00
|
|
|
* OMAP2/3 clockdomain common data
|
2008-08-19 16:08:44 +08:00
|
|
|
*
|
2011-09-15 06:01:21 +08:00
|
|
|
* Copyright (C) 2008-2011 Texas Instruments, Inc.
|
2010-01-27 11:13:13 +08:00
|
|
|
* Copyright (C) 2008-2010 Nokia Corporation
|
2008-08-19 16:08:44 +08:00
|
|
|
*
|
2010-12-22 11:01:20 +08:00
|
|
|
* Paul Walmsley, Jouni Högander
|
2010-01-27 11:12:59 +08:00
|
|
|
*
|
|
|
|
* This file contains clockdomains and clockdomain wakeup/sleep
|
|
|
|
* dependencies for the OMAP2/3 chips. Some notes:
|
|
|
|
*
|
|
|
|
* A useful validation rule for struct clockdomain: Any clockdomain
|
|
|
|
* referenced by a wkdep_srcs or sleepdep_srcs array must have a
|
|
|
|
* dep_bit assigned. So wkdep_srcs/sleepdep_srcs are really just
|
|
|
|
* software-controllable dependencies. Non-software-controllable
|
|
|
|
* dependencies do exist, but they are not encoded below (yet).
|
|
|
|
*
|
|
|
|
* 24xx does not support programmable sleep dependencies (SLEEPDEP)
|
|
|
|
*
|
|
|
|
* The overly-specific dep_bit names are due to a bit name collision
|
|
|
|
* with CM_FCLKEN_{DSP,IVA2}. The DSP/IVA2 PM_WKDEP and CM_SLEEPDEP shift
|
|
|
|
* value are the same for all powerdomains: 2
|
|
|
|
*
|
|
|
|
* XXX should dep_bit be a mask, so we can test to see if it is 0 as a
|
|
|
|
* sanity check?
|
|
|
|
* XXX encode hardware fixed wakeup dependencies -- esp. for 3430 CORE
|
2008-08-19 16:08:44 +08:00
|
|
|
*/
|
|
|
|
|
2010-01-27 11:12:54 +08:00
|
|
|
/*
|
|
|
|
* To-Do List
|
|
|
|
* -> Port the Sleep/Wakeup dependencies for the domains
|
|
|
|
* from the Power domain framework
|
|
|
|
*/
|
|
|
|
|
2010-12-22 11:01:20 +08:00
|
|
|
#include <linux/kernel.h>
|
|
|
|
#include <linux/io.h>
|
2008-08-19 16:08:44 +08:00
|
|
|
|
2010-12-22 12:05:15 +08:00
|
|
|
#include "clockdomain.h"
|
2010-12-22 06:30:55 +08:00
|
|
|
#include "prm2xxx_3xxx.h"
|
|
|
|
#include "cm2xxx_3xxx.h"
|
2010-12-22 11:01:17 +08:00
|
|
|
#include "cm-regbits-24xx.h"
|
|
|
|
#include "cm-regbits-34xx.h"
|
|
|
|
#include "cm-regbits-44xx.h"
|
|
|
|
#include "prm-regbits-24xx.h"
|
|
|
|
#include "prm-regbits-34xx.h"
|
2008-08-19 16:08:44 +08:00
|
|
|
|
2010-01-27 11:12:59 +08:00
|
|
|
/*
|
|
|
|
* Clockdomain dependencies for wkdeps/sleepdeps
|
|
|
|
*
|
|
|
|
* XXX Hardware dependencies (e.g., dependencies that cannot be
|
|
|
|
* changed in software) are not included here yet, but should be.
|
|
|
|
*/
|
|
|
|
|
|
|
|
/* Wakeup dependency source arrays */
|
|
|
|
|
2011-09-15 06:01:21 +08:00
|
|
|
/* 2xxx-specific possible dependencies */
|
2010-01-27 11:12:59 +08:00
|
|
|
|
2011-09-15 06:01:21 +08:00
|
|
|
/* 2xxx PM_WKDEP_GFX: CORE, MPU, WKUP */
|
|
|
|
struct clkdm_dep gfx_24xx_wkdeps[] = {
|
|
|
|
{ .clkdm_name = "core_l3_clkdm" },
|
|
|
|
{ .clkdm_name = "core_l4_clkdm" },
|
|
|
|
{ .clkdm_name = "mpu_clkdm" },
|
|
|
|
{ .clkdm_name = "wkup_clkdm" },
|
2010-01-27 11:12:59 +08:00
|
|
|
{ NULL },
|
|
|
|
};
|
|
|
|
|
2011-09-15 06:01:21 +08:00
|
|
|
/* 2xxx PM_WKDEP_DSP: CORE, MPU, WKUP */
|
|
|
|
struct clkdm_dep dsp_24xx_wkdeps[] = {
|
|
|
|
{ .clkdm_name = "core_l3_clkdm" },
|
|
|
|
{ .clkdm_name = "core_l4_clkdm" },
|
|
|
|
{ .clkdm_name = "mpu_clkdm" },
|
|
|
|
{ .clkdm_name = "wkup_clkdm" },
|
2010-01-27 11:12:59 +08:00
|
|
|
{ NULL },
|
|
|
|
};
|
|
|
|
|
|
|
|
|
2008-08-19 16:08:44 +08:00
|
|
|
/*
|
|
|
|
* OMAP2/3-common clockdomains
|
2008-09-11 00:47:36 +08:00
|
|
|
*
|
|
|
|
* Even though the 2420 has a single PRCM module from the
|
|
|
|
* interconnect's perspective, internally it does appear to have
|
|
|
|
* separate PRM and CM clockdomains. The usual test case is
|
|
|
|
* sys_clkout/sys_clkout2.
|
2008-08-19 16:08:44 +08:00
|
|
|
*/
|
|
|
|
|
|
|
|
/* This is an implicit clockdomain - it is never defined as such in TRM */
|
2011-09-15 06:01:21 +08:00
|
|
|
struct clockdomain wkup_common_clkdm = {
|
2008-08-19 16:08:44 +08:00
|
|
|
.name = "wkup_clkdm",
|
2009-02-03 17:10:03 +08:00
|
|
|
.pwrdm = { .name = "wkup_pwrdm" },
|
2010-01-27 11:12:59 +08:00
|
|
|
.dep_bit = OMAP_EN_WKUP_SHIFT,
|
2008-08-19 16:08:44 +08:00
|
|
|
};
|