Skip to contentSkip to conversation

OMAP4: I2C: Enable FIFO usage for OMAP4

PATCH New Shubhrajyoti D 2 participants 2 messages Nov 3, 2011 – Nov 8, 2011

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 OMAP4: I2C: Enable FIFO usage for OMAP4

Currently the fifo depth is set to zero for OMAP4 which disables the FIFO usage. This patch enables the FIFO usage for I2C transactions on OMAP4 also.

Tested on omap4430 and 3430.

---
 drivers/i2c/busses/i2c-omap.c |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)
drivers/i2c/busses/i2c-omap.c +6 -5
index a43d002..fa23faa 100644
@@ -1047,13 +1047,14 @@ omap_i2c_probe(struct platform_device *pdev)
 		 * size. This is to ensure that we can handle the status on int
 		 * call back latencies.
 		 */
-		if (dev->rev >= OMAP_I2C_REV_ON_3530_4430) {
-			dev->fifo_size = 0;
+
+		dev->fifo_size = (dev->fifo_size / 2);
+
+		if (dev->rev >= OMAP_I2C_REV_ON_3530_4430)
 			dev->b_hw = 0; /* Disable hardware fixes */
-		} else {
-			dev->fifo_size = (dev->fifo_size / 2);
+		else
 			dev->b_hw = 1; /* Enable hardware fixes */
-		}
+
 		/* calculate wakeup latency constraint for MPU */
 		if (dev->set_mpu_wkup_lat != NULL)
 			dev->latency = (1000000 * dev->fifo_size) /
Signature · 1 line
1.7.1
#1 lore raw

PATCH 1/1 OMAP4: I2C: Enable FIFO usage for OMAP4

+Ben Dooks

Quoted 8 lines · Shubhrajyoti D

Currently the fifo depth is set to zero for OMAP4 which disables the FIFO usage. This patch enables the FIFO usage for I2C transactions on OMAP4 also.

Tested on omap4430 and 3430.

Ben, please queue as a fix for the v3.2-rc. It applies cleanly to v3.2-rc1.

If you prefer a branch:
https://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-omap-pm.git for_3.2/fixes/i2c

Thanks,

Kevin