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) static int enable_puncture_rate(struct stv *state, enum fe_code_rate rate)
{ {
u8 val;
switch (rate) { switch (rate) {
case FEC_1_2: case FEC_1_2:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff, val = 0x01;
0x01); break;
case FEC_2_3: case FEC_2_3:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff, val = 0x02;
0x02); break;
case FEC_3_4: case FEC_3_4:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff, val = 0x04;
0x04); break;
case FEC_5_6: case FEC_5_6:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff, val = 0x08;
0x08); break;
case FEC_7_8: case FEC_7_8:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff, val = 0x20;
0x20); break;
case FEC_NONE: case FEC_NONE:
default: default:
return write_reg(state, RSTV0910_P2_PRVIT + state->regoff, val = 0x2f;
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) static int set_vth_default(struct stv *state)