Skip to content

Commit

Permalink
[media] af9033: sleep on attach
Browse files Browse the repository at this point in the history
This reduces power consumption 10mA.

Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
  • Loading branch information
Antti Palosaari authored and Mauro Carvalho Chehab committed Sep 27, 2012
1 parent 51639be commit 12897dc
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions drivers/media/dvb-frontends/af9033.c
Original file line number Diff line number Diff line change
Expand Up @@ -909,6 +909,15 @@ struct dvb_frontend *af9033_attach(const struct af9033_config *config,
"OFDM=%d.%d.%d.%d\n", KBUILD_MODNAME, buf[0], buf[1],
buf[2], buf[3], buf[4], buf[5], buf[6], buf[7]);

/* sleep */
ret = af9033_wr_reg(state, 0x80004c, 1);
if (ret < 0)
goto err;

ret = af9033_wr_reg(state, 0x800000, 0);
if (ret < 0)
goto err;

/* configure internal TS mode */
switch (state->cfg.ts_mode) {
case AF9033_TS_MODE_PARALLEL:
Expand Down

0 comments on commit 12897dc

Please sign in to comment.