Commit a83d7d17 authored by Antti Palosaari's avatar Antti Palosaari Committed by Mauro Carvalho Chehab

[media] si2157: implement sleep

Implement sleep for power-management.
Signed-off-by: default avatarAntti Palosaari <crope@iki.fi>
Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
parent 3c0d394e
...@@ -89,12 +89,23 @@ static int si2157_init(struct dvb_frontend *fe) ...@@ -89,12 +89,23 @@ static int si2157_init(struct dvb_frontend *fe)
static int si2157_sleep(struct dvb_frontend *fe) static int si2157_sleep(struct dvb_frontend *fe)
{ {
struct si2157 *s = fe->tuner_priv; struct si2157 *s = fe->tuner_priv;
int ret;
struct si2157_cmd cmd;
dev_dbg(&s->client->dev, "%s:\n", __func__); dev_dbg(&s->client->dev, "%s:\n", __func__);
s->active = false; s->active = false;
memcpy(cmd.args, "\x13", 1);
cmd.len = 1;
ret = si2157_cmd_execute(s, &cmd);
if (ret)
goto err;
return 0; return 0;
err:
dev_dbg(&s->client->dev, "%s: failed=%d\n", __func__, ret);
return ret;
} }
static int si2157_set_params(struct dvb_frontend *fe) static int si2157_set_params(struct dvb_frontend *fe)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment