Re: [patch] Fix AF9015 Dual tuner i2c write failures

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 03/05/2011 03:43 AM, adq wrote:
+static int af9015_lock_i2c_gate_ctrl(struct dvb_frontend *fe, int enable)
+{
+	int result;
+	struct dvb_usb_adapter *adap = fe->dvb->priv;
+	struct af9015_state *state = adap->dev->priv;
+
+	if (enable)
+		if (mutex_lock_interruptible(&adap->dev->usb_mutex))
+			return -EAGAIN;
+
+	result = state->i2c_gate_ctrl[adap->id](fe, enable);
+	
+	if (!enable)
+		mutex_unlock(&adap->dev->usb_mutex);
+	
+	return result;
+}

I think this will cause problems in case of tuner driver calls more than one time gate close or gate enable one after the other.


Antti

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


[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux