From 838eb620ba1215af9474305f6102159128cb1bea Mon Sep 17 00:00:00 2001 From: Ralph Metzler Date: Fri, 25 Aug 2017 22:06:07 +0200 Subject: [PATCH] write register with mode last --- frontends/stv090x.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontends/stv090x.c b/frontends/stv090x.c index 1684cf9..5662170 100644 --- a/frontends/stv090x.c +++ b/frontends/stv090x.c @@ -3446,11 +3446,11 @@ err: static int stv090x_set_pls(struct stv090x_state *state, u8 pls_mode, u32 pls_code) { dprintk(FE_DEBUG, 1, "Set PLS code %d (mode %d)", pls_code, pls_mode); - if (STV090x_WRITE_DEMOD(state, PLROOT2, (pls_mode << 2) | (pls_code >> 16)) < 0) + if (STV090x_WRITE_DEMOD(state, PLROOT0, pls_code & 0xff) < 0) goto err; if (STV090x_WRITE_DEMOD(state, PLROOT1, (pls_code >> 8) & 0xff) < 0) goto err; - if (STV090x_WRITE_DEMOD(state, PLROOT0, pls_code & 0xff) < 0) + if (STV090x_WRITE_DEMOD(state, PLROOT2, (pls_mode << 2) | (pls_code >> 16)) < 0) goto err; return 0; err: