diff mbox

[2/2,media] tuner-xc2028: unlock on error in xc2028_get_afc()

Message ID 20120721083259.GB13454@elgon.mountain (mailing list archive)
State New, archived
Headers show

Commit Message

Dan Carpenter July 21, 2012, 8:32 a.m. UTC
We need to do a mutex_unlock(&priv->lock) before returning.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/drivers/media/common/tuners/tuner-xc2028.c b/drivers/media/common/tuners/tuner-xc2028.c
index 9e60285..ea0550e 100644
--- a/drivers/media/common/tuners/tuner-xc2028.c
+++ b/drivers/media/common/tuners/tuner-xc2028.c
@@ -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 */