> > We should probably use the in-kernel crc32 library... > > Opss... I did not know about it ;) New patch attached. I hope I used the > kernel crc routine in the correct way - ffmpeg likes the PATs and PMTs > produced by the new code, hence it seems that the crc is computed > correctly.
Cool. > Ok. I noticed it because I was calling the MPEG_SETPARAMS ioctl() > without setting video_max_bitrate (I was setting bitrate_mode = > MPEG_BITRATE_MODE_CBR), and the ioctl was not working. > > BTW, there is a bug that I forgot to mention: if the checks in > saa6752hs_init() fail, the ioctl() fails silently (i.e., the return > value is not negative). Since saa6752hs_init() is properly returning a > negative value, I think the problem is somewhere else... Uhm.. I think I > am seeing it: ts_init_encoder() in drivers/media/video/saa7134-ts.c is > always returning 0!!! Can we get a return value from > saa7134_i2c_call_clients()? Ok, I'll try to have a look at it... Ah, yeah, as far as I know it isn't possible. It seems to be a bit of a flaw in the i2c stuff really. I think the best we can do for the moment is bung something in dmesg if something fails. > > > Now, I am thinking about adding code for setting the video format (it > > > is currently hardcoded to D1). Is it ok to add yet another field to > > > mpeg_params? > > > > Fine by me - if you can, try and make it flexible; I was aiming for > > something that used by other MPEG encoders at a future date. > > Unfortunately, I don't know about other MPEG encoders... I see that in > the saa6752hs there is a 1-byte parameter for selecting the video format > (D1, 2/3D1, 1/2D1, or SIF) and I was thinking about adding a field to > mpeg_params for setting the format. But I don't know if this is flexible > enough. Sounds fine - it can always be sorted out if/when another MPEG encoder appears. > Finally, I also have a patch against saa7134-ts.c, for transforming > TS_NR_PACKETS in a module parameter (very useful for reducing the jitter > in the PCR!!!), and I wanted to submit it to Gerd Knorr, but it seems > that the v4l mailing list is not working (or I have been unsubscribed > for some reason, I don't know). I attach it to this mail; maybe you can > submit it when you will submit the next update to saa6752hs.c? Sure, no probs.