From owner-freebsd-multimedia@freebsd.org Sun Aug 28 23:54:38 2016 Return-Path: Delivered-To: freebsd-multimedia@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5FA49BC738E for ; Sun, 28 Aug 2016 23:54:38 +0000 (UTC) (envelope-from miguelmclara@gmail.com) Received: from mail-wm0-x231.google.com (mail-wm0-x231.google.com [IPv6:2a00:1450:400c:c09::231]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id DB2D6A07 for ; Sun, 28 Aug 2016 23:54:37 +0000 (UTC) (envelope-from miguelmclara@gmail.com) Received: by mail-wm0-x231.google.com with SMTP id i5so66970260wmg.0 for ; Sun, 28 Aug 2016 16:54:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=5djKnHng0lZCuRJwzF2bnnWplG81kDbH1KayORGlfck=; b=S+cpzFwQNhaXVbk/A2y9JwFcI6QSjQmMJMlue4ffza5yIjyLq79RO5sIhvADXYjXUX lpwWSszaBA3zpfHQkRw290JS9cuVJfm3WI69rMgEmkt9K95XUGpBElX1TEApirrnfyjj Tid252RONTAvKFDbYCcF7c/bUr5VC55j+4lJUrm0hHP9CBV7/uSWzBZfRZz2DNYiWGHs qg+4vKPtXw1Ztm+Uba/HLRmxOgx6Isckh5oUdhg5t/nw2K7R3D7Dd8jKiUTdHXOP4gkX /Wf4ThCh+QLIEuyl48ld+HqsbcUeC2rMioGMZOEYOybNyFiX1rkumetvhpnAAoZOdHyr 4dIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=5djKnHng0lZCuRJwzF2bnnWplG81kDbH1KayORGlfck=; b=R1RxIby6A6996eWGzLV4uEtCXoTqbSyxEl8MyTFZcLJAgFaCWy5v5cuZ/5w+GXeWhA Z4+rW/NB5NiclRkPtlzrIOU3d2w2+FlaVUqL1C/yBsLHzJrWK2z/tCCJJQ1Q0RXYqbK8 j29+rLSEhpyIVVw0k2oExvYt2/STZK5T1l96cTWHcylCPQQgRtjE2TkgphxPqc0tPNTC Ojax/a2WxmAgl++DHTX1i6DCiG6rUOb7KtHE99nPCW1j5VvYUqMVYZCRx2eTpGD4dDJk IJnmGvBFxz2G/obMY0Cm0iZiWK/tif7XRKiE1gmyhHtCZaWQpsn3wxz3LCwBZ+TuoLJ3 xkaA== X-Gm-Message-State: AE9vXwNU+skdWuaaEWJBcCNlXJMqyAeo22FGXBuB3dkBlYkeJOdTbfb9E/hSCyT6LUNT+aaJGN215e+60PHJoQ== X-Received: by 10.194.57.244 with SMTP id l20mr12827759wjq.1.1472428475983; Sun, 28 Aug 2016 16:54:35 -0700 (PDT) MIME-Version: 1.0 Received: by 10.28.208.65 with HTTP; Sun, 28 Aug 2016 16:53:55 -0700 (PDT) In-Reply-To: References: <050b048b-b73d-0823-885a-e8ab88f070e8@selasky.org> From: Miguel C Date: Mon, 29 Aug 2016 00:53:55 +0100 Message-ID: Subject: Re: [CFT] New version of webcamd, now v4.8.0.2 To: Hans Petter Selasky Cc: Oleg Nauman , "freebsd-multimedia@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.22 X-BeenThere: freebsd-multimedia@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: Multimedia discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 28 Aug 2016 23:54:38 -0000 On Sun, Aug 28, 2016 at 7:21 PM, Hans Petter Selasky wrote: > On 08/28/16 16:02, Miguel C wrote: > >> On Sun, Aug 28, 2016 at 12:53 PM, Hans Petter Selasky >> wrote: >> >> > Hi, > > The descriptors you sent look OK. > > Can you run webcamd from gdb and trace all the parameters and code path > taken inside the function named usb_setup_endpoint which triggers after you > run pwcview ? > > gdb > file webcamd > run -d ugenX.Y > CTRL+C > break usb_setup_endpoint > continue > next > next > next > .... > > > Let's skip Freebsd-current and freebsd-x11 in the CC'ing of this thread to > reduce the amount of cross-posting? Or which list do you prefer? Sure multimedia@ seems fine Lets see if I got this right (let me know if its best to upload this... just feel like its important to keep the "text" in the archive for future reference: gdb) continue Continuing. Creating /dev/video0 [New Thread 802017400 (LWP 100268/webcamd)] [New Thread 802019200 (LWP 100303/webcamd)] [Switching to Thread 802019200 (LWP 100303/webcamd)] Breakpoint 1, usb_setup_endpoint (dev=0x802076000, uhe=0x8020764a0, bufsize=16) at kernel/linux_usb.c:923 923 uint8_t type = uhe->desc.bmAttributes & USB_ENDPOINT_XFERTYPE_MASK; (gdb) next 924 uint8_t addr = uhe->desc.bEndpointAddress; (gdb) next 925 uint8_t ep_index = ((addr / 0x40) | (addr * 4)) % (16 * 4); (gdb) next 928 if (uhe->bsd_xfer[0] || (gdb) next 931 return (0); (gdb) next 1030 } (gdb) next usb_submit_urb (urb=0x802092070, mem_flags=0) at kernel/linux_usb.c:613 613 err = usb_setup_endpoint(urb->dev, uhe, (gdb) next 615 if (err) { (gdb) next 624 if (uhe->bsd_xfer[0] || (gdb) next 629 if (urb->bsd_urb_list.tqe_prev == NULL) { (gdb) next 630 TAILQ_INSERT_TAIL(&uhe->bsd_urb_list, urb, bsd_urb_list); (gdb) next 631 urb->status = -EINPROGRESS; (gdb) next 638 if (urb->bsd_no_resubmit == 0) { (gdb) next 639 usb_submit_urb_sub(uhe->bsd_xfer[0]); (gdb) next 640 usb_submit_urb_sub(uhe->bsd_xfer[1]); (gdb) next 642 err = 0; (gdb) next 643 } else { (gdb) next 648 atomic_unlock(); (gdb) next 649 return (err); (gdb) next 650 } (gdb) next uvc_status_start (dev=0x802047180, flags=0) at media_tree/drivers/media/usb/uvc/uvc_status.c:214 214 return usb_submit_urb(dev->int_urb, flags); (gdb) next 215 } (gdb) next uvc_v4l2_open (file=0x80220d020) at media_tree/drivers/media/usb/uvc/uvc_v4l2.c:514 514 ret = uvc_status_start(stream->dev, GFP_KERNEL); (gdb) next 515 if (ret < 0) { (gdb) next 521 } (gdb) next 523 stream->dev->users++; (gdb) next 524 mutex_unlock(&stream->dev->lock); (gdb) next 526 v4l2_fh_init(&handle->vfh, &stream->vdev); (gdb) next 527 v4l2_fh_add(&handle->vfh); (gdb) next 528 handle->chain = stream->chain; (gdb) next 529 handle->stream = stream; (gdb) next 530 handle->state = UVC_HANDLE_PASSIVE; (gdb) next 531 file->private_data = handle; (gdb) next 533 return 0; (gdb) next 534 } (gdb) next v4l2_open (inode=0x80220d008, filp=0x80220d020) at media_tree/drivers/media/v4l2-core/v4l2-dev.c:453 453 ret = vdev->fops->open(filp); (gdb) next 456 } (gdb) next 458 if (vdev->dev_debug & V4L2_DEV_DEBUG_FOP) (gdb) next 462 if (ret) (gdb) next 464 return ret; (gdb) next 465 } (gdb) next linux_open (f_v4b=0, fflags=0) at kernel/linux_file.c:65 65 return (handle); (gdb) next 66 } (gdb) next v4b_open (cdev=0x802052030, fflags=1) at /usr/home/user/webcamd_src/webcamd-4.8.0.4/webcamd.c:211 211 handle = linux_open(f_v4b, fflags_linux); (gdb) next 213 if (handle == NULL) { (gdb) next 217 cuse_dev_set_per_file_handle(cdev, handle); (gdb) next 218 return (0); (gdb) next 219 } pwcview --> Failed to get current picture info: Invalid argument > > > --HPS >