Skip to content

Commit

Permalink
[media] mb86a20s: Fix the code that estimates the measurement interval
Browse files Browse the repository at this point in the history
Instead of looking at the guard interval field, it was using
the interval length, with is wrong. Fix it.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
  • Loading branch information
Mauro Carvalho Chehab committed Jul 23, 2014
1 parent 4247368 commit 277bfd2
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions drivers/media/dvb-frontends/mb86a20s.c
Original file line number Diff line number Diff line change
Expand Up @@ -556,15 +556,15 @@ static u32 isdbt_rate[3][5][4] = {

static void mb86a20s_layer_bitrate(struct dvb_frontend *fe, u32 layer,
u32 modulation, u32 forward_error_correction,
u32 interleaving,
u32 guard_interval,
u32 segment)
{
struct mb86a20s_state *state = fe->demodulator_priv;
u32 rate;
int mod, fec, guard;

/*
* If modulation/fec/interleaving is not detected, the default is
* If modulation/fec/guard is not detected, the default is
* to consider the lowest bit rate, to avoid taking too long time
* to get BER.
*/
Expand Down Expand Up @@ -602,7 +602,7 @@ static void mb86a20s_layer_bitrate(struct dvb_frontend *fe, u32 layer,
break;
}

switch (interleaving) {
switch (guard_interval) {
default:
case GUARD_INTERVAL_1_4:
guard = 0;
Expand Down Expand Up @@ -693,7 +693,7 @@ static int mb86a20s_get_frontend(struct dvb_frontend *fe)
c->layer[layer].interleaving = rc;
mb86a20s_layer_bitrate(fe, layer, c->layer[layer].modulation,
c->layer[layer].fec,
c->layer[layer].interleaving,
c->guard_interval,
c->layer[layer].segment_count);
}

Expand Down

0 comments on commit 277bfd2

Please sign in to comment.