From b27d07e094376c2970cdb62434450f7a683edee7 Mon Sep 17 00:00:00 2001 From: Amaury Pouly Date: Tue, 13 Sep 2011 23:38:52 +0000 Subject: imx233/fuze+: reset ssp block correctly, define maximum ssp transfer size git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30525 a1c6a512-1295-4272-9138-f99709370657 --- firmware/target/arm/imx233/ssp-imx233.c | 3 +-- firmware/target/arm/imx233/ssp-imx233.h | 3 +++ 2 files changed, 4 insertions(+), 2 deletions(-) (limited to 'firmware/target/arm/imx233') diff --git a/firmware/target/arm/imx233/ssp-imx233.c b/firmware/target/arm/imx233/ssp-imx233.c index 912f9c3ae4..21d5658392 100644 --- a/firmware/target/arm/imx233/ssp-imx233.c +++ b/firmware/target/arm/imx233/ssp-imx233.c @@ -93,8 +93,7 @@ void imx233_ssp_init(void) void imx233_ssp_start(int ssp) { /* Gate block */ - __REG_CLR(HW_SSP_CTRL0(ssp)) = __BLOCK_CLKGATE; - while(HW_SSP_CTRL0(ssp) & __BLOCK_CLKGATE); + imx233_reset_block(&HW_SSP_CTRL0(ssp)); /* Gate dma channel */ imx233_dma_clkgate_channel(APB_SSP(ssp), true); /* If first block to start, start SSP clock */ diff --git a/firmware/target/arm/imx233/ssp-imx233.h b/firmware/target/arm/imx233/ssp-imx233.h index c9083d8d75..42aa2550a6 100644 --- a/firmware/target/arm/imx233/ssp-imx233.h +++ b/firmware/target/arm/imx233/ssp-imx233.h @@ -28,6 +28,7 @@ #include "system.h" #include "system-target.h" #include "pinctrl-imx233.h" +#include "dma-imx233.h" /* ssp can value 1 or 2 */ #define __SSP_SELECT(ssp, ssp1, ssp2) ((ssp) == 1 ? (ssp1) : (ssp2)) @@ -130,6 +131,8 @@ #define HW_SSP_VERSION(ssp) (*(volatile uint32_t *)(HW_SSP_BASE(ssp) + 0x110)) +#define IMX233_MAX_SSP_XFER_SIZE IMX233_MAX_SINGLE_DMA_XFER_SIZE + enum imx233_ssp_error_t { SSP_SUCCESS = 0, -- cgit v1.2.3