Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[linux-dvb] Re: AVerMedia 771 problems [everything solved]



> I tested it again, it doesn't work with the sleep. But less head
> sounds good. Does it sleep when I unload the driver again? I could
> only load it when needed.

The problem isn't the sleep itself, the problem is that in the CVS code
(at least), the FE_GET_TUNE_SETTINGS internal IOCTL falls through and puts
the module to sleep when the frontend queries these parameters (which it
always does).  The attached patch to the CVS version of mt352.c fixes
this.

The patch also stops the frontend thread from hunting around for a signal
- the MT352 chip has a good capture range and shouldn't really need it.
Wolfram, is there any particular reason you think we want that enabled?
In any case, the chip can take >0.5s to re-acquire all parameters so the
50ms min_delay there is a little short...

Regards
Chris
-- 
Christopher Pascoe
IT Infrastructure Manager
School of Information Technology and Electrical Engineering
The University of Queensland   Brisbane  QLD  4072  Australia
Index: mt352.c
===================================================================
RCS file: /cvs/linuxtv/dvb-kernel/linux/drivers/media/dvb/frontends/mt352.c,v
retrieving revision 1.5
diff -u -r1.5 mt352.c
--- mt352.c	14 Jun 2004 09:54:29 -0000	1.5
+++ mt352.c	26 Jun 2004 11:52:57 -0000
@@ -522,7 +522,7 @@
 	fe_status_t *status;
 	u16 signal;
 #ifdef FE_GET_TUNE_SETTINGS
-	struct dvb_frontend_tune_settings* fe_tune_settings;
+	struct dvb_frontend_tune_settings *fe_tune_settings;
 #endif
 
 	switch (cmd) {
@@ -583,10 +583,11 @@
 
 #ifdef FE_GET_TUNE_SETTINGS
 	case FE_GET_TUNE_SETTINGS:
-		fe_tune_settings = (struct dvb_frontend_tune_settings*) arg;
- 		fe_tune_settings->min_delay_ms = 50;
-		fe_tune_settings->step_size = mt352_info.frequency_stepsize;
-		fe_tune_settings->max_drift = mt352_info.frequency_stepsize*2;
+		fe_tune_settings = (struct dvb_frontend_tune_settings *) arg;
+ 		fe_tune_settings->min_delay_ms = 800;
+		fe_tune_settings->step_size = 0;
+		fe_tune_settings->max_drift = 0;
+		break;
 #endif
 
 	case FE_SLEEP:

Home | Main Index | Thread Index