Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 138321
b: refs/heads/master
c: 378a279
h: refs/heads/master
i:
  138319: 33c7975
v: v3
  • Loading branch information
Antti Palosaari authored and Mauro Carvalho Chehab committed Mar 30, 2009
1 parent c38e5d0 commit e5c8725
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 3 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: 14a19c0a2254ba58ed7559e072456ab94c9a2d3c
refs/heads/master: 378a2793eb5e1e6bcd44f85d368ad6962c8ce1ee
8 changes: 7 additions & 1 deletion trunk/drivers/media/dvb/frontends/zl10353.c
Original file line number Diff line number Diff line change
Expand Up @@ -572,6 +572,10 @@ static int zl10353_init(struct dvb_frontend *fe)
zl10353_dump_regs(fe);
if (state->config.parallel_ts)
zl10353_reset_attach[2] &= ~0x20;
if (state->config.clock_ctl_1)
zl10353_reset_attach[3] = state->config.clock_ctl_1;
if (state->config.pll_0)
zl10353_reset_attach[4] = state->config.pll_0;

/* Do a "hard" reset if not already done */
if (zl10353_read_register(state, 0x50) != zl10353_reset_attach[1] ||
Expand Down Expand Up @@ -614,6 +618,7 @@ struct dvb_frontend *zl10353_attach(const struct zl10353_config *config,
struct i2c_adapter *i2c)
{
struct zl10353_state *state = NULL;
int id;

/* allocate memory for the internal state */
state = kzalloc(sizeof(struct zl10353_state), GFP_KERNEL);
Expand All @@ -625,7 +630,8 @@ struct dvb_frontend *zl10353_attach(const struct zl10353_config *config,
memcpy(&state->config, config, sizeof(struct zl10353_config));

/* check if the demod is there */
if (zl10353_read_register(state, CHIP_ID) != ID_ZL10353)
id = zl10353_read_register(state, CHIP_ID);
if ((id != ID_ZL10353) && (id != ID_CE6230) && (id != ID_CE6231))
goto error;

/* create dvb_frontend */
Expand Down
4 changes: 4 additions & 0 deletions trunk/drivers/media/dvb/frontends/zl10353.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ struct zl10353_config

/* set if i2c_gate_ctrl disable is required */
u8 disable_i2c_gate_ctrl:1;

/* clock control registers (0x51-0x54) */
u8 clock_ctl_1; /* default: 0x46 */
u8 pll_0; /* default: 0x15 */
};

#if defined(CONFIG_DVB_ZL10353) || (defined(CONFIG_DVB_ZL10353_MODULE) && defined(MODULE))
Expand Down
8 changes: 7 additions & 1 deletion trunk/drivers/media/dvb/frontends/zl10353_priv.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@
#ifndef _ZL10353_PRIV_
#define _ZL10353_PRIV_

#define ID_ZL10353 0x14
#define ID_ZL10353 0x14 /* Zarlink ZL10353 */
#define ID_CE6230 0x18 /* Intel CE6230 */
#define ID_CE6231 0x19 /* Intel CE6231 */

#define msb(x) (((x) >> 8) & 0xff)
#define lsb(x) ((x) & 0xff)
Expand Down Expand Up @@ -50,6 +52,10 @@ enum zl10353_reg_addr {
TPS_RECEIVED_0 = 0x1E,
TPS_CURRENT_1 = 0x1F,
TPS_CURRENT_0 = 0x20,
CLOCK_CTL_0 = 0x51,
CLOCK_CTL_1 = 0x52,
PLL_0 = 0x53,
PLL_1 = 0x54,
RESET = 0x55,
AGC_TARGET = 0x56,
MCLK_RATIO = 0x5C,
Expand Down

0 comments on commit e5c8725

Please sign in to comment.