Re: gpio-omap: Edge interrupts stall

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



* Tony Lindgren <tony@xxxxxxxxxxx> [170324 10:59]:
> * Tony Lindgren <tony@xxxxxxxxxxx> [170324 10:51]:
> > If something like the untested patch below helps, then we might be
> > able to optimize thing a bit. We need to check if something has to
> > be configured in the PER retention case though.
> >
> > 8< ---------------
> > diff --git a/arch/arm/mach-omap2/pm34xx.c b/arch/arm/mach-omap2/pm34xx.c
> > --- a/arch/arm/mach-omap2/pm34xx.c
> > +++ b/arch/arm/mach-omap2/pm34xx.c
> > @@ -229,7 +229,8 @@ void omap_sram_idle(void)
> >  	/* PER */
> >  	if (per_next_state < PWRDM_POWER_ON) {
> >  		per_going_off = (per_next_state == PWRDM_POWER_OFF) ? 1 : 0;
> > -		omap2_gpio_prepare_for_idle(per_going_off);
> > +		if (per_going_off)
> > +			omap2_gpio_prepare_for_idle(per_going_off);
> >  	}
> >  
> >  	/* CORE */
> 
> And that will lead into unpaired pm_runtime_calls. Here's a better
> experimental patch that seems to increase runtime power consumption
> by 30mW, need to check more though. Off mode idle consumption is not
> effected. But if that helps Ladis then we can investigate further.

Hmm actually this patch causes no change in runtime power consumption
for me, it must be something else doing it. So you yeah the below might
be doable, needs to be tested properly though to make sure nothing
else breaks.

Regards,

Tony

> 8< ----------------------
> diff --git a/arch/arm/mach-omap2/pm34xx.c b/arch/arm/mach-omap2/pm34xx.c
> --- a/arch/arm/mach-omap2/pm34xx.c
> +++ b/arch/arm/mach-omap2/pm34xx.c
> @@ -197,7 +197,6 @@ void omap_sram_idle(void)
>  	int mpu_next_state = PWRDM_POWER_ON;
>  	int per_next_state = PWRDM_POWER_ON;
>  	int core_next_state = PWRDM_POWER_ON;
> -	int per_going_off;
>  	u32 sdrc_pwr = 0;
>  
>  	mpu_next_state = pwrdm_read_next_pwrst(mpu_pwrdm);
> @@ -227,10 +226,8 @@ void omap_sram_idle(void)
>  	pwrdm_pre_transition(NULL);
>  
>  	/* PER */
> -	if (per_next_state < PWRDM_POWER_ON) {
> -		per_going_off = (per_next_state == PWRDM_POWER_OFF) ? 1 : 0;
> -		omap2_gpio_prepare_for_idle(per_going_off);
> -	}
> +	if (per_next_state == PWRDM_POWER_OFF)
> +		omap2_gpio_prepare_for_idle(true);
>  
>  	/* CORE */
>  	if (core_next_state < PWRDM_POWER_ON) {
> @@ -295,7 +292,7 @@ void omap_sram_idle(void)
>  	pwrdm_post_transition(NULL);
>  
>  	/* PER */
> -	if (per_next_state < PWRDM_POWER_ON)
> +	if (per_next_state == PWRDM_POWER_OFF)
>  		omap2_gpio_resume_after_idle();
>  }
>  
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux