summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAmaury Pouly <amaury.pouly@gmail.com>2013-09-25 16:36:41 +0200
committerAmaury Pouly <amaury.pouly@gmail.com>2013-09-25 16:36:41 +0200
commite41d2ba02b5a15fe2b370ba410faa7e292ba8bc0 (patch)
tree7d79402009231c754fb8521af270269fde132522
parent6ac481e8bcb72066594e64ec70edd2b869c254eb (diff)
downloadrockbox-e41d2ba02b5a15fe2b370ba410faa7e292ba8bc0.tar.gz
rockbox-e41d2ba02b5a15fe2b370ba410faa7e292ba8bc0.zip
imx233: only clear got_a_nak on imx233, it doesn't exists on other stmps
Change-Id: I88e369dd7fa289f054837b442983bb7c97a58c53
-rw-r--r--firmware/target/arm/imx233/i2c-imx233.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/firmware/target/arm/imx233/i2c-imx233.c b/firmware/target/arm/imx233/i2c-imx233.c
index f3bdb48e89..57f0f7356a 100644
--- a/firmware/target/arm/imx233/i2c-imx233.c
+++ b/firmware/target/arm/imx233/i2c-imx233.c
@@ -212,7 +212,9 @@ enum imx233_i2c_error_t imx233_i2c_end(unsigned timeout)
212 else if(BF_RD(I2C_CTRL1, NO_SLAVE_ACK_IRQ)) 212 else if(BF_RD(I2C_CTRL1, NO_SLAVE_ACK_IRQ))
213 { 213 {
214 /* the core doesn't like this error, this is a workaround to prevent lock up */ 214 /* the core doesn't like this error, this is a workaround to prevent lock up */
215#if IMX233_SUBTARGET >= 3780
215 BF_SET(I2C_CTRL1, CLR_GOT_A_NAK); 216 BF_SET(I2C_CTRL1, CLR_GOT_A_NAK);
217#endif
216 imx233_dma_reset_channel(APB_I2C); 218 imx233_dma_reset_channel(APB_I2C);
217 imx233_i2c_reset(); 219 imx233_i2c_reset();
218 ret = I2C_NO_SLAVE_ACK; 220 ret = I2C_NO_SLAVE_ACK;