Skip to content

Commit

Permalink
V4L/DVB: xc5000: Fix a few warnings
Browse files Browse the repository at this point in the history
drivers/media/common/tuners/xc5000.c: In function ‘xc_write_reg’:
drivers/media/common/tuners/xc5000.c:298: warning: passing argument 3 of ‘xc5000_readreg’ from incompatible pointer type
drivers/media/common/tuners/xc5000.c:235: note: expected ‘u16 *’ but argument is of type ‘u8 *’
drivers/media/common/tuners/xc5000.c: At top level:
drivers/media/common/tuners/xc5000.c:223: warning: ‘xc_read_i2c_data’ defined but not used

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
  • Loading branch information
Mauro Carvalho Chehab committed Aug 2, 2010
1 parent 43c2407 commit 1cdffda
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion drivers/media/common/tuners/xc5000.c
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,7 @@ static int xc_send_i2c_data(struct xc5000_priv *priv, u8 *buf, int len)
return XC_RESULT_SUCCESS;
}

#if 0
/* This routine is never used because the only time we read data from the
i2c bus is when we read registers, and we want that to be an atomic i2c
transaction in case we are on a multi-master bus */
Expand All @@ -231,6 +232,7 @@ static int xc_read_i2c_data(struct xc5000_priv *priv, u8 *buf, int len)
}
return 0;
}
#endif

static int xc5000_readreg(struct xc5000_priv *priv, u16 reg, u16 *val)
{
Expand Down Expand Up @@ -295,7 +297,7 @@ static int xc_write_reg(struct xc5000_priv *priv, u16 regAddr, u16 i2cData)
if (result == XC_RESULT_SUCCESS) {
/* wait for busy flag to clear */
while ((WatchDogTimer > 0) && (result == XC_RESULT_SUCCESS)) {
result = xc5000_readreg(priv, XREG_BUSY, buf);
result = xc5000_readreg(priv, XREG_BUSY, (u16 *)buf);
if (result == XC_RESULT_SUCCESS) {
if ((buf[0] == 0) && (buf[1] == 0)) {
/* busy flag cleared */
Expand Down

0 comments on commit 1cdffda

Please sign in to comment.