i2c: tegra: Fix to avoid possible race condition
authorChaitanya Bandi <bandik@nvidia.com>
Fri, 16 Mar 2012 12:17:35 +0000 (17:17 +0530)
committerVarun Wadekar <vwadekar@nvidia.com>
Wed, 18 Apr 2012 04:09:27 +0000 (09:09 +0530)
commit257f68b70585ade9622b4b60c4ae57ea3ef01b26
tree0abd4fbbb6b98de73dc78d9b59c3cd389d7cbfd6
parent67ee893a536aba15457b8198d75190a2b544b49d
i2c: tegra: Fix to avoid possible race condition

Because of race condition between isr and tx fifo fill,
duplicate data is being written. So added locking to make
Tx fifo fill as atomic.

Change-Id: Ia99466adadfb6d86a6f238ec4cd0aa13bd36e434
Signed-off-by: Chaitanya Bandi <bandik@nvidia.com>
Reviewed-on: http://git-master/r/90870
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
drivers/i2c/busses/i2c-tegra.c