Re: [PATCH 1/1] OMAP3: DMA: Enable idlemodes for DMA OCP

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

 



"ext Kalle Jokiniemi" <ext-kalle.jokiniemi@xxxxxxxxx> writes:

> This patch enables MStandby smart-idle mode, autoidle smartidle mode,
> and the autoidle bit for DMA4_OCP_SYSCONFIG.
>
> Signed-off-by: Kalle Jokiniemi <ext-kalle.jokiniemi@xxxxxxxxx>
> ---
>  arch/arm/plat-omap/dma.c              |   13 +++++++++++++
>  arch/arm/plat-omap/include/mach/dma.h |   15 +++++++++++++++
>  2 files changed, 28 insertions(+), 0 deletions(-)
>
> diff --git a/arch/arm/plat-omap/dma.c b/arch/arm/plat-omap/dma.c
> index c4e5ba3..9d8d28c 100644
> --- a/arch/arm/plat-omap/dma.c
> +++ b/arch/arm/plat-omap/dma.c
> @@ -2420,6 +2420,19 @@ static int __init omap_init_dma(void)
>  	if (cpu_class_is_omap2())
>  		setup_irq(INT_24XX_SDMA_IRQ0, &omap24xx_dma_irq);
>  
> +	/* Enable smartidle idlemodes and autoidle */
> +	if (cpu_is_omap34xx()) {

I think this can be done for omap2 also.

> +		u32 v = dma_read(OCP_SYSCONFIG);
> +		v &= ~(DMA_SYSCONFIG_MIDLEMODE_MASK |
> +				DMA_SYSCONFIG_SIDLEMODE_MASK |
> +				DMA_SYSCONFIG_AUTOIDLE);
> +		v |= (DMA_SYSCONFIG_MIDLEMODE(DMA_IDLEMODE_SMARTIDLE) |
> +			DMA_SYSCONFIG_SIDLEMODE(DMA_IDLEMODE_SMARTIDLE) |
> +			DMA_SYSCONFIG_AUTOIDLE);
> +		dma_write(v , OCP_SYSCONFIG);
> +	}
> +
> +
>  	/* FIXME: Update LCD DMA to work on 24xx */
>  	if (cpu_class_is_omap1()) {
>  		r = request_irq(INT_DMA_LCD, lcd_dma_irq_handler, 0,
> diff --git a/arch/arm/plat-omap/include/mach/dma.h
>  	b/arch/arm/plat-omap/include/mach/dma.h

-- 
Jouni Högander

--
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