From owner-freebsd-multimedia@FreeBSD.ORG Thu Feb 23 20:39:34 2012 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 3220F106572A for ; Thu, 23 Feb 2012 20:39:33 +0000 (UTC) (envelope-from kwm@rainbow-runner.nl) Received: from fep23.mx.upcmail.net (fep23.mx.upcmail.net [62.179.121.43]) by mx1.freebsd.org (Postfix) with ESMTP id 95A218FC0A for ; Thu, 23 Feb 2012 20:39:32 +0000 (UTC) Received: from edge02.upcmail.net ([192.168.13.237]) by viefep13-int.chello.at (InterMail vM.8.01.05.04 201-2260-151-105-20111014) with ESMTP id <20120223202027.JKAC3333.viefep13-int.chello.at@edge02.upcmail.net>; Thu, 23 Feb 2012 21:20:27 +0100 Received: from [192.168.0.100] ([178.84.137.57]) by edge02.upcmail.net with edge id dYLR1i01A1EUzH602YLR2k; Thu, 23 Feb 2012 21:20:27 +0100 X-SourceIP: 178.84.137.57 Message-ID: <1330028425.3227.4.camel@crashalot.rainbow-runner.nl> From: Koop Mast To: Juergen Lock Date: Thu, 23 Feb 2012 21:20:25 +0100 In-Reply-To: <201202231854.q1NIsgc8088888@triton8.kn-bremen.de> References: <4F32E19A.4050208@googlemail.com> <4F3628F4.4000303@freebsd.org> <4F380CD9.8030308@googlemail.com> <201202122003.39874.hselasky@c2i.net> <201202231854.q1NIsgc8088888@triton8.kn-bremen.de> Content-Type: text/plain; charset="us-ascii" X-Mailer: Evolution 3.2.3 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit Mime-Version: 1.0 Cc: freebsd-multimedia@freebsd.org Subject: Re: v4l_compat lacks V4L2_PIX_FMT_JL2005BCD (and others) 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: Thu, 23 Feb 2012 20:39:34 -0000 On Thu, 2012-02-23 at 19:54 +0100, Juergen Lock wrote: > In article <4F4131AA.5080207@googlemail.com> you write: > >On 2/12/12 8:03 PM, Hans Petter Selasky wrote: > >> On Sunday 12 February 2012 20:02:49 Gregor Jasny wrote: > >>> I prepared an updated v4l_compat archive based on Linux 3.3-rc3 (diff > >>> attached). You can download the tarball here: > >>> > >>> http://alioth.debian.org/~gjasny-guest/v4l_compat-3.3-rc3.tar.gz > >>> > >>> Would it be possible to push this into FreeBSD 9 ports tree? > >> > >> Hi, > >> > >> Looks good, though it should be compile tested with some existing V4L > >> applications first, like VLC, mplayer, pwcview ... > > > >I prepared another tarball (fixes ivtv header and directory structure): > >http://alioth.debian.org/~gjasny-guest/v4l_compat-3.3-rc4.tar.gz > > > >I successfully build libv4l, webcamd and pwcview with it. > > Hi! > > I finally got around looking at this and found at least two patches > are missing in your tarball: > > diff -upr v4l_compat-3.3-rc4/linux/dvb/frontend.h /usr/local/include/linux/dvb/frontend.h > --- v4l_compat-3.3-rc4/linux/dvb/frontend.h 2012-02-19 16:19:51.000000000 +0100 > +++ /usr/local/include/linux/dvb/frontend.h 2011-09-18 06:15:16.000000000 +0200 > @@ -396,7 +373,13 @@ struct dtv_properties { > }; > > #define FE_SET_PROPERTY _IOW('o', 82, struct dtv_properties) > -#define FE_GET_PROPERTY _IOR('o', 83, struct dtv_properties) > +/* > + * This is broken on linux as well but they workaround it in the driver. > + * Since this is impossible to do on FreeBSD fix the header instead. > + * Detailed and discussion : > + * http://lists.freebsd.org/pipermail/freebsd-multimedia/2010-April/010958.html > + */ > +#define FE_GET_PROPERTY _IOW('o', 83, struct dtv_properties) > > > /** > diff -upr v4l_compat-3.3-rc4/linux/input.h /usr/local/include/linux/input.h > --- v4l_compat-3.3-rc4/linux/input.h 2012-02-19 16:18:52.000000000 +0100 > +++ /usr/local/include/linux/input.h 2011-09-18 06:15:16.000000000 +0200 > @@ -140,8 +140,12 @@ struct input_keymap_entry { > #define EVIOCGREP _IOR('E', 0x03, unsigned int[2]) /* get repeat settings */ > #define EVIOCSREP _IOW('E', 0x03, unsigned int[2]) /* set repeat settings */ > > -#define EVIOCGKEYCODE _IOR('E', 0x04, unsigned int[2]) /* get keycode */ > -#define EVIOCGKEYCODE_V2 _IOR('E', 0x04, struct input_keymap_entry) > +/* > + * These two need to be _IOWR not _IOR (they're wrong on Linux too but > + * there the driver doesn't care.) > + */ > +#define EVIOCGKEYCODE _IOWR('E', 0x04, unsigned int[2]) /* get keycode */ > +#define EVIOCGKEYCODE_V2 _IOWR('E', 0x04, struct input_keymap_entry) > #define EVIOCSKEYCODE _IOW('E', 0x04, unsigned int[2]) /* set keycode */ > #define EVIOCSKEYCODE_V2 _IOW('E', 0x04, struct input_keymap_entry) > > > With those applied I build- and runtime-tested successfully (from > ports) v4l-utils (ir-keytable needs the second patch), vdr (which > needs the first), and mplayer for dvb and pwcview for v4l2. > > Thanx! :) > Juergen > > PS: patch also at: > > http://people.freebsd.org/~nox/tmp/v4l_compat-3.3-rc4.patch Hey, Just to note that I will soon sort this mess out. And update the ports. Gregor is updating to libv4l 0.8.6 enough? Because I use the headers from v4l-utils in v4l_compat. -Koop