Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 261261
b: refs/heads/master
c: 09f4634
h: refs/heads/master
i:
  261259: c4e391e
v: v3
  • Loading branch information
istvan_v@mailbox.hu authored and Mauro Carvalho Chehab committed Jul 27, 2011
1 parent 9696c68 commit 297ac79
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 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: 7c8ec47a92107281cd00d5d4c2b7ccfb53143e28
refs/heads/master: 09f4634293f2d48a9619f51b104bef8e6cc6d559
18 changes: 9 additions & 9 deletions trunk/drivers/media/common/tuners/xc4000.c
Original file line number Diff line number Diff line change
Expand Up @@ -919,7 +919,7 @@ static int check_firmware(struct dvb_frontend *fe, unsigned int type,
struct xc4000_priv *priv = fe->tuner_priv;
struct firmware_properties new_fw;
int rc = 0, is_retry = 0;
u16 version = 0, hwmodel;
u16 hwmodel;
v4l2_std_id std0;
u8 hw_major, hw_minor, fw_major, fw_minor;

Expand Down Expand Up @@ -1032,23 +1032,23 @@ static int check_firmware(struct dvb_frontend *fe, unsigned int type,
hwmodel, hw_major, hw_minor, fw_major, fw_minor);

/* Check firmware version against what we downloaded. */
#ifdef DJH_DEBUG
if (priv->firm_version != ((version & 0xf0) << 4 | (version & 0x0f))) {
printk("Incorrect readback of firmware version %x.\n",
(version & 0xff));
if (priv->firm_version != ((fw_major << 8) | fw_minor)) {
printk(KERN_WARNING
"Incorrect readback of firmware version %d.%d.\n",
fw_major, fw_minor);
goto fail;
}
#endif

/* Check that the tuner hardware model remains consistent over time. */
if (priv->hwmodel == 0 &&
(hwmodel == XC_PRODUCT_ID_XC4000 ||
hwmodel == XC_PRODUCT_ID_XC4100)) {
priv->hwmodel = hwmodel;
priv->hwvers = version & 0xff00;
priv->hwvers = (hw_major << 8) | hw_minor;
} else if (priv->hwmodel == 0 || priv->hwmodel != hwmodel ||
priv->hwvers != (version & 0xff00)) {
printk("Read invalid device hardware information - tuner "
priv->hwvers != ((hw_major << 8) | hw_minor)) {
printk(KERN_WARNING
"Read invalid device hardware information - tuner "
"hung?\n");
goto fail;
}
Expand Down

0 comments on commit 297ac79

Please sign in to comment.