From: Kevin Hilman <khilman@deeprootsystems.com>
To: linux-omap@vger.kernel.org
Cc: nm@ti.com, thara@ti.com, b-cousson@ti.com
Subject: [PATCH 10/12] OMAP: voltage: update to new device-based OPP API
Date: Wed, 16 Jun 2010 17:17:11 -0700 [thread overview]
Message-ID: <1276733833-18510-11-git-send-email-khilman@deeprootsystems.com> (raw)
In-Reply-To: <1276733833-18510-1-git-send-email-khilman@deeprootsystems.com>
The OPP API has changed to a device-based API. This patch updates
the usage of that API in the voltage layer.
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
---
arch/arm/mach-omap2/voltage.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/arch/arm/mach-omap2/voltage.c b/arch/arm/mach-omap2/voltage.c
index 6e84ea1..d289691 100644
--- a/arch/arm/mach-omap2/voltage.c
+++ b/arch/arm/mach-omap2/voltage.c
@@ -102,7 +102,7 @@ struct vp_reg_val {
* @vp_reg : the register values, shifts, masks for various
* vp registers
* @volt_clk : the clock associated with the vdd.
- * @opp_type : the type of OPP associated with this vdd.
+ * @opp_dev : the 'struct device' associated with this vdd.
* @volt_data_count : Number of distinct voltages supported by this vdd.
* @nominal_volt : Nominal voltaged for this vdd.
* cmdval_reg : Voltage controller cmdval register.
@@ -113,7 +113,7 @@ struct omap_vdd_info{
struct vp_reg_offs vp_offs;
struct vp_reg_val vp_reg;
struct clk *volt_clk;
- int opp_type;
+ struct device *opp_dev;
int volt_data_count;
int id;
unsigned long nominal_volt;
@@ -385,7 +385,7 @@ static void __init omap3_vdd_data_configure(int vdd)
vdd_info[vdd].volt_clk = clk_get(NULL, "dpll1_ck");
WARN(IS_ERR(vdd_info[vdd].volt_clk),
"unable to get clock for VDD%d\n", vdd + 1);
- vdd_info[vdd].opp_type = OPP_MPU;
+ vdd_info[vdd].opp_dev = omap_get_mpu_device();
vdd_info[vdd].vp_reg.tranxdone_status =
OMAP3430_VP1_TRANXDONE_ST_MASK;
vdd_info[vdd].cmdval_reg = OMAP3_PRM_VC_CMD_VAL_0_OFFSET;
@@ -411,7 +411,7 @@ static void __init omap3_vdd_data_configure(int vdd)
vdd_info[vdd].volt_clk = clk_get(NULL, "l3_ick");
WARN(IS_ERR(vdd_info[vdd].volt_clk),
"unable to get clock for VDD%d\n", vdd + 1);
- vdd_info[vdd].opp_type = OPP_L3;
+ vdd_info[vdd].opp_dev = omap_get_l3_device();
vdd_info[vdd].vp_reg.tranxdone_status =
OMAP3430_VP2_TRANXDONE_ST_MASK;
vdd_info[vdd].cmdval_reg = OMAP3_PRM_VC_CMD_VAL_1_OFFSET;
@@ -843,7 +843,7 @@ unsigned long get_curr_voltage(int vdd)
}
freq = vdd_info[vdd].volt_clk->rate;
- opp = opp_find_freq_ceil(vdd_info[vdd].opp_type, &freq);
+ opp = opp_find_freq_ceil(vdd_info[vdd].opp_dev, &freq);
if (IS_ERR(opp)) {
pr_warning("%s: Unable to find OPP for VDD%d freq%ld\n",
__func__, vdd + 1, freq);
--
1.7.0.2
next prev parent reply other threads:[~2010-06-17 0:17 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-17 0:17 [PATCH 00/12] rework OPP layer to handle device-based OPPs Kevin Hilman
2010-06-17 0:17 ` [PATCH 01/12] OMAP2/3: hwmod: remove '_hwmod' suffix from names Kevin Hilman
2010-06-17 14:23 ` Kevin Hilman
2010-06-17 0:17 ` [PATCH 02/12] OMAP: hwmod: add class for DSP hwmods Kevin Hilman
2010-06-17 0:17 ` [PATCH 03/12] OMAP3: hwmod: add data for OMAP3 IVA2 Kevin Hilman
2010-06-17 0:17 ` [PATCH 04/12] OMAP: omap_device: ensure hwmod tracks attached omap_device pointer Kevin Hilman
2010-06-17 0:17 ` [PATCH 05/12] OMAP: create omap_devices for MPU, DSP, L3 Kevin Hilman
2010-06-23 11:01 ` Gopinath, Thara
2010-06-23 14:48 ` Kevin Hilman
2010-06-23 15:03 ` Gopinath, Thara
2010-06-23 17:46 ` Kevin Hilman
2010-06-24 6:23 ` Gopinath, Thara
2010-06-24 18:09 ` Kevin Hilman
2010-06-17 0:17 ` [PATCH 06/12] OMAP: voltage: use device_initcall() Kevin Hilman
2010-06-17 0:17 ` [PATCH 07/12] OMAP: SR: " Kevin Hilman
2010-06-17 0:17 ` [PATCH 08/12] OMAP2: OPP: update API to be device-based Kevin Hilman
2010-06-17 0:17 ` [PATCH 09/12] OMAP3: CPUfreq: update to device-based OPP API Kevin Hilman
2010-06-17 0:17 ` Kevin Hilman [this message]
2010-06-17 0:17 ` [PATCH 11/12] OMAP: SRF: update to new " Kevin Hilman
2010-06-17 0:17 ` [PATCH 12/12] OMAP: SRF: must be initialized before allowing constraints to be set Kevin Hilman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1276733833-18510-11-git-send-email-khilman@deeprootsystems.com \
--to=khilman@deeprootsystems.com \
--cc=b-cousson@ti.com \
--cc=linux-omap@vger.kernel.org \
--cc=nm@ti.com \
--cc=thara@ti.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).