On Wed, May 22, 2019 at 11:31:38AM -0700, Ajay Gupta wrote:
> From: Ajay Gupta <[email protected]>
> 
> Added a local variable "send_stop" to simplify "goto" statements.
> 
> The "send_stop" handles below two case
> 1) When first i2c start fails and so i2c stop is not sent before
> exiting
> 
> 2) When i2c stop failed after all transfers and we do not need to
> send another stop before exiting.
> 
> Signed-off-by: Ajay Gupta <[email protected]>

Nice! It was only a brainstorming suggestion to use a dedicated flag.
But I must say I like the outcome; much better readable code IMO.

Suggested-by: Wolfram Sang <[email protected]>
Reviewed-by: Wolfram Sang <[email protected]>

Attachment: signature.asc
Description: PGP signature

Reply via email to