diff mbox

[pm-wip/voltdm_nm,01/10] OMAP3+: VC: fix mutant channel handling

Message ID 1307412972-25854-2-git-send-email-nm@ti.com (mailing list archive)
State Not Applicable
Delegated to: Kevin Hilman
Headers show

Commit Message

Nishanth Menon June 7, 2011, 2:16 a.m. UTC
"OMAP3+: PM: VC: handle mutant channel config for OMAP4 MPU channel"
handles the mutant channel flags, however since vc_cfg_bits is static
file wide variable, it makes better sense to update this based on
the specific channel using mutant or not. else if we have a initial
registration of mutant channel definition, all other channels will
end up using the mutant definition.

Signed-off-by: Nishanth Menon <nm@ti.com>
---
we should probably squash this in to the original commit
 arch/arm/mach-omap2/vc.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

Comments

Kevin Hilman June 9, 2011, 5:21 p.m. UTC | #1
Nishanth Menon <nm@ti.com> writes:

> "OMAP3+: PM: VC: handle mutant channel config for OMAP4 MPU channel"
> handles the mutant channel flags, however since vc_cfg_bits is static
> file wide variable, it makes better sense to update this based on
> the specific channel using mutant or not. else if we have a initial
> registration of mutant channel definition, all other channels will
> end up using the mutant definition.

Indeed.

> Signed-off-by: Nishanth Menon <nm@ti.com>
> ---
> we should probably squash this in to the original commit

Thanks, squashed.

Kevin

>  arch/arm/mach-omap2/vc.c |    4 +++-
>  1 files changed, 3 insertions(+), 1 deletions(-)
>
> diff --git a/arch/arm/mach-omap2/vc.c b/arch/arm/mach-omap2/vc.c
> index c8deac9..aa9f0bc 100644
> --- a/arch/arm/mach-omap2/vc.c
> +++ b/arch/arm/mach-omap2/vc.c
> @@ -53,7 +53,7 @@ static struct omap_vc_channel_cfg vc_mutant_channel_cfg = {
>  	.cmd   = BIT(1),
>  };
>  
> -static struct omap_vc_channel_cfg *vc_cfg_bits = &vc_default_channel_cfg;
> +static struct omap_vc_channel_cfg *vc_cfg_bits;
>  #define CFG_CHANNEL_MASK 0x1f
>  
>  /**
> @@ -300,6 +300,8 @@ void __init omap_vc_init_channel(struct voltagedomain *voltdm)
>  	vc->cfg_channel = 0;
>  	if (vc->flags & OMAP_VC_CHANNEL_CFG_MUTANT)
>  		vc_cfg_bits = &vc_mutant_channel_cfg;
> +	else
> +		vc_cfg_bits = &vc_default_channel_cfg;
>  
>  	/* get PMIC/board specific settings */
>  	vc->i2c_slave_addr = voltdm->pmic->i2c_slave_addr;
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/arch/arm/mach-omap2/vc.c b/arch/arm/mach-omap2/vc.c
index c8deac9..aa9f0bc 100644
--- a/arch/arm/mach-omap2/vc.c
+++ b/arch/arm/mach-omap2/vc.c
@@ -53,7 +53,7 @@  static struct omap_vc_channel_cfg vc_mutant_channel_cfg = {
 	.cmd   = BIT(1),
 };
 
-static struct omap_vc_channel_cfg *vc_cfg_bits = &vc_default_channel_cfg;
+static struct omap_vc_channel_cfg *vc_cfg_bits;
 #define CFG_CHANNEL_MASK 0x1f
 
 /**
@@ -300,6 +300,8 @@  void __init omap_vc_init_channel(struct voltagedomain *voltdm)
 	vc->cfg_channel = 0;
 	if (vc->flags & OMAP_VC_CHANNEL_CFG_MUTANT)
 		vc_cfg_bits = &vc_mutant_channel_cfg;
+	else
+		vc_cfg_bits = &vc_default_channel_cfg;
 
 	/* get PMIC/board specific settings */
 	vc->i2c_slave_addr = voltdm->pmic->i2c_slave_addr;