[mythtv-commits] mythtv commit: r8207 by danielk

mythtv at cvs.mythtv.org mythtv at cvs.mythtv.org
Fri Dec 9 13:09:27 EST 2005


      Author: danielk
        Date: 2005-12-09 18:09:26 +0000 (Fri, 09 Dec 2005)
New Revision: 8207
   Changeset: http://cvs.mythtv.org/trac/changeset/8207

Added:

   trunk/mythtv/libs/libmythtv/DeviceReadBuffer.cpp
   trunk/mythtv/libs/libmythtv/DeviceReadBuffer.h

Modified:

   trunk/mythtv/libs/libmythtv/dvbrecorder.cpp
   trunk/mythtv/libs/libmythtv/dvbrecorder.h
   trunk/mythtv/libs/libmythtv/libmythtv.pro

Log:

References #712. References #551.

This adds the DeviceReadBuffer to the DVBRecorder. This is taken from the same functionality in HDTVRecorder written by John Poet, except it has been extended to allow for non-blocking file descriptors.

This doesn't close the ticket because I'd like to replace the same functionality in HDTVRecorder with the DeviceReadBuffer with a non-blocking file descriptor. But this does make the rest of this is non-critical for 0.19. I've tested this by running 'dd if=/dev/zero of=/video/zero.tmp' while recording, there were no lost packets...

There are two important defines. If you comment out "#define USE_DRB" in dvbrecorder.cpp, it will fallback to relying on the buffering in the driver. If you change "#define REPORT_RING_STATS 0" in DeviceReadBuffer.cpp to "#define REPORT_RING_STATS 1", then it will print out buffer usage information every 20 seconds.

WRT #551. I did my testing for this patch using the XFS file system. Brandon reported to me earlier this week that switching from ReiserFS3 to XFS made his problem much less severe even without the DRB patch (He had a problem recording multiple HDTV streams, triggered by a reschedule). If anyone reports disk write performance problems in the future we should insist that they switch to XFS or JFS before spending too much time on the problem. With ReiserFS3 the problem continues long after the reschedule, but with XFS the problem only lasts a few seconds and then goes away. Of course with this commit, neither file system should cause any problems to the DVBRecorder, but the bttv and ivtv recorders could theoretically experience similar problems (though in practice they have much less data to write).






More information about the mythtv-commits mailing list