diff options
author | Malcolm Priestley <tvboxspy@gmail.com> | 2013-12-28 12:04:51 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2014-01-07 06:40:34 -0500 |
commit | a6d8e68b60703eb4779c502ec15a627c505c34da (patch) | |
tree | 11acbbd68b9fd2cf4d1910217063bc021a6d92fa /drivers/media | |
parent | 49c44802a79ca558c78d9b86f4c1ff6bb5ba0208 (diff) |
[media] m88rs2000: Correct m88rs2000_get_fec
Value of fec is achieved by the upper nibble bits 6,7 & 8.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/dvb-frontends/m88rs2000.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/drivers/media/dvb-frontends/m88rs2000.c b/drivers/media/dvb-frontends/m88rs2000.c index 002b109d9383..b2351466b0da 100644 --- a/drivers/media/dvb-frontends/m88rs2000.c +++ b/drivers/media/dvb-frontends/m88rs2000.c | |||
@@ -581,18 +581,20 @@ static fe_code_rate_t m88rs2000_get_fec(struct m88rs2000_state *state) | |||
581 | reg = m88rs2000_readreg(state, 0x76); | 581 | reg = m88rs2000_readreg(state, 0x76); |
582 | m88rs2000_writereg(state, 0x9a, 0xb0); | 582 | m88rs2000_writereg(state, 0x9a, 0xb0); |
583 | 583 | ||
584 | reg &= 0xf0; | ||
585 | reg >>= 5; | ||
586 | |||
584 | switch (reg) { | 587 | switch (reg) { |
585 | case 0x88: | 588 | case 0x4: |
586 | return FEC_1_2; | 589 | return FEC_1_2; |
587 | case 0x68: | 590 | case 0x3: |
588 | return FEC_2_3; | 591 | return FEC_2_3; |
589 | case 0x48: | 592 | case 0x2: |
590 | return FEC_3_4; | 593 | return FEC_3_4; |
591 | case 0x28: | 594 | case 0x1: |
592 | return FEC_5_6; | 595 | return FEC_5_6; |
593 | case 0x18: | 596 | case 0x0: |
594 | return FEC_7_8; | 597 | return FEC_7_8; |
595 | case 0x08: | ||
596 | default: | 598 | default: |
597 | break; | 599 | break; |
598 | } | 600 | } |