Commit 826c8b60 authored by Patrick Boettcher's avatar Patrick Boettcher Committed by Mauro Carvalho Chehab
Browse files

V4L/DVB (9887): Minor fixes for cx24113-driver (codingstyle)



Fixed some minor coding style issues and some driver information
printed when using the driver on a board.

Signed-off-by: default avatarPatrick Boettcher <pb@linuxtv.org>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 1dc87b6e
Loading
Loading
Loading
Loading
+39 −31
Original line number Diff line number Diff line
@@ -557,6 +557,7 @@ struct dvb_frontend *cx24113_attach(struct dvb_frontend *fe,
	/* allocate memory for the internal state */
	struct cx24113_state *state =
		kzalloc(sizeof(struct cx24113_state), GFP_KERNEL);
	int rc;
	if (state == NULL) {
		err("Unable to kmalloc\n");
		goto error;
@@ -572,15 +573,22 @@ struct dvb_frontend *cx24113_attach(struct dvb_frontend *fe,
	 * after power on */
	cx24113_readreg(state, 0x00);

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

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