From: Simon F. <sim...@on...> - 2007-05-09 08:10:45
|
xi...@za... wrote: >> Our channels.conf format is slightly extended to include tuning-time >> signal strength and SNR as the last two fields of each line (after the >> service ID). We have thus hacked out the offending code in our copy of >> xine, and mainline's tuning is now fast enough for our needs; the big >> slowdown is somewhere in kernel, where FE_GET_INFO is taking around 2 >> seconds (but only if done shortly after opening the front-end device). > > You can turn off some of the kernel silliness by invoking: > > unsigned long mode = FE_TUNE_MODE_ONESHOT; > ioctl(fd, FE_SET_FRONTEND_TUNE_MODE, mode); > > But in any case you will find that bad things happen if you > make your first status check too soon after tuning. > Or if you make subsequent checks less than about 1 second apart. > This is immediately after opening the frontend, before we've attempted to tune. Removing the error handling, the code (around line 600ish of input_dvb.c) looks like: fd = open(frontend_device, O_RDWR); ioctl(fd, FE_GET_INFO, fe_info_ptr); If we put a sleep(10) between open and ioctl, there's no delay. If we don't, the ioctl takes around 2 seconds to return (currently acceptable for our use). The remainder of the mainline input_dvb code is plenty fast enough for us. -- Any clues would be welcome, Simon Farnsworth |