From owner-freebsd-multimedia@FreeBSD.ORG Tue Jan 11 22:23:00 2011 Return-Path: Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4C6581065670; Tue, 11 Jan 2011 22:23:00 +0000 (UTC) (envelope-from nox@jelal.kn-bremen.de) Received: from smtp.kn-bremen.de (gelbbaer.kn-bremen.de [78.46.108.116]) by mx1.freebsd.org (Postfix) with ESMTP id D1A598FC15; Tue, 11 Jan 2011 22:22:59 +0000 (UTC) Received: by smtp.kn-bremen.de (Postfix, from userid 10) id 767761E00075; Tue, 11 Jan 2011 23:22:58 +0100 (CET) Received: from triton8.kn-bremen.de (noident@localhost [127.0.0.1]) by triton8.kn-bremen.de (8.14.4/8.14.3) with ESMTP id p0BMKtc6045623; Tue, 11 Jan 2011 23:20:55 +0100 (CET) (envelope-from nox@triton8.kn-bremen.de) Received: (from nox@localhost) by triton8.kn-bremen.de (8.14.4/8.14.3/Submit) id p0BMKtdV045622; Tue, 11 Jan 2011 23:20:55 +0100 (CET) (envelope-from nox) From: Juergen Lock Date: Tue, 11 Jan 2011 23:20:55 +0100 To: "J.R. Oldroyd" Message-ID: <20110111222055.GA44727@triton8.kn-bremen.de> References: <20091204223126.00005392@unknown> <201001081650.14189.hselasky@c2i.net> <20100108114130.1cfe88c5@shibato.opal.com> <201101110947.46399.hselasky@c2i.net> <20110111092609.7bf82016@shibato.opal.com> <20110111183937.GA36761@triton8.kn-bremen.de> <20110111160907.454c74d7@shibato.opal.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20110111160907.454c74d7@shibato.opal.com> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: emulation@freebsd.org, Juergen Lock , freebsd-multimedia@freebsd.org, freebsd-emulation@freebsd.org, Alexander Leidinger Subject: Re: FYI: v4l-linuxulator support in FreeBSD-current now X-BeenThere: freebsd-multimedia@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Multimedia discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Jan 2011 22:23:00 -0000 On Tue, Jan 11, 2011 at 04:09:07PM -0500, J.R. Oldroyd wrote: > On Tue, 11 Jan 2011 15:17:59 -0500, Andrew Gallatin wrote: > > > > On Tue, Jan 11, 2011 at 1:39 PM, Juergen Lock wrote: > > > > >  And FE_[GS]ET_PROPERTY I think are part of the `new' dvb api that > > > was introduced when adding support for dvb-s2, which would also > > > explain why the naive patch appeared to work:  whatever app(s) were > > > used to test it probably were just still using the `old' dvb api. > > > (Well, or the tests were only done on i386. :) > > > > Test was done with just azap, dvbtraffic, and test_dvr on amd64.. > > Yeah those don't use the `new' api I'd say. > > Drew > > At issue is not if the simple patch works for a few apps. At issue > is whether or not FreeBSD should code defensively to protect against > possible problems in the future. > > When I did the V4L shim, my initial test app (Skype) also worked without > much of the structure conversion code. I was asked to write additional > structure conversion code anyway, because it is the correct way to > handle such data when the field sizes are not defined. > > The good news is that the conversion code is not complex. One copy > in function and one copy out function that hande those data types whose > length may vary is needed for each such structure. > Yeah and in this case (FE_[GS]ET_PROPERTY) it is only two structures, tho one of them is an array. (struct dtv_properties and struct dtv_property, and the pointer in struct dtv_property is called reserved2 i.e. its unused.) > The bad news is, as I understand it, that DVB is tied closely to V4L2, > so it may be necessary to implement a complete set of conversion code > for all V4L2 functions, too. Is this the case? I'm not sure. > Isnt v4l2 still about /dev/video*? The dvb api is only about /dev/dvb/adapter*/* and pretty independent... Afaik. > On the other hand, if it is working acceptably now, we could just add > the simpler patch and punt any conversion code until/if something is > found to not work properly, later. At least things that want to be able to use dvb-s2 need the `new' dvb api and thus will have problems. (I know and have here at least the kde4 version of kaffeine, w_scan, szap_s2, and vdr, tho of course I use them natively.) Oh and mythtv I'm pretty sure knows dvb-s2 too. But anyway if you want to merge this version as it is now you want it at least to return errors for the ioctls it doesn't translate, or only do that on amd64. (Or maybe I'll look at this over the weekend myself but I can't promise anything... :) Cheers, Juergen