Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 285739
b: refs/heads/master
c: d4d5a40
h: refs/heads/master
i:
  285737: e637c69
  285735: 96976a7
v: v3
  • Loading branch information
Malcolm Priestley authored and Mauro Carvalho Chehab committed Jan 6, 2012
1 parent 83e5faa commit f8532a5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 14 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: bcd158de94238d90adf7275548f0aaf2de724ab1
refs/heads/master: d4d5a40710701abd4535d6a5ada601c885a08865
22 changes: 9 additions & 13 deletions trunk/drivers/media/dvb/dvb-usb/it913x.c
Original file line number Diff line number Diff line change
Expand Up @@ -259,15 +259,15 @@ static u32 it913x_query(struct usb_device *udev, u8 pro)

static int it913x_pid_filter_ctrl(struct dvb_usb_adapter *adap, int onoff)
{
int ret = 0;
struct usb_device *udev = adap->dev->udev;
int ret;
u8 pro = (adap->id == 0) ? DEV_0_DMOD : DEV_1_DMOD;

if (mutex_lock_interruptible(&adap->dev->i2c_mutex) < 0)
return -EAGAIN;
deb_info(1, "PID_C (%02x)", onoff);

if (!onoff)
ret = it913x_wr_reg(adap->dev->udev, pro, PID_RST, 0x1);
ret = it913x_wr_reg(udev, pro, PID_EN, onoff);

mutex_unlock(&adap->dev->i2c_mutex);
return ret;
Expand All @@ -277,24 +277,20 @@ static int it913x_pid_filter(struct dvb_usb_adapter *adap,
int index, u16 pid, int onoff)
{
struct usb_device *udev = adap->dev->udev;
int ret = 0;
int ret;
u8 pro = (adap->id == 0) ? DEV_0_DMOD : DEV_1_DMOD;

if (mutex_lock_interruptible(&adap->dev->i2c_mutex) < 0)
return -EAGAIN;
deb_info(1, "PID_F (%02x)", onoff);
if (onoff) {
ret = it913x_wr_reg(udev, pro, PID_EN, 0x1);

ret |= it913x_wr_reg(udev, pro, PID_LSB, (u8)(pid & 0xff));
ret = it913x_wr_reg(udev, pro, PID_LSB, (u8)(pid & 0xff));

ret |= it913x_wr_reg(udev, pro, PID_MSB, (u8)(pid >> 8));
ret |= it913x_wr_reg(udev, pro, PID_MSB, (u8)(pid >> 8));

ret |= it913x_wr_reg(udev, pro, PID_INX_EN, (u8)onoff);
ret |= it913x_wr_reg(udev, pro, PID_INX_EN, (u8)onoff);

ret |= it913x_wr_reg(udev, pro, PID_INX, (u8)(index & 0x1f));

}
ret |= it913x_wr_reg(udev, pro, PID_INX, (u8)(index & 0x1f));

mutex_unlock(&adap->dev->i2c_mutex);
return 0;
Expand Down Expand Up @@ -839,5 +835,5 @@ module_exit(it913x_module_exit);

MODULE_AUTHOR("Malcolm Priestley <tvboxspy@gmail.com>");
MODULE_DESCRIPTION("it913x USB 2 Driver");
MODULE_VERSION("1.18");
MODULE_VERSION("1.20");
MODULE_LICENSE("GPL");

0 comments on commit f8532a5

Please sign in to comment.