From: Kevin Hilman <khilman@ti.com>
To: Sanjeev Premi <premi@ti.com>
Cc: linux-omap@vger.kernel.org
Subject: Re: [PATCH 2/2] omap3: voltage: fix variable type and name
Date: Thu, 17 Mar 2011 13:11:59 -0700 [thread overview]
Message-ID: <874o711p80.fsf@ti.com> (raw)
In-Reply-To: <1300374757-23010-3-git-send-email-premi@ti.com> (Sanjeev Premi's message of "Thu, 17 Mar 2011 20:42:37 +0530")
Sanjeev Premi <premi@ti.com> writes:
> In all usages, variables prm_mod_offs and prm_irqst_ocp_mod_offs
> are expected to be "u16" but have been declared as "s16".
What kind of problem is that causing?
Kevin
> In addition, renamed prm_irqst_ocp_mod_offs to ocp_sysreg_prm_offs
> for better association with the TRM. Original name perhaps came
> from the current usage of this offset to reach PRM_IRQSTATUS_MPU
> offset.
>
> Signed-off-by: Sanjeev Premi <premi@ti.com>
> ---
> arch/arm/mach-omap2/voltage.c | 18 +++++++++---------
> 1 files changed, 9 insertions(+), 9 deletions(-)
>
> diff --git a/arch/arm/mach-omap2/voltage.c b/arch/arm/mach-omap2/voltage.c
> index ce3098a..c686eca 100644
> --- a/arch/arm/mach-omap2/voltage.c
> +++ b/arch/arm/mach-omap2/voltage.c
> @@ -51,8 +51,8 @@ static struct omap_vdd_info **vdd_info;
> static int nr_scalable_vdd;
>
> /* XXX document */
> -static s16 prm_mod_offs;
> -static s16 prm_irqst_ocp_mod_offs;
> +static u16 prm_mod_offs;
> +static u16 ocp_sysreg_prm_offs;
>
> static struct dentry *voltage_dir;
>
> @@ -447,8 +447,8 @@ static int vp_forceupdate_scale_voltage(struct omap_vdd_info *vdd,
> */
> while (timeout++ < VP_TRANXDONE_TIMEOUT) {
> vdd->write_reg(vdd->vp_data->prm_irqst_data->tranxdone_status,
> - prm_irqst_ocp_mod_offs, prm_irqst_reg);
> - if (!(vdd->read_reg(prm_irqst_ocp_mod_offs, prm_irqst_reg) &
> + ocp_sysreg_prm_offs, prm_irqst_reg);
> + if (!(vdd->read_reg(ocp_sysreg_prm_offs, prm_irqst_reg) &
> vdd->vp_data->prm_irqst_data->tranxdone_status))
> break;
> udelay(1);
> @@ -481,7 +481,7 @@ static int vp_forceupdate_scale_voltage(struct omap_vdd_info *vdd,
> * Depends on SMPSWAITTIMEMIN/MAX and voltage change
> */
> timeout = 0;
> - omap_test_timeout((vdd->read_reg(prm_irqst_ocp_mod_offs, prm_irqst_reg) &
> + omap_test_timeout((vdd->read_reg(ocp_sysreg_prm_offs, prm_irqst_reg) &
> vdd->vp_data->prm_irqst_data->tranxdone_status),
> VP_TRANXDONE_TIMEOUT, timeout);
> if (timeout >= VP_TRANXDONE_TIMEOUT)
> @@ -498,8 +498,8 @@ static int vp_forceupdate_scale_voltage(struct omap_vdd_info *vdd,
> timeout = 0;
> while (timeout++ < VP_TRANXDONE_TIMEOUT) {
> vdd->write_reg(vdd->vp_data->prm_irqst_data->tranxdone_status,
> - prm_irqst_ocp_mod_offs, prm_irqst_reg);
> - if (!(vdd->read_reg(prm_irqst_ocp_mod_offs, prm_irqst_reg) &
> + ocp_sysreg_prm_offs, prm_irqst_reg);
> + if (!(vdd->read_reg(ocp_sysreg_prm_offs, prm_irqst_reg) &
> vdd->vp_data->prm_irqst_data->tranxdone_status))
> break;
> udelay(1);
> @@ -1101,10 +1101,10 @@ int __init omap_voltage_early_init(struct omap_vdd_info *omap_vdd_array[],
> {
> if (cpu_is_omap44xx()) {
> prm_mod_offs = OMAP4430_PRM_DEVICE_INST;
> - prm_irqst_ocp_mod_offs = OMAP4430_PRM_OCP_SOCKET_INST;
> + ocp_sysreg_prm_offs = OMAP4430_PRM_OCP_SOCKET_INST;
> } else if (cpu_is_omap34xx()) {
> prm_mod_offs = OMAP3430_GR_MOD;
> - prm_irqst_ocp_mod_offs = OCP_MOD;
> + ocp_sysreg_prm_offs = OCP_MOD;
> } else {
> /* TODO:
> * What should be done for OMAP24xx?
next prev parent reply other threads:[~2011-03-17 20:12 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-17 15:12 [PATCH 0/2] omap2+: voltage: simple clean-ups Sanjeev Premi
2011-03-17 15:12 ` [PATCH 1/2] omap3: voltage: remove unnecessary param passing Sanjeev Premi
2011-03-17 20:10 ` Kevin Hilman
2011-03-18 4:58 ` Premi, Sanjeev
2011-03-17 15:12 ` [PATCH 2/2] omap3: voltage: fix variable type and name Sanjeev Premi
2011-03-17 20:11 ` Kevin Hilman [this message]
2011-03-18 4:53 ` Premi, Sanjeev
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=874o711p80.fsf@ti.com \
--to=khilman@ti.com \
--cc=linux-omap@vger.kernel.org \
--cc=premi@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.