diff options
author | Manu Abraham <manu@kromtek.com> | 2005-05-28 18:51:51 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-05-28 19:46:10 -0400 |
commit | 86360a3edeb6b7b6230dc13ef6835d2851409502 (patch) | |
tree | 654e06d466ae9b746739cb4a4f0b11dce88d080d /drivers/media/dvb/bt8xx/dst.c | |
parent | 8f6da8f166228c1720d16216a9d82d630c58de57 (diff) |
[PATCH] dvb: Fix 22k tone control
Signed-off-by: Manu Abraham <manu@kromtek.com>
Cc: Johannes Stezenbach <js@linuxtv.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/media/dvb/bt8xx/dst.c')
-rw-r--r-- | drivers/media/dvb/bt8xx/dst.c | 27 |
1 files changed, 9 insertions, 18 deletions
diff --git a/drivers/media/dvb/bt8xx/dst.c b/drivers/media/dvb/bt8xx/dst.c index 33cca69d67a7..8104240a2208 100644 --- a/drivers/media/dvb/bt8xx/dst.c +++ b/drivers/media/dvb/bt8xx/dst.c | |||
@@ -907,12 +907,7 @@ static int dst_tone_power_cmd(struct dst_state* state) | |||
907 | return 0; | 907 | return 0; |
908 | 908 | ||
909 | paket[4] = state->tx_tuna[4]; | 909 | paket[4] = state->tx_tuna[4]; |
910 | 910 | paket[2] = state->tx_tuna[2]; | |
911 | if (state->tone == SEC_TONE_ON) | ||
912 | paket[2] = 0x02; | ||
913 | else | ||
914 | paket[2] = 0; | ||
915 | |||
916 | paket[3] = state->tx_tuna[3]; | 911 | paket[3] = state->tx_tuna[3]; |
917 | paket[7] = dst_check_sum (paket, 7); | 912 | paket[7] = dst_check_sum (paket, 7); |
918 | dst_command(state, paket, 8); | 913 | dst_command(state, paket, 8); |
@@ -1094,7 +1089,6 @@ static int dst_set_voltage(struct dvb_frontend* fe, fe_sec_voltage_t voltage) | |||
1094 | 1089 | ||
1095 | static int dst_set_tone(struct dvb_frontend* fe, fe_sec_tone_mode_t tone) | 1090 | static int dst_set_tone(struct dvb_frontend* fe, fe_sec_tone_mode_t tone) |
1096 | { | 1091 | { |
1097 | u8 *val; | ||
1098 | struct dst_state* state = fe->demodulator_priv; | 1092 | struct dst_state* state = fe->demodulator_priv; |
1099 | 1093 | ||
1100 | state->tone = tone; | 1094 | state->tone = tone; |
@@ -1102,20 +1096,17 @@ static int dst_set_tone(struct dvb_frontend* fe, fe_sec_tone_mode_t tone) | |||
1102 | if (state->dst_type == DST_TYPE_IS_TERR) | 1096 | if (state->dst_type == DST_TYPE_IS_TERR) |
1103 | return 0; | 1097 | return 0; |
1104 | 1098 | ||
1105 | val = &state->tx_tuna[0]; | ||
1106 | |||
1107 | val[8] &= ~0x1; | ||
1108 | |||
1109 | switch (tone) { | 1099 | switch (tone) { |
1110 | case SEC_TONE_OFF: | 1100 | case SEC_TONE_OFF: |
1111 | break; | 1101 | state->tx_tuna[2] = 0xff; |
1102 | break; | ||
1112 | 1103 | ||
1113 | case SEC_TONE_ON: | 1104 | case SEC_TONE_ON: |
1114 | val[8] |= 1; | 1105 | state->tx_tuna[2] = 0x02; |
1115 | break; | 1106 | break; |
1116 | 1107 | ||
1117 | default: | 1108 | default: |
1118 | return -EINVAL; | 1109 | return -EINVAL; |
1119 | } | 1110 | } |
1120 | dst_tone_power_cmd(state); | 1111 | dst_tone_power_cmd(state); |
1121 | 1112 | ||