[PATCH 07/21] OMAP3+: PM: SR/Class3: disable errorgen before disable VP

Sergei Shtylyov sshtylyov at ru.mvista.com
Thu Jan 26 06:26:24 EST 2012


Hello.

On 25-01-2012 19:16, Jean Pihet wrote:

> From: Nishanth Menon<nm at ti.com>

> SmartReflex AVS Errorgen module supplies signals to Voltage
> Processor. It is suggested that by disabling Errorgen module
> before we disable VP, we might be able to ensure lesser
> chances of race condition to occur in the system.

> Change-Id: Id0145adacfa63d7652a29859ad6c95cc2ac61cc8

    Please remove this line.

> Signed-off-by: Nishanth Menon<nm at ti.com>
> Signed-off-by: Jean Pihet<j-pihet at ti.com>
[...]

> diff --git a/arch/arm/mach-omap2/smartreflex.c b/arch/arm/mach-omap2/smartreflex.c
> index ee224df..d7294c6 100644
> --- a/arch/arm/mach-omap2/smartreflex.c
> +++ b/arch/arm/mach-omap2/smartreflex.c
> @@ -454,6 +454,50 @@ int sr_configure_errgen(struct voltagedomain *voltdm)
>   }
>
>   /**
> + * sr_disable_errgen() - Disables SmartReflex AVS module's errgen component
> + * @voltdm: voltagedomain pointer to which the SR module to be configured belongs to.
> + *
> + * This API is to be called from the smartreflex class driver to
> + * disable the error generator module inside the smartreflex module.
> + *
> + * Returns 0 on success and error value in case of failure.
> + */
> +int sr_disable_errgen(struct voltagedomain *voltdm)
> +{
> +	u32 errconfig_offs, vpboundint_en;
> +	u32 vpboundint_st;
> +	struct omap_sr *sr = _sr_lookup(voltdm);
> +
> +	if (IS_ERR(sr)) {
> +		pr_warning("%s: omap_sr struct for sr_%s not found\n",
> +			__func__, voltdm->name);
> +		return -EINVAL;

    Not PTR_ERR(sr)?

WBR, Sergei



More information about the linux-arm-kernel mailing list