Skip to contentSkip to conversation

tuner-xc2028: unlock on error in xc2028_get_afc()

PATCH New Dan Carpenter 1 participant 1 message Jul 21, 2012

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 2/2 tuner-xc2028: unlock on error in xc2028_get_afc()

We need to do a mutex_unlock(&priv->lock) before returning.

drivers/media/common/tuners/tuner-xc2028.c +1 -1
index 9e60285..ea0550e 100644
@@ -978,7 +978,7 @@ static int xc2028_get_afc(struct dvb_frontend *fe, s32 *afc)
 	/* Get AFC */
 	rc = xc2028_get_reg(priv, XREG_FREQ_ERROR, &afc_reg);
 	if (rc < 0)
-		return rc;
+		goto ret;
 
 	*afc = afc_reg * 15625; /* Hz */