[PATCHv5 1/3] OMAP: I2C: Reset support
From: Kevin Hilman <hidden>
Date: 2011-08-04 15:05:20
Also in:
linux-i2c, linux-omap
Shubhrajyoti [off-list ref] writes:
On Wednesday 03 August 2011 04:53 AM, Kevin Hilman wrote:quoted
Shubhrajyoti D[off-list ref] writes:quoted
Under some error conditions the i2c driver may do a reset.^ ^ minor: extra whitespacequoted
Adding a reset field and support in the platform.s/platform/device-specific code/Yes will fix these.quoted
quoted
Signed-off-by: Shubhrajyoti D<redacted>That being said, omap_device_shutdown() should already do a clean shutdown + reset for you, and i2c-omap.h already has a pointer for ->device_shutdown() so a new device_reset() should not be needed. IOW, simply adding pdata->device_shutdown = omap_device_shutdown() should work.i2C has a special reset sequence ie Disable -> reset -> enable -> Poll on reset done. This function is implemented in omap_i2c_reset. The omap_hwmod_reset calls -> _reset which calls ocp_softrest or custom reset if it is present.The latter is true for I2C. However I see that omap_device_shutdown -> _assert_hardreset However for I2c there doesnt seem to be a HW reset line. Am I missing something?
No, my fault. I thought omap_device_shutdown() also did soft reset, but I see that's not the case. You can ignore my comments about using omap_device_shutdown. Kevin