Skip to contentSkip to conversation

smiapp: Fix error handling in power on sequence

PATCH New Sakari Ailus 1 participant 1 message Dec 9, 2016 Media (V4L/DVB)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 smiapp: Fix error handling in power on sequence

The error handling code in smiapp_power_on() returned in case of a failed I2C write instead of cleaning up the mess. Fix this.

---
 drivers/media/i2c/smiapp/smiapp-core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/i2c/smiapp/smiapp-core.c +1 -1
index f4e92bd..e290601 100644
@@ -1310,7 +1310,7 @@ static int smiapp_power_on(struct device *dev)
 	rval = smiapp_write(sensor, SMIAPP_REG_U8_DPHY_CTRL,
 			    SMIAPP_DPHY_CTRL_UI);
 	if (rval < 0)
-		return rval;
+		goto out_cci_addr_fail;
 
 	rval = smiapp_call_quirk(sensor, post_poweron);
 	if (rval) {
Signature · 1 line
2.1.4