Re: [PATCH v2] i2c: davinci: Refactor i2c_davinci_wait_bus_not_busy()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 05/13/2015 04:03 PM, Alexander Sverdlin wrote:
There are several problems in the function:
- "to_cnt" variable does nothing
- schedule_timeout() call without setting current state does nothing
- "allow_sleep" parameter is not really used

Refactor the function so that it really tries to wait. In case of timeout try
to recover the bus.

Reviewed-by: Grygorii Strashko <grygorii.strashko@xxxxxxxxxx>

Signed-off-by: Alexander Sverdlin <alexander.sverdlin@xxxxxxxxx>
---
Changes in v2:
- rebased on 110bc76729d4 of Linus's tree;

  drivers/i2c/busses/i2c-davinci.c |   42 +++++++++++++++++--------------------
  1 files changed, 19 insertions(+), 23 deletions(-)


--
regards,
-grygorii
--
To unsubscribe from this list: send the line "unsubscribe linux-i2c" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux GPIO]     [Linux SPI]     [Linux Hardward Monitoring]     [LM Sensors]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux