提交 e23d9ae3 编写于 作者: A Andreas Oberritter 提交者: Mauro Carvalho Chehab

[media] DVB: call get_property at the end of dtv_property_process_get

- Drivers should be able to override properties returned to the user.
- The default values get prefilled from the cache.
Signed-off-by: NAndreas Oberritter <obi@linuxtv.org>
Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
上级 15cc2bb3
......@@ -1196,14 +1196,7 @@ static int dtv_property_process_get(struct dvb_frontend *fe,
struct dtv_property *tvp,
struct file *file)
{
int r = 0;
/* Allow the frontend to validate incoming properties */
if (fe->ops.get_property)
r = fe->ops.get_property(fe, tvp);
if (r < 0)
return r;
int r;
switch(tvp->cmd) {
case DTV_FREQUENCY:
......@@ -1323,6 +1316,13 @@ static int dtv_property_process_get(struct dvb_frontend *fe,
return -EINVAL;
}
/* Allow the frontend to override outgoing properties */
if (fe->ops.get_property) {
r = fe->ops.get_property(fe, tvp);
if (r < 0)
return r;
}
dtv_property_dump(tvp);
return 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册