aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sound/soc/fsl/fsl_ssi.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/sound/soc/fsl/fsl_ssi.c b/sound/soc/fsl/fsl_ssi.c
index bc904696d820..d0b9fe31f49a 100644
--- a/sound/soc/fsl/fsl_ssi.c
+++ b/sound/soc/fsl/fsl_ssi.c
@@ -159,6 +159,7 @@ struct fsl_ssi_private {
159 bool use_dma; 159 bool use_dma;
160 bool baudclk_locked; 160 bool baudclk_locked;
161 bool irq_stats; 161 bool irq_stats;
162 bool offline_config;
162 u8 i2s_mode; 163 u8 i2s_mode;
163 spinlock_t baudclk_lock; 164 spinlock_t baudclk_lock;
164 struct clk *baudclk; 165 struct clk *baudclk;
@@ -1251,6 +1252,32 @@ static int fsl_ssi_probe(struct platform_device *pdev)
1251 ssi_private->baudclk_locked = false; 1252 ssi_private->baudclk_locked = false;
1252 spin_lock_init(&ssi_private->baudclk_lock); 1253 spin_lock_init(&ssi_private->baudclk_lock);
1253 1254
1255 /*
1256 * imx51 and later SoCs have a slightly different IP that allows the
1257 * SSI configuration while the SSI unit is running.
1258 *
1259 * More important, it is necessary on those SoCs to configure the
1260 * sperate TX/RX DMA bits just before starting the stream
1261 * (fsl_ssi_trigger). The SDMA unit has to be configured before fsl_ssi
1262 * sends any DMA requests to the SDMA unit, otherwise it is not defined
1263 * how the SDMA unit handles the DMA request.
1264 *
1265 * SDMA units are present on devices starting at imx35 but the imx35
1266 * reference manual states that the DMA bits should not be changed
1267 * while the SSI unit is running (SSIEN). So we support the necessary
1268 * online configuration of fsl-ssi starting at imx51.
1269 */
1270 switch (hw_type) {
1271 case FSL_SSI_MCP8610:
1272 case FSL_SSI_MX21:
1273 case FSL_SSI_MX35:
1274 ssi_private->offline_config = true;
1275 break;
1276 case FSL_SSI_MX51:
1277 ssi_private->offline_config = false;
1278 break;
1279 }
1280
1254 if (hw_type == FSL_SSI_MX21 || hw_type == FSL_SSI_MX51 || 1281 if (hw_type == FSL_SSI_MX21 || hw_type == FSL_SSI_MX51 ||
1255 hw_type == FSL_SSI_MX35) { 1282 hw_type == FSL_SSI_MX35) {
1256 u32 dma_events[2]; 1283 u32 dma_events[2];