From owner-freebsd-multimedia@FreeBSD.ORG Mon Feb 15 14:38:50 2010 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 94FBE1065780 for ; Mon, 15 Feb 2010 14:38:50 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe06.swip.net [212.247.154.161]) by mx1.freebsd.org (Postfix) with ESMTP id F1D038FC2D for ; Mon, 15 Feb 2010 14:38:49 +0000 (UTC) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.0 c=1 a=KO_5GujDXrcA:10 a=MnI1ikcADjEx7bvsp0jZvQ==:17 a=PgnWpsbSguqmrfsmZSUA:9 a=Rk0bFRzFnJMxcdmZ7wkA:7 a=E7PnnhV-3tkfn179pNsPhwR-tN8A:4 Received: from [188.126.201.140] (account mc467741@c2i.net HELO laptop002.hselasky.homeunix.org) by mailfe06.swip.net (CommuniGate Pro SMTP 5.2.19) with ESMTPA id 1338976129; Mon, 15 Feb 2010 15:38:48 +0100 From: Hans Petter Selasky To: Joerg Pulz Date: Mon, 15 Feb 2010 15:37:19 +0100 User-Agent: KMail/1.12.4 (FreeBSD/8.0-STABLE; KDE/4.3.4; amd64; ; ) References: In-Reply-To: X-Face: +~\`s("[*|O,="7?X@L.elg*F"OA\I/3%^p8g?ab%RN'(; _IjlA: hGE..Ew, XAQ*o#\/M~SC=S1-f9{EzRfT'|Hhll5Q]ha5Bt-s|oTlKMusi:1e[wJl}kd}GR Z0adGx-x_0zGbZj'e(Y[(UNle~)8CQWXW@:DX+9)_YlB[tIccCPN$7/L' MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201002151537.19382.hselasky@c2i.net> Cc: freebsd-multimedia@freebsd.org Subject: Re: DVB-T (siano sms1xxx) w Video4BSD/Cuse4BSD 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: Mon, 15 Feb 2010 14:38:50 -0000 On Monday 15 February 2010 15:35:46 Joerg Pulz wrote: > Hi, > > today i found some time to try the latest stuff regarding Video4BSD and > DVB-T USB devices. > My system is: > FreeBSD hades.admin.frm2 8.0-STABLE FreeBSD 8.0-STABLE #2: Thu Jan 21 > 12:42:55 CET 2010 root@hades.admin.frm2:/usr/obj/usr/src/sys/GENERIC > amd64 > > My device is a Hauupauge WinTV MiniStick: > usbconfig -u 7 -a 3 dump_device_desc > > ugen7.3: at usbus7, cfg=0 > md=HOST spd=HIGH (480Mbps) pwr=ON > > bLength = 0x0012 > bDescriptorType = 0x0001 > bcdUSB = 0x0200 > bDeviceClass = 0x0000 > bDeviceSubClass = 0x0000 > bDeviceProtocol = 0x0000 > bMaxPacketSize0 = 0x0040 > idVendor = 0x2040 > idProduct = 0x5500 > bcdDevice = 0x0001 > iManufacturer = 0x0001 > iProduct = 0x0002 > iSerialNumber = 0x0003 > bNumConfigurations = 0x0001 > > I svn up'ed the sources (revision 1469) and recompiled. So far everything > wnet fine. I kldload'ed video4bsd and cuse4bsd without errors. > After plugging in the DVB-T stick i tried to start webcamd and it just > bails out with a segmentation fault: > ./webcamd > Attached ugen7.3[0] to cuse unit 0 > Segmentation fault (core dumped) > > After recompiling webcamd with "-g" and using gdb i found that it faults > at: v4l-dvb-82bbb3bd0f0a/linux/drivers/media/dvb/siano/smsusb.c (line 358) > Which is the following line: > snprintf(params.devpath, sizeof(params.devpath), > "usb\\%d-%s", dev->udev->bus->busnum, dev->udev->devpath); > > As i'm not that deep inside Video4BSD i'm lost at this point. > > The only thing i already tried was uncommentig the above line and trying > again. This in fact, solved the segmentation fault and results in the > following output: > > ./webcamd -f /tmp > Attached ugen7.3[0] to cuse unit 0 > Loading firmware at '/tmp/sms1xxx-hcw-55xxx-dvbt-02.fw', f=7 > Creating /dev/dvb/adapter0/demux0 > Creating /dev/dvb/adapter0/dvr0 > Creating /dev/dvb/adapter0/frontend0 > > So it seems the device should work but it doesn't. Whatever i try no > application identifies it as a usable device. > A simple 'cat /dev/dvb/adapter0/dvr0' results in "Device not configured". > May be this is due to uncommenting the code in smsusb.c, i don't know. > What i found by doing a simple 'ls -l /dev/dvb/adapter0' is that the above > mentioned devices (demux0, dvr0 and frontend0) exist twice! > > ls -l /dev/dvb/adapter0 > > crw-r--r-- 1 root operator 0, 224 Feb 15 15:25 demux0 > crw-r--r-- 1 root operator 0, 224 Feb 15 15:25 demux0 > crw------- 1 root operator 0, 225 Feb 15 15:25 demux_daemon0 > crw-r--r-- 1 root operator 0, 226 Feb 15 15:25 dvr0 > crw-r--r-- 1 root operator 0, 226 Feb 15 15:25 dvr0 > crw------- 1 root operator 0, 227 Feb 15 15:25 dvr_daemon0 > crw-r--r-- 1 root operator 0, 228 Feb 15 15:25 frontend0 > crw-r--r-- 1 root operator 0, 228 Feb 15 15:25 frontend0 > crw------- 1 root operator 0, 229 Feb 15 15:25 frontend_daemon0 > > > I don't know how this is possible? Hi, Try to kldload video4bsd, and only have cuse4bsd in the kernel. I will try to fix that segmentation fault. --HPS