Skip to content

Commit

Permalink
[media] cx24113: Don't reuse core macro names
Browse files Browse the repository at this point in the history
The info and err macros are already defined by the USB stack. Rename
these macros to avoid macro redefinition warnings.

Signed-off-by: Hans Petter Selasky <hselasky@c2i.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
  • Loading branch information
Hans Petter Selasky authored and Mauro Carvalho Chehab committed Jul 27, 2011
1 parent a5bef1d commit d294093
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions drivers/media/dvb/frontends/cx24113.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@

static int debug;

#define info(args...) do { printk(KERN_INFO "CX24113: " args); } while (0)
#define err(args...) do { printk(KERN_ERR "CX24113: " args); } while (0)
#define cx_info(args...) do { printk(KERN_INFO "CX24113: " args); } while (0)
#define cx_err(args...) do { printk(KERN_ERR "CX24113: " args); } while (0)

#define dprintk(args...) \
do { \
Expand Down Expand Up @@ -341,7 +341,7 @@ static void cx24113_calc_pll_nf(struct cx24113_state *state, u16 *n, s32 *f)
} while (N < 6 && R < 3);

if (N < 6) {
err("strange frequency: N < 6\n");
cx_err("strange frequency: N < 6\n");
return;
}
F = freq_hz;
Expand Down Expand Up @@ -563,40 +563,40 @@ struct dvb_frontend *cx24113_attach(struct dvb_frontend *fe,
kzalloc(sizeof(struct cx24113_state), GFP_KERNEL);
int rc;
if (state == NULL) {
err("Unable to kzalloc\n");
cx_err("Unable to kzalloc\n");
goto error;
}

/* setup the state */
state->config = config;
state->i2c = i2c;

info("trying to detect myself\n");
cx_info("trying to detect myself\n");

/* making a dummy read, because of some expected troubles
* after power on */
cx24113_readreg(state, 0x00);

rc = cx24113_readreg(state, 0x00);
if (rc < 0) {
info("CX24113 not found.\n");
cx_info("CX24113 not found.\n");
goto error;
}
state->rev = rc;

switch (rc) {
case 0x43:
info("detected CX24113 variant\n");
cx_info("detected CX24113 variant\n");
break;
case REV_CX24113:
info("successfully detected\n");
cx_info("successfully detected\n");
break;
default:
err("unsupported device id: %x\n", state->rev);
cx_err("unsupported device id: %x\n", state->rev);
goto error;
}
state->ver = cx24113_readreg(state, 0x01);
info("version: %x\n", state->ver);
cx_info("version: %x\n", state->ver);

/* create dvb_frontend */
memcpy(&fe->ops.tuner_ops, &cx24113_tuner_ops,
Expand Down

0 comments on commit d294093

Please sign in to comment.