[PATCHv5 1/3] OMAP: I2C: Reset support

Kevin Hilman khilman at ti.com
Thu Aug 4 11:05:20 EDT 2011


Shubhrajyoti <shubhrajyoti at ti.com> writes:

> On Wednesday 03 August 2011 04:53 AM, Kevin Hilman wrote:
>> Shubhrajyoti D<shubhrajyoti at ti.com>  writes:
>>
>>>   Under some error conditions the i2c  driver may do a reset.
>>    ^                                    ^
>> minor: extra whitespace
>>
>>>   Adding a reset field and support in the platform.
>> s/platform/device-specific code/
>>
> Yes will fix these.
>>> Signed-off-by: Shubhrajyoti D<shubhrajyoti at ti.com>
>> 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



More information about the linux-arm-kernel mailing list