Second Round of LTSI-v4.14 Backports of I2C R-Car Fixes

Base:
* v4.14.61
* Backports of components for Renesas SoCs to v4.18
* First round of Backports of I2C R-Car Fixes

Backport of post-v4.18 fix for i2c-shmobile and I2C core
The focus of these fixes is to make DMA buffer handling safe
i2c: sh_mobile: fix leak when using DMA bounce buffer

We only freed the bounce buffer after successful DMA, missing the cases
where DMA setup may have gone wrong. Use a better location which always
gets called after each message and use 'stop_after_dma' as a flag for a
successful transfer.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
(cherry picked from commit cebc07d84ad71bc58d6f59b770e4347da48a5a2b)
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
1 file changed