]> git.karo-electronics.de Git - karo-tx-linux.git/commit
leds: leds-lp5523: fix build warnings
authorJingoo Han <jg1.han@samsung.com>
Mon, 29 Oct 2012 01:45:11 +0000 (18:45 -0700)
committerBryan Wu <roc@roc-samos.(none)>
Thu, 1 Nov 2012 22:48:01 +0000 (15:48 -0700)
commit792229798dfba484f9665170023b84ffbbb08572
tree31839af1d21c996afe229e990d49e9864d55fcd1
parent424f58e4cebd76458b44e69ed31f7297808770cd
leds: leds-lp5523: fix build warnings

This patch fixes build warnings as below:

drivers/leds/leds-lp5523.c: In function 'lp5523_selftest':
drivers/leds/leds-lp5523.c:496:18: warning: 'adc' may be used uninitialized in this function [-Wuninitialized]
drivers/leds/leds-lp5523.c:471:5: warning: 'vdd' may be used uninitialized in this function [-Wuninitialized]
drivers/leds/leds-lp5523.c: In function 'lp5523_probe':
drivers/leds/leds-lp5523.c:252:9: warning: 'status' may be used uninitialized in this function [-Wuninitialized]
drivers/leds/leds-lp5523.c:201:5: note: 'status' was declared here

If lp5523_read() returns an error, problems will happen. Thus,
when lp5523_read() returns an error, it should be handled.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Bryan Wu <cooloney@gmail.com>
drivers/leds/leds-lp5523.c