NFC: Avoid gpio_free for invalid GPIO
ese_gpio was initialised with -EINVAL in case the gpio
is found invalid. While freeing up the resources in
case of probe failure, ese_gpio being an unsigned value
was being compared with numeric value, which will always
be true, hence leading to freeing up the gpio.
Checked if gpio is valid before freeing it up.
Change-Id: Ibfcc14984b2dc45c1dee51ba6a3d03109420be15
Signed-off-by:
Bhuvan Varshney <bvarshne@codeaurora.org>
Loading
Please register or sign in to comment