aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTaras Kondratiuk <taras@ti.com>2011-10-25 18:16:41 -0500
committerZiyann <jaraidaniel@gmail.com>2014-10-01 12:55:17 +0200
commitb6f983a2f024da6f62db479b2dd5e460a7efbf70 (patch)
treeb0333164c806857eb4f45fa8b67ddbc8daacfd76
parenta13903f85f394b45015bd215e17057ba8c8c7712 (diff)
downloadkernel_samsung_tuna-b6f983a2f024da6f62db479b2dd5e460a7efbf70.zip
kernel_samsung_tuna-b6f983a2f024da6f62db479b2dd5e460a7efbf70.tar.gz
kernel_samsung_tuna-b6f983a2f024da6f62db479b2dd5e460a7efbf70.tar.bz2
OMAP4: voltage: Add 4470 voltage definitions
Add structures containing OMAP4470 voltage supported and various voltage dependent data for each VDD. Data is based on Data Manual Operating Condition Addendum v0.2 for 4470. Change-Id: I8baa6ccf26786b4ee1764fe96f312ae7fb65ccbf Signed-off-by: Taras Kondratiuk <taras@ti.com>
-rw-r--r--arch/arm/mach-omap2/omap_opp_data.h5
-rw-r--r--arch/arm/mach-omap2/opp4xxx_data.c74
-rw-r--r--arch/arm/mach-omap2/voltagedomains44xx_data.c6
3 files changed, 85 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/omap_opp_data.h b/arch/arm/mach-omap2/omap_opp_data.h
index 37d16e1..8f3c713 100644
--- a/arch/arm/mach-omap2/omap_opp_data.h
+++ b/arch/arm/mach-omap2/omap_opp_data.h
@@ -103,10 +103,15 @@ extern struct omap_volt_data omap443x_vdd_core_volt_data[];
extern struct omap_volt_data omap446x_vdd_mpu_volt_data[];
extern struct omap_volt_data omap446x_vdd_iva_volt_data[];
extern struct omap_volt_data omap446x_vdd_core_volt_data[];
+extern struct omap_volt_data omap447x_vdd_mpu_volt_data[];
+extern struct omap_volt_data omap447x_vdd_iva_volt_data[];
+extern struct omap_volt_data omap447x_vdd_core_volt_data[];
extern struct omap_vdd_dep_info omap443x_vddmpu_dep_info[];
extern struct omap_vdd_dep_info omap443x_vddiva_dep_info[];
extern struct omap_vdd_dep_info omap446x_vddmpu_dep_info[];
extern struct omap_vdd_dep_info omap446x_vddiva_dep_info[];
+extern struct omap_vdd_dep_info omap447x_vddmpu_dep_info[];
+extern struct omap_vdd_dep_info omap447x_vddiva_dep_info[];
#endif /* __ARCH_ARM_MACH_OMAP2_OMAP_OPP_DATA_H */
diff --git a/arch/arm/mach-omap2/opp4xxx_data.c b/arch/arm/mach-omap2/opp4xxx_data.c
index f58db35..dc7043e 100644
--- a/arch/arm/mach-omap2/opp4xxx_data.c
+++ b/arch/arm/mach-omap2/opp4xxx_data.c
@@ -285,6 +285,80 @@ static struct omap_opp_def __initdata omap446x_opp_def_list[] = {
OPP_INITIALIZER("aess", "abe_clk", "iva", true, 196608000, OMAP4460_VDD_IVA_OPP100_UV),
};
+/*
+ * Structures containing OMAP4470 voltage supported and various
+ * voltage dependent data for each VDD.
+ */
+#define OMAP4470_VDD_MPU_OPP50_UV 1025000
+#define OMAP4470_VDD_MPU_OPP100_UV 1200000
+#define OMAP4470_VDD_MPU_OPPTURBO_UV 1312000
+#define OMAP4470_VDD_MPU_OPPNITRO_UV 1375000
+
+struct omap_volt_data omap447x_vdd_mpu_volt_data[] = {
+ VOLT_DATA_DEFINE(OMAP4470_VDD_MPU_OPP50_UV, OMAP44XX_CONTROL_FUSE_MPU_OPP50, 0xf4, 0x0c, OMAP_ABB_NOMINAL_OPP),
+ VOLT_DATA_DEFINE(OMAP4470_VDD_MPU_OPP100_UV, OMAP44XX_CONTROL_FUSE_MPU_OPP100, 0xf9, 0x16, OMAP_ABB_NOMINAL_OPP),
+ VOLT_DATA_DEFINE(OMAP4470_VDD_MPU_OPPTURBO_UV, OMAP44XX_CONTROL_FUSE_MPU_OPPTURBO, 0xfa, 0x23, OMAP_ABB_FAST_OPP),
+ VOLT_DATA_DEFINE(OMAP4470_VDD_MPU_OPPNITRO_UV, OMAP44XX_CONTROL_FUSE_MPU_OPPNITRO, 0xfa, 0x27, OMAP_ABB_FAST_OPP),
+ VOLT_DATA_DEFINE(0, 0, 0, 0, 0),
+};
+
+#define OMAP4470_VDD_IVA_OPP50_UV 950000
+#define OMAP4470_VDD_IVA_OPP100_UV 1137000
+#define OMAP4470_VDD_IVA_OPPTURBO_UV 1287000
+#define OMAP4470_VDD_IVA_OPPNITRO_UV 1375000
+
+struct omap_volt_data omap447x_vdd_iva_volt_data[] = {
+ VOLT_DATA_DEFINE(OMAP4470_VDD_IVA_OPP50_UV, OMAP44XX_CONTROL_FUSE_IVA_OPP50, 0xf4, 0x0c, OMAP_ABB_NOMINAL_OPP),
+ VOLT_DATA_DEFINE(OMAP4470_VDD_IVA_OPP100_UV, OMAP44XX_CONTROL_FUSE_IVA_OPP100, 0xf9, 0x16, OMAP_ABB_NOMINAL_OPP),
+ VOLT_DATA_DEFINE(OMAP4470_VDD_IVA_OPPTURBO_UV, OMAP44XX_CONTROL_FUSE_IVA_OPPTURBO, 0xfa, 0x23, OMAP_ABB_NOMINAL_OPP),
+ VOLT_DATA_DEFINE(OMAP4470_VDD_IVA_OPPNITRO_UV, OMAP44XX_CONTROL_FUSE_IVA_OPPNITRO, 0xfa, 0x23, OMAP_ABB_FAST_OPP),
+ VOLT_DATA_DEFINE(0, 0, 0, 0, 0),
+};
+
+#define OMAP4470_VDD_CORE_OPP50_UV 962000
+#define OMAP4470_VDD_CORE_OPP100_UV 1125000
+#define OMAP4470_VDD_CORE_OPP100_OV_UV 1250000
+
+struct omap_volt_data omap447x_vdd_core_volt_data[] = {
+ VOLT_DATA_DEFINE(OMAP4470_VDD_CORE_OPP50_UV, OMAP44XX_CONTROL_FUSE_CORE_OPP50, 0xf4, 0x0c, OMAP_ABB_NONE),
+ VOLT_DATA_DEFINE(OMAP4470_VDD_CORE_OPP100_UV, OMAP44XX_CONTROL_FUSE_CORE_OPP100, 0xf9, 0x16, OMAP_ABB_NONE),
+ VOLT_DATA_DEFINE(OMAP4470_VDD_CORE_OPP100_OV_UV, OMAP44XX_CONTROL_FUSE_CORE_OPP100OV, 0xf9, 0x16, OMAP_ABB_NONE),
+ VOLT_DATA_DEFINE(0, 0, 0, 0, 0),
+};
+
+/* OMAP 4470 MPU Core VDD dependency table */
+static struct omap_vdd_dep_volt omap447x_vdd_mpu_core_dep_data[] = {
+ {.main_vdd_volt = OMAP4470_VDD_MPU_OPP50_UV, .dep_vdd_volt = OMAP4470_VDD_CORE_OPP50_UV},
+ {.main_vdd_volt = OMAP4470_VDD_MPU_OPP100_UV, .dep_vdd_volt = OMAP4470_VDD_CORE_OPP100_UV},
+ {.main_vdd_volt = OMAP4470_VDD_MPU_OPPTURBO_UV, .dep_vdd_volt = OMAP4470_VDD_CORE_OPP100_UV},
+ {.main_vdd_volt = OMAP4470_VDD_MPU_OPPNITRO_UV, .dep_vdd_volt = OMAP4470_VDD_CORE_OPP100_UV},
+};
+
+struct omap_vdd_dep_info omap447x_vddmpu_dep_info[] = {
+ {
+ .name = "core",
+ .dep_table = omap447x_vdd_mpu_core_dep_data,
+ .nr_dep_entries = ARRAY_SIZE(omap447x_vdd_mpu_core_dep_data),
+ },
+ {.name = NULL, .dep_table = NULL, .nr_dep_entries = 0},
+};
+
+/* OMAP 4470 MPU IVA VDD dependency table */
+static struct omap_vdd_dep_volt omap447x_vdd_iva_core_dep_data[] = {
+ {.main_vdd_volt = OMAP4470_VDD_IVA_OPP50_UV, .dep_vdd_volt = OMAP4470_VDD_CORE_OPP50_UV},
+ {.main_vdd_volt = OMAP4470_VDD_IVA_OPP100_UV, .dep_vdd_volt = OMAP4470_VDD_CORE_OPP100_UV},
+ {.main_vdd_volt = OMAP4470_VDD_IVA_OPPTURBO_UV, .dep_vdd_volt = OMAP4470_VDD_CORE_OPP100_UV},
+ {.main_vdd_volt = OMAP4470_VDD_IVA_OPPNITRO_UV, .dep_vdd_volt = OMAP4470_VDD_CORE_OPP100_UV},
+};
+
+struct omap_vdd_dep_info omap447x_vddiva_dep_info[] = {
+ {
+ .name = "core",
+ .dep_table = omap447x_vdd_iva_core_dep_data,
+ .nr_dep_entries = ARRAY_SIZE(omap447x_vdd_iva_core_dep_data),
+ },
+ {.name = NULL, .dep_table = NULL, .nr_dep_entries = 0},
+};
/**
* omap4_mpu_opp_enable() - helper to enable the OPP
* @freq: frequency to enable
diff --git a/arch/arm/mach-omap2/voltagedomains44xx_data.c b/arch/arm/mach-omap2/voltagedomains44xx_data.c
index dc5026e..aba2090 100644
--- a/arch/arm/mach-omap2/voltagedomains44xx_data.c
+++ b/arch/arm/mach-omap2/voltagedomains44xx_data.c
@@ -155,6 +155,12 @@ void __init omap44xx_voltagedomains_init(void)
omap4_vdd_core_info.volt_data = omap446x_vdd_core_volt_data;
omap4_vdd_mpu_info.dep_vdd_info = omap446x_vddmpu_dep_info;
omap4_vdd_iva_info.dep_vdd_info = omap446x_vddiva_dep_info;
+ } else if (cpu_is_omap447x()) {
+ omap4_vdd_mpu_info.volt_data = omap447x_vdd_mpu_volt_data;
+ omap4_vdd_iva_info.volt_data = omap447x_vdd_iva_volt_data;
+ omap4_vdd_core_info.volt_data = omap447x_vdd_core_volt_data;
+ omap4_vdd_mpu_info.dep_vdd_info = omap447x_vddmpu_dep_info;
+ omap4_vdd_iva_info.dep_vdd_info = omap447x_vddiva_dep_info;
} else {
return;
}