simply enable_puncture_rate

This commit is contained in:
Ralph Metzler 2017-10-27 13:11:11 +02:00
parent 9e5576c562
commit ca3c26808f
1 changed files with 15 additions and 13 deletions

View File

@ -897,28 +897,30 @@ static int init_search_param(struct stv *state)
static int enable_puncture_rate(struct stv *state, enum fe_code_rate rate)
{
u8 val;
switch (rate) {
case FEC_1_2:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff,
0x01);
val = 0x01;
break;
case FEC_2_3:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff,
0x02);
val = 0x02;
break;
case FEC_3_4:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff,
0x04);
val = 0x04;
break;
case FEC_5_6:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff,
0x08);
val = 0x08;
break;
case FEC_7_8:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff,
0x20);
val = 0x20;
break;
case FEC_NONE:
default:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff,
0x2f);
val = 0x2f;
break;
}
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff, 0x2f);
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff, val);
}
static int set_vth_default(struct stv *state)