regulator: ab8500-ext: Don't update info->update_val if set_mode() fails
authorAxel Lin <axel.lin@ingics.com>
Tue, 16 Apr 2013 15:29:12 +0000 (23:29 +0800)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Wed, 17 Apr 2013 14:08:33 +0000 (15:08 +0100)
commit66511fa4a7902fb9ffdffc8c153f1758817fb8a4
tree50ff9b1d779a064207a72618a564d2bccabb9b92
parent0b665062a1dde470d69ff3bd435b090a119991ab
regulator: ab8500-ext: Don't update info->update_val if set_mode() fails

This ensures info->update_val status is still correct if set_mode() call fails.
Otherwise, get_mode() may return wrong status if a set_mode() call fails.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Bengt Jonsson <bengt.g.jonsson@stericsson.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
drivers/regulator/ab8500-ext.c