i2c-msm-geni: Initialize completion variable before txfer request
During I2C GSI mode transfer scenario, there is a potential race between
initializing the completion variable and waiting for the completion.
After submitting the DMA transfer request, initializing the completion
may actually reset the received event as DMA could have complete the
transfer immediately before driver waits for the event. Then it can
never receive the completion and results in timeout.
This change initializes the completion variable before submitting the
DMA transfer request and then waits for the completion.
Change-Id: I537d1187a84171a0811862efd5e118c8d8b57fef
Signed-off-by:
Mukesh Kumar Savaliya <msavaliy@codeaurora.org>
Loading
Please register or sign in to comment