Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 366872
b: refs/heads/master
c: 6f8ca0b
h: refs/heads/master
v: v3
  • Loading branch information
Mauro Carvalho Chehab committed Mar 25, 2013
1 parent 0582374 commit 3fc2ecf
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 11 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: 383730c36419b85233fe2b5081253a2181160d17
refs/heads/master: 6f8ca0b541c8bb542edb02dad68bd723625132e7
16 changes: 6 additions & 10 deletions trunk/drivers/media/v4l2-core/tuner-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -222,8 +222,7 @@ static int fe_has_signal(struct dvb_frontend *fe)
{
u16 strength = 0;

if (fe->ops.tuner_ops.get_rf_strength)
fe->ops.tuner_ops.get_rf_strength(fe, &strength);
fe->ops.tuner_ops.get_rf_strength(fe, &strength);

return strength;
}
Expand All @@ -232,8 +231,7 @@ static int fe_get_afc(struct dvb_frontend *fe)
{
s32 afc = 0;

if (fe->ops.tuner_ops.get_afc)
fe->ops.tuner_ops.get_afc(fe, &afc);
fe->ops.tuner_ops.get_afc(fe, &afc);

return afc;
}
Expand All @@ -256,8 +254,6 @@ static void tuner_status(struct dvb_frontend *fe);
static const struct analog_demod_ops tuner_analog_ops = {
.set_params = fe_set_params,
.standby = fe_standby,
.has_signal = fe_has_signal,
.get_afc = fe_get_afc,
.set_config = fe_set_config,
.tuner_status = tuner_status
};
Expand Down Expand Up @@ -453,10 +449,10 @@ static void set_type(struct i2c_client *c, unsigned int type,
memcpy(analog_ops, &tuner_analog_ops,
sizeof(struct analog_demod_ops));

if (fe_tuner_ops->get_rf_strength == NULL)
analog_ops->has_signal = NULL;
if (fe_tuner_ops->get_afc == NULL)
analog_ops->get_afc = NULL;
if (fe_tuner_ops->get_rf_strength)
analog_ops->has_signal = fe_has_signal;
if (fe_tuner_ops->get_afc)
analog_ops->get_afc = fe_get_afc;

} else {
t->name = analog_ops->info.name;
Expand Down

0 comments on commit 3fc2ecf

Please sign in to comment.