From owner-freebsd-multimedia@freebsd.org Thu May 21 12:27:19 2020 Return-Path: Delivered-To: freebsd-multimedia@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id B40B82CDF3C for ; Thu, 21 May 2020 12:27:19 +0000 (UTC) (envelope-from fbl@aoek.com) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 49STQb1Wv5z4v5H for ; Thu, 21 May 2020 12:27:19 +0000 (UTC) (envelope-from fbl@aoek.com) Received: by mailman.nyi.freebsd.org (Postfix) id 344942CDE43; Thu, 21 May 2020 12:27:19 +0000 (UTC) Delivered-To: multimedia@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 340222CE094 for ; Thu, 21 May 2020 12:27:19 +0000 (UTC) (envelope-from fbl@aoek.com) Received: from mail.yourbox.net (mail.yourbox.net [IPv6:2001:41d0:1:767d::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mail.yourbox.net", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 49STQZ239lz4v2c for ; Thu, 21 May 2020 12:27:17 +0000 (UTC) (envelope-from fbl@aoek.com) Received: from mail.yourbox.net (localhost [IPv6:0:0:0:0:0:0:0:1]) by mail.yourbox.net (8.15.2/8.15.2) with ESMTP id 04LCRFWP079446 for ; Thu, 21 May 2020 14:27:15 +0200 (CEST) (envelope-from fbl@aoek.com) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Date: Thu, 21 May 2020 14:27:10 +0200 From: =?UTF-8?Q?Jos=C3=A9_P=C3=A9rez?= To: multimedia@freebsd.org Subject: Re: USB webcam not attaching: proposed patch In-Reply-To: References: <9ae2688ee04cef61ee7e20412da6ed49@mail.yourbox.net> Message-ID: X-Sender: fbl@aoek.com User-Agent: Roundcube Webmail/1.2.0 X-Rspamd-Queue-Id: 49STQZ239lz4v2c X-Spamd-Bar: -- X-Spamd-Result: default: False [-2.18 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.97)[-0.972]; R_DKIM_ALLOW(-0.20)[aoek.com:s=mailbox]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+mx:c]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[multimedia@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.93)[-0.926]; RCVD_TLS_LAST(0.00)[]; DKIM_TRACE(0.00)[aoek.com:+]; DMARC_POLICY_ALLOW(-0.50)[aoek.com,reject]; NEURAL_HAM_SHORT(-0.40)[-0.397]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; R_MIXED_CHARSET(1.11)[subject]; ASN(0.00)[asn:16276, ipnet:2001:41d0::/32, country:FR]; RCVD_COUNT_TWO(0.00)[2] X-BeenThere: freebsd-multimedia@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: Multimedia discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 May 2020 12:27:19 -0000 El 2020-05-21 13:23, Hans Petter Selasky escribió: > Hi, > > The match rule must be narrowed down a bit. > > Can you dump the full configuration and device descriptor for this > device? 0x0a is not correct interface class. This will make trouble > for USB ethernet devices. Hi, is the vendor + intclass enough? Or are there Logitec ethernet devices? --------------------------- CUT --------------------------- --- webcamd.conf.orig 2020-05-21 12:41:25.844895000 +0200 +++ webcamd.conf 2020-05-21 14:19:55.447913000 +0200 @@ -64,3 +64,13 @@ action "/usr/local/etc/rc.d/webcamd start $cdev $interface"; }; +# Logitech webcams +notify 100 { + match "system" "USB"; + match "subsystem" "INTERFACE"; + match "type" "ATTACH"; + + match "vendor" "0x046d"; + match "intclass" "0x0a"; + action "/usr/local/etc/rc.d/webcamd start $cdev"; +}; --------------------------- CUT --------------------------- Anyhow, here you are: # usbconfig -d 1.2 dump_all_desc ugen1.2: at usbus1, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON (500mA) bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0110 bDeviceClass = 0x0000 bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0000 bMaxPacketSize0 = 0x0008 idVendor = 0x046d idProduct = 0x08b3 bcdDevice = 0x0000 iManufacturer = 0x0000 iProduct = 0x0000 iSerialNumber = 0x0000 bNumConfigurations = 0x0001 Configuration index 0 bLength = 0x0009 bDescriptorType = 0x0002 wTotalLength = 0x01fd bNumInterfaces = 0x0003 bConfigurationValue = 0x0001 iConfiguration = 0x0000 bmAttributes = 0x00a0 bMaxPower = 0x00fa Interface 0 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x0000 bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x00ff bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0082 bmAttributes = 0x0003 wMaxPacketSize = 0x0001 bInterval = 0x0064 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0001 wMaxPacketSize = 0x0000 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 0 Alt 1 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x0001 bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x00ff bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0082 bmAttributes = 0x0003 wMaxPacketSize = 0x0001 bInterval = 0x0064 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0001 wMaxPacketSize = 0x00c4 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 0 Alt 2 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x0002 bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x00ff bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0082 bmAttributes = 0x0003 wMaxPacketSize = 0x0001 bInterval = 0x0064 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0001 wMaxPacketSize = 0x0124 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 0 Alt 3 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x0003 bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x00ff bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0082 bmAttributes = 0x0003 wMaxPacketSize = 0x0001 bInterval = 0x0064 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0001 wMaxPacketSize = 0x01c0 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 0 Alt 4 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x0004 bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x00ff bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0082 bmAttributes = 0x0003 wMaxPacketSize = 0x0001 bInterval = 0x0064 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0001 wMaxPacketSize = 0x0250 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 0 Alt 5 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x0005 bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x00ff bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0082 bmAttributes = 0x0003 wMaxPacketSize = 0x0001 bInterval = 0x0064 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0001 wMaxPacketSize = 0x02c0 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 0 Alt 6 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x0006 bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x00ff bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0082 bmAttributes = 0x0003 wMaxPacketSize = 0x0001 bInterval = 0x0064 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0001 wMaxPacketSize = 0x0308 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 0 Alt 7 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x0007 bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x00ff bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0082 bmAttributes = 0x0003 wMaxPacketSize = 0x0001 bInterval = 0x0064 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0001 wMaxPacketSize = 0x0348 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 0 Alt 8 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x0008 bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x00ff bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0082 bmAttributes = 0x0003 wMaxPacketSize = 0x0001 bInterval = 0x0064 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0001 wMaxPacketSize = 0x0380 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 0 Alt 9 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x0009 bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x00ff bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0082 bmAttributes = 0x0003 wMaxPacketSize = 0x0001 bInterval = 0x0064 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0001 wMaxPacketSize = 0x03c0 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 0 Alt 10 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x000a bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x00ff bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0082 bmAttributes = 0x0003 wMaxPacketSize = 0x0001 bInterval = 0x0064 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0001 wMaxPacketSize = 0x03c0 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 1 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0001 bAlternateSetting = 0x0000 bNumEndpoints = 0x0000 bInterfaceClass = 0x0001