i2c: tegra: notify transfer-complete after clearing status.
authorLaxman Dewangan <ldewangan@nvidia.com>
Mon, 7 May 2012 06:46:19 +0000 (12:16 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 1 Jun 2012 07:18:28 +0000 (15:18 +0800)
commit3e5f29bd22e597d66d9c1013a0ab190e6b48a8ba
tree4facfe4cc1bd4354435fb517888529fae4edb6f2
parent16d815fd230b81d49d395e91b084f0731ea6e4a2
i2c: tegra: notify transfer-complete after clearing status.

commit c889e91d2cc22123f20f40dde0c0a91856a20eea upstream.

The notification of the transfer complete by calling complete()
should be done after clearing all interrupt status.
This avoids the race condition of misconfigure the i2c controller
in multi-core environment.

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Acked-by: Stephen Warren <swarren@wwwdotorg.org>
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/i2c/busses/i2c-tegra.c