Commit b71e2c4c authored by Reinhard Nißl's avatar Reinhard Nißl Committed by Mauro Carvalho Chehab

[media] stb0899: store autodetected inversion while tuning in non S2 mode

In non S2 mode, the device is able to autodetect inversion. So
let's store it for tuning to S2 transponders.
Signed-off-by: default avatarReinhard Nißl <rnissl@gmx.de>
Signed-off-by: default avatarMichael Krufky <mkrufky@linuxtv.org>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 0c1d2b14
......@@ -425,6 +425,14 @@ static enum stb0899_status stb0899_search_data(struct stb0899_state *state)
if (internal->status == DATAOK) {
stb0899_read_regs(state, STB0899_CFRM, cfr, 2); /* get derotator frequency */
/* store autodetected IQ swapping as default for DVB-S2 tuning */
reg = stb0899_read_reg(state, STB0899_IQSWAP);
if (STB0899_GETFIELD(SYM, reg))
internal->inversion = IQ_SWAP_ON;
else
internal->inversion = IQ_SWAP_OFF;
internal->derot_freq = state->config->inversion * MAKEWORD16(cfr[0], cfr[1]);
dprintk(state->verbose, FE_DEBUG, 1, "------> DATAOK ! Derot Freq=%d", internal->derot_freq);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment