From nobody Tue Jan 18 15:21:25 2022 X-Original-To: freebsd-hackers@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id F003F195E532 for ; Tue, 18 Jan 2022 15:21:43 +0000 (UTC) (envelope-from janm@transactionware.com) Received: from mail3.transactionware.com (mail.transactionware.com [203.14.245.7]) by mx1.freebsd.org (Postfix) with SMTP id 4JdXYc0xSKz3KND for ; Tue, 18 Jan 2022 15:21:39 +0000 (UTC) (envelope-from janm@transactionware.com) Received: (qmail 34631 invoked by uid 907); 18 Jan 2022 15:21:30 -0000 Received: from i5E86417A.versanet.de (HELO smtpclient.apple) (94.134.65.122) (smtp-auth username janm, mechanism plain) by mail3.transactionware.com (qpsmtpd/0.84) with (ECDHE-RSA-AES256-GCM-SHA384 encrypted) ESMTPSA; Wed, 19 Jan 2022 02:21:30 +1100 From: Jan Mikkelsen Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable List-Id: Technical discussions relating to FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-hackers List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-hackers@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.120.0.1.13\)) Subject: Joystick with keyboard, mouse and joystick endpoints disconnects after 3-4 seconds Message-Id: <7A70DD3A-48A9-426A-BB73-7DB1B31BE1E0@transactionware.com> Date: Tue, 18 Jan 2022 16:21:25 +0100 To: freebsd-hackers@freebsd.org X-Mailer: Apple Mail (2.3654.120.0.1.13) X-Rspamd-Queue-Id: 4JdXYc0xSKz3KND X-Spamd-Bar: + Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of janm@transactionware.com has no SPF policy when checking 203.14.245.7) smtp.mailfrom=janm@transactionware.com X-Spamd-Result: default: False [1.93 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MV_CASE(0.50)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[transactionware.com]; AUTH_NA(1.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_SPAM_MEDIUM(0.72)[0.720]; NEURAL_HAM_SHORT(-1.00)[-1.000]; NEURAL_SPAM_LONG(0.71)[0.706]; MLMMJ_DEST(0.00)[freebsd-hackers]; R_SPF_NA(0.00)[no SPF record]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:17559, ipnet:203.14.245.0/24, country:AU]; RCVD_COUNT_TWO(0.00)[2]; MID_RHS_MATCH_FROM(0.00)[] X-ThisMailContainsUnwantedMimeParts: N Hi, When attaching an APEM VM Desktop joystick, = https://www.apem.com/int/vm-desktop-93.html, to a 12.2 system, I get = this sequence of events: ugen0.10: at usbus0 uhid0 numa-domain 0 on uhub2 uhid0: on usbus0 uhid1 numa-domain 0 on uhub2 uhid1: on usbus0 uhid2 numa-domain 0 on uhub2 uhid2: on usbus0 ugen0.10: at usbus0 (disconnected) uhid0: at uhub2, port 5, addr 19 (disconnected) uhid0: detached uhid1: at uhub2, port 5, addr 19 (disconnected) uhid1: detached uhid2: at uhub2, port 5, addr 19 (disconnected) uhid2: detached The disconnection happens about 3-4 seconds after the attachment = completes. The device has three endpoints: A mouse, a keyboard and a joystick. I = have added quirks to have ums and ukbd ignore the device, so that uhid = attaches. I believe that mouse and keyboard endpoints on the same device = are not currently supported. The output from =E2=80=9Cusbconfig dump_all_desc=E2=80=9D is shown = below. Any ideas on where to look to resolve this? Thanks, Jan M. ugen0.10: at usbus0, cfg=3D0 md=3DHOST spd=3DFULL= (12Mbps) pwr=3DON (500mA) bLength =3D 0x0012=20 bDescriptorType =3D 0x0001=20 bcdUSB =3D 0x0200=20 bDeviceClass =3D 0x0000 bDeviceSubClass =3D 0x0000=20 bDeviceProtocol =3D 0x0000=20 bMaxPacketSize0 =3D 0x0008=20 idVendor =3D 0x068e=20 idProduct =3D 0x0064=20 bcdDevice =3D 0x0200=20 iManufacturer =3D 0x0001 iProduct =3D 0x0002 iSerialNumber =3D 0x0000 bNumConfigurations =3D 0x0001=20 Configuration index 0 bLength =3D 0x0009=20 bDescriptorType =3D 0x0002=20 wTotalLength =3D 0x005b=20 bNumInterfaces =3D 0x0003=20 bConfigurationValue =3D 0x0001=20 iConfiguration =3D 0x0000 bmAttributes =3D 0x0080=20 bMaxPower =3D 0x00fa=20 Interface 0 bLength =3D 0x0009=20 bDescriptorType =3D 0x0004=20 bInterfaceNumber =3D 0x0000=20 bAlternateSetting =3D 0x0000=20 bNumEndpoints =3D 0x0002=20 bInterfaceClass =3D 0x0003 bInterfaceSubClass =3D 0x0000=20 bInterfaceProtocol =3D 0x0000=20 iInterface =3D 0x0005 Additional Descriptor bLength =3D 0x09 bDescriptorType =3D 0x21 bDescriptorSubType =3D 0x11 RAW dump:=20 0x00 | 0x09, 0x21, 0x11, 0x01, 0x21, 0x01, 0x22, 0x4b,=20 0x08 | 0x00 Endpoint 0 bLength =3D 0x0007=20 bDescriptorType =3D 0x0005=20 bEndpointAddress =3D 0x0082 bmAttributes =3D 0x0003 wMaxPacketSize =3D 0x0040=20 bInterval =3D 0x000a=20 bRefresh =3D 0x0000=20 bSynchAddress =3D 0x0000=20 Endpoint 1 bLength =3D 0x0007=20 bDescriptorType =3D 0x0005=20 bEndpointAddress =3D 0x0001 bmAttributes =3D 0x0003 wMaxPacketSize =3D 0x0040=20 bInterval =3D 0x000a=20 bRefresh =3D 0x0000=20 bSynchAddress =3D 0x0000=20 Interface 1 bLength =3D 0x0009=20 bDescriptorType =3D 0x0004=20 bInterfaceNumber =3D 0x0001=20 bAlternateSetting =3D 0x0000=20 bNumEndpoints =3D 0x0001=20 bInterfaceClass =3D 0x0003 bInterfaceSubClass =3D 0x0000=20 bInterfaceProtocol =3D 0x0000=20 iInterface =3D 0x0004 Additional Descriptor bLength =3D 0x09 bDescriptorType =3D 0x21 bDescriptorSubType =3D 0x11 RAW dump:=20 0x00 | 0x09, 0x21, 0x11, 0x01, 0x21, 0x01, 0x22, 0x3f,=20 0x08 | 0x00 Endpoint 0 bLength =3D 0x0007=20 bDescriptorType =3D 0x0005=20 bEndpointAddress =3D 0x0083 bmAttributes =3D 0x0003 wMaxPacketSize =3D 0x0008=20 bInterval =3D 0x000a=20 bRefresh =3D 0x0000=20 bSynchAddress =3D 0x0000=20 Interface 2 bLength =3D 0x0009=20 bDescriptorType =3D 0x0004=20 bInterfaceNumber =3D 0x0002=20 bAlternateSetting =3D 0x0000=20 bNumEndpoints =3D 0x0001=20 bInterfaceClass =3D 0x0003 bInterfaceSubClass =3D 0x0000=20 bInterfaceProtocol =3D 0x0000=20 iInterface =3D 0x0003 Additional Descriptor bLength =3D 0x09 bDescriptorType =3D 0x21 bDescriptorSubType =3D 0x11 RAW dump:=20 0x00 | 0x09, 0x21, 0x11, 0x01, 0x21, 0x01, 0x22, 0x34,=20 0x08 | 0x00 Endpoint 0 bLength =3D 0x0007=20 bDescriptorType =3D 0x0005=20 bEndpointAddress =3D 0x0084 bmAttributes =3D 0x0003 wMaxPacketSize =3D 0x0008=20 bInterval =3D 0x000a=20 bRefresh =3D 0x0000=20 bSynchAddress =3D 0x0000=20