Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

V4L/DVB (11215): zl10353: add support for Intel CE6230 and Intel CE6231

Add chip IDs and configuration registers needed for Intel CE6230 and
Intel CE6231.

Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>

authored by

Antti Palosaari and committed by
Mauro Carvalho Chehab
378a2793 14a19c0a

+18 -2
+7 -1
drivers/media/dvb/frontends/zl10353.c
··· 572 572 zl10353_dump_regs(fe); 573 573 if (state->config.parallel_ts) 574 574 zl10353_reset_attach[2] &= ~0x20; 575 + if (state->config.clock_ctl_1) 576 + zl10353_reset_attach[3] = state->config.clock_ctl_1; 577 + if (state->config.pll_0) 578 + zl10353_reset_attach[4] = state->config.pll_0; 575 579 576 580 /* Do a "hard" reset if not already done */ 577 581 if (zl10353_read_register(state, 0x50) != zl10353_reset_attach[1] || ··· 618 614 struct i2c_adapter *i2c) 619 615 { 620 616 struct zl10353_state *state = NULL; 617 + int id; 621 618 622 619 /* allocate memory for the internal state */ 623 620 state = kzalloc(sizeof(struct zl10353_state), GFP_KERNEL); ··· 630 625 memcpy(&state->config, config, sizeof(struct zl10353_config)); 631 626 632 627 /* check if the demod is there */ 633 - if (zl10353_read_register(state, CHIP_ID) != ID_ZL10353) 628 + id = zl10353_read_register(state, CHIP_ID); 629 + if ((id != ID_ZL10353) && (id != ID_CE6230) && (id != ID_CE6231)) 634 630 goto error; 635 631 636 632 /* create dvb_frontend */
+4
drivers/media/dvb/frontends/zl10353.h
··· 41 41 42 42 /* set if i2c_gate_ctrl disable is required */ 43 43 u8 disable_i2c_gate_ctrl:1; 44 + 45 + /* clock control registers (0x51-0x54) */ 46 + u8 clock_ctl_1; /* default: 0x46 */ 47 + u8 pll_0; /* default: 0x15 */ 44 48 }; 45 49 46 50 #if defined(CONFIG_DVB_ZL10353) || (defined(CONFIG_DVB_ZL10353_MODULE) && defined(MODULE))
+7 -1
drivers/media/dvb/frontends/zl10353_priv.h
··· 22 22 #ifndef _ZL10353_PRIV_ 23 23 #define _ZL10353_PRIV_ 24 24 25 - #define ID_ZL10353 0x14 25 + #define ID_ZL10353 0x14 /* Zarlink ZL10353 */ 26 + #define ID_CE6230 0x18 /* Intel CE6230 */ 27 + #define ID_CE6231 0x19 /* Intel CE6231 */ 26 28 27 29 #define msb(x) (((x) >> 8) & 0xff) 28 30 #define lsb(x) ((x) & 0xff) ··· 52 50 TPS_RECEIVED_0 = 0x1E, 53 51 TPS_CURRENT_1 = 0x1F, 54 52 TPS_CURRENT_0 = 0x20, 53 + CLOCK_CTL_0 = 0x51, 54 + CLOCK_CTL_1 = 0x52, 55 + PLL_0 = 0x53, 56 + PLL_1 = 0x54, 55 57 RESET = 0x55, 56 58 AGC_TARGET = 0x56, 57 59 MCLK_RATIO = 0x5C,