aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/dvb/ttpci/budget-av.c
diff options
context:
space:
mode:
authorHartmut Birr <e9hack@googlemail.com>2007-04-21 18:17:49 -0400
committerMauro Carvalho Chehab <mchehab@infradead.org>2007-04-27 14:45:46 -0400
commitfd9c66e269a44bd3c6c615957c79b21f3dde69af (patch)
tree586a103569630cd0f3ed376ed3af9de03dbde0bb /drivers/media/dvb/ttpci/budget-av.c
parenta1314b1ab61027ac803b0899ead1ce1229d46a37 (diff)
V4L/DVB (5542): Budget-av: Remove polarity switching of the clock for DVB-C
Remove the polarity switching of the clock for the DVB-C cards in budget-av.c. This hack is no longer necessary because the saa7146 can do the job to remove the additional FEC bytes from the TS. Signed-off-by: Hartmut Birr <e9hack@googlemail.com> Signed-off-by: Oliver Endriss <o.endriss@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/dvb/ttpci/budget-av.c')
-rw-r--r--drivers/media/dvb/ttpci/budget-av.c40
1 files changed, 0 insertions, 40 deletions
diff --git a/drivers/media/dvb/ttpci/budget-av.c b/drivers/media/dvb/ttpci/budget-av.c
index 3035b224c7a3..54ca3a3288e7 100644
--- a/drivers/media/dvb/ttpci/budget-av.c
+++ b/drivers/media/dvb/ttpci/budget-av.c
@@ -66,9 +66,6 @@ struct budget_av {
66 int slot_status; 66 int slot_status;
67 struct dvb_ca_en50221 ca; 67 struct dvb_ca_en50221 ca;
68 u8 reinitialise_demod:1; 68 u8 reinitialise_demod:1;
69 u8 tda10021_poclkp:1;
70 u8 tda10021_ts_enabled;
71 int (*tda10021_set_frontend)(struct dvb_frontend *fe, struct dvb_frontend_parameters *p);
72}; 69};
73 70
74static int ciintf_slot_shutdown(struct dvb_ca_en50221 *ca, int slot); 71static int ciintf_slot_shutdown(struct dvb_ca_en50221 *ca, int slot);
@@ -234,12 +231,6 @@ static int ciintf_slot_reset(struct dvb_ca_en50221 *ca, int slot)
234 if (budget_av->reinitialise_demod) 231 if (budget_av->reinitialise_demod)
235 dvb_frontend_reinitialise(budget_av->budget.dvb_frontend); 232 dvb_frontend_reinitialise(budget_av->budget.dvb_frontend);
236 233
237 /* set tda10021 back to original clock configuration on reset */
238 if (budget_av->tda10021_poclkp) {
239 tda10021_writereg(budget_av->budget.dvb_frontend, 0x12, 0xa0);
240 budget_av->tda10021_ts_enabled = 0;
241 }
242
243 return 0; 234 return 0;
244} 235}
245 236
@@ -256,11 +247,6 @@ static int ciintf_slot_shutdown(struct dvb_ca_en50221 *ca, int slot)
256 ttpci_budget_set_video_port(saa, BUDGET_VIDEO_PORTB); 247 ttpci_budget_set_video_port(saa, BUDGET_VIDEO_PORTB);
257 budget_av->slot_status = SLOTSTATUS_NONE; 248 budget_av->slot_status = SLOTSTATUS_NONE;
258 249
259 /* set tda10021 back to original clock configuration when cam removed */
260 if (budget_av->tda10021_poclkp) {
261 tda10021_writereg(budget_av->budget.dvb_frontend, 0x12, 0xa0);
262 budget_av->tda10021_ts_enabled = 0;
263 }
264 return 0; 250 return 0;
265} 251}
266 252
@@ -276,12 +262,6 @@ static int ciintf_slot_ts_enable(struct dvb_ca_en50221 *ca, int slot)
276 262
277 ttpci_budget_set_video_port(saa, BUDGET_VIDEO_PORTA); 263 ttpci_budget_set_video_port(saa, BUDGET_VIDEO_PORTA);
278 264
279 /* tda10021 seems to need a different TS clock config when data is routed to the CAM */
280 if (budget_av->tda10021_poclkp) {
281 tda10021_writereg(budget_av->budget.dvb_frontend, 0x12, 0xa1);
282 budget_av->tda10021_ts_enabled = 1;
283 }
284
285 return 0; 265 return 0;
286} 266}
287 267
@@ -927,23 +907,6 @@ static u8 read_pwm(struct budget_av *budget_av)
927#define SUBID_DVBT_KNC1 0x0030 907#define SUBID_DVBT_KNC1 0x0030
928#define SUBID_DVBT_CINERGY1200 0x1157 908#define SUBID_DVBT_CINERGY1200 0x1157
929 909
930
931static int tda10021_set_frontend(struct dvb_frontend *fe,
932 struct dvb_frontend_parameters *p)
933{
934 struct budget_av* budget_av = fe->dvb->priv;
935 int result;
936
937 result = budget_av->tda10021_set_frontend(fe, p);
938 if (budget_av->tda10021_ts_enabled) {
939 tda10021_writereg(budget_av->budget.dvb_frontend, 0x12, 0xa1);
940 } else {
941 tda10021_writereg(budget_av->budget.dvb_frontend, 0x12, 0xa0);
942 }
943
944 return result;
945}
946
947static void frontend_init(struct budget_av *budget_av) 910static void frontend_init(struct budget_av *budget_av)
948{ 911{
949 struct saa7146_dev * saa = budget_av->budget.dev; 912 struct saa7146_dev * saa = budget_av->budget.dev;
@@ -1025,9 +988,6 @@ static void frontend_init(struct budget_av *budget_av)
1025 &budget_av->budget.i2c_adap, 988 &budget_av->budget.i2c_adap,
1026 read_pwm(budget_av)); 989 read_pwm(budget_av));
1027 if (fe) { 990 if (fe) {
1028 budget_av->tda10021_poclkp = 1;
1029 budget_av->tda10021_set_frontend = fe->ops.set_frontend;
1030 fe->ops.set_frontend = tda10021_set_frontend;
1031 fe->ops.tuner_ops.set_params = philips_cu1216_tuner_set_params; 991 fe->ops.tuner_ops.set_params = philips_cu1216_tuner_set_params;
1032 } 992 }
1033 break; 993 break;