From nobody Wed Jan 25 07:48:31 2023 X-Original-To: dev-commits-src-branches@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 4P1wv32jS8z3byQP; Wed, 25 Jan 2023 07:48:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (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 (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4P1wv31rtBz3Mxn; Wed, 25 Jan 2023 07:48:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1674632911; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iYLTnIyCYxAu4WbTlQoWLMWXp+0x1kn54HV9rI2AzVA=; b=p6wxTdK4YIjteVykbe0LtRb2HDBMx/kjnw/dlxnvVQl9ZbeGfxhy/qMDZXiPnKBYg7y+it cGpJ7XqFJEMeHpsxfnW6aeNNvqBIjCs0V4z9cUGspNiPe2cZuBZeaPevhYM8ArcgZ3rfaq zEWvVKhRhlMwmJWBesV0bP7Ow5G7uffEOT6FOpwVzweLAbhxMFQsjCJ6KK3FmF3oXnzAtx wYL5gIrHwQxMFFSEHx1xnXcoQKRDjwqvZV0YyDdEr/hiB8W+4+d8Ib8QNeVArsoL0decSA C/3lLVGtrcoJp5XuLk6ooOpM6wPikVpsa2bGmCdk32zr2pIwbABf4htH+hdcSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1674632911; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iYLTnIyCYxAu4WbTlQoWLMWXp+0x1kn54HV9rI2AzVA=; b=IpBc/ZRdsaWw9D0wSiVq2v9oTYOYV4Y9t3GQdUPfiNIb/2omGEW15HtVK4la2vxF9UkO+r z74vYn+uUgxjKlZkfZ8mjkGTpX7FjxkEWWkI235jyJURSsyo4XOBEpJgT3XpB44QDTUHvG ia2koyUcTHTI4iWjbHd5qmLDmFy7PCp6pCFZvUiAD4816xsxL4WWay0n8qqEpRnzfBzYyj O1TBwCpMqGWg3/m9BYiYBzezLUY90QQyFG8/1EivpTsb6FdTs5zhLNN6NBu8KvFf3uG7l/ taRwbG2pi/SdG9tI3q2XaMZtIOFEZIXgmrppqK2yydc4Ag+aBrXNXQTgsoH1Gw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1674632911; a=rsa-sha256; cv=none; b=IxCDetD6fteZzRXIKgBfTo919vAXWrhndQPgpFAilLb2q3gXOZkD53oO23V1GVo2LO6eui XRKo9BW++nqUjk44z3xUefrapN2UqE9ZeQEc1jOTm7RdOejFBTCgadomwi+APWbkoE2B06 D8F8dG6hbKEXdQLztK+lnW/FUjes9Gch82MC0IRrIX64o2f57+B9Enub6v1e3DNwFSpflN vu3w2x8HWm3oPS7F2C8GLtyfR1+TACd7zTrh3/tYjDEeiCc5qvgsyS5QSoF9fdTznKtCr9 /HwPAQoeiuBr5xc48q2s7fHonWkH8qQxgYQdXudaymW2Z7zeJjMN/OCtoovn+Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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 did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4P1wv30yH1zhY1; Wed, 25 Jan 2023 07:48:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 30P7mVdi013201; Wed, 25 Jan 2023 07:48:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 30P7mVBF013200; Wed, 25 Jan 2023 07:48:31 GMT (envelope-from git) Date: Wed, 25 Jan 2023 07:48:31 GMT Message-Id: <202301250748.30P7mVBF013200@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: =?utf-8?Q?Corvin=20K=C3=B6hne?= Subject: git: 026b0ff652e3 - stable/13 - umodem: ignore CDC_CM descriptor for baltech smartcard reader List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: corvink X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 026b0ff652e327ff850e643a7ab8d78fa9e56412 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by corvink: URL: https://cgit.FreeBSD.org/src/commit/?id=026b0ff652e327ff850e643a7ab8d78fa9e56412 commit 026b0ff652e327ff850e643a7ab8d78fa9e56412 Author: Steffen Dirkwinkel AuthorDate: 2022-11-04 14:46:07 +0000 Commit: Corvin Köhne CommitDate: 2023-01-25 06:55:13 +0000 umodem: ignore CDC_CM descriptor for baltech smartcard reader The CDC_CM descriptor points to the wrong interface for serial port use. Ignore it to use the CDC_UNION descriptor. usbconfig dump (spec at: https://usb.org/sites/default/files/CDC1.2_WMC1.1_012011.zip): ugen0.2: at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON (300mA) bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0200 bDeviceClass = 0x0000 bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0000 bMaxPacketSize0 = 0x0040 idVendor = 0x13ad idProduct = 0xf019 bcdDevice = 0x0100 iManufacturer = 0x0001 iProduct = 0x0002 iSerialNumber = 0x0003 <45031910> bNumConfigurations = 0x0001 Configuration index 0 bLength = 0x0009 bDescriptorType = 0x0002 wTotalLength = 0x0064 bNumInterfaces = 0x0003 bConfigurationValue = 0x0001 iConfiguration = 0x0000 bmAttributes = 0x0080 bMaxPower = 0x0096 Interface 0 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0000 bAlternateSetting = 0x0000 bNumEndpoints = 0x0001 bInterfaceClass = 0x0003 bInterfaceSubClass = 0x0000 bInterfaceProtocol = 0x0000 iInterface = 0x0000 Additional Descriptor bLength = 0x09 bDescriptorType = 0x21 bDescriptorSubType = 0x11 RAW dump: 0x00 | 0x09, 0x21, 0x11, 0x01, 0x00, 0x01, 0x22, 0xd0, 0x08 | 0x00 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0081 bmAttributes = 0x0003 wMaxPacketSize = 0x0040 bInterval = 0x0001 bRefresh = 0x0000 bSynchAddress = 0x0000 Additional Descriptor bLength = 0x08 bDescriptorType = 0x0b bDescriptorSubType = 0x01 RAW dump: 0x00 | 0x08, 0x0b, 0x01, 0x02, 0x02, 0x02, 0x00, 0x00 Interface 1 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0001 bAlternateSetting = 0x0000 bNumEndpoints = 0x0001 bInterfaceClass = 0x0002 bInterfaceSubClass = 0x0002 bInterfaceProtocol = 0x0000 iInterface = 0x0000 Additional Descriptor bLength = 0x05 bDescriptorType = 0x24 bDescriptorSubType = 0x00 RAW dump: 0x00 | 0x05, 0x24, 0x00, 0x10, 0x01 Additional Descriptor bLength = 0x04 bDescriptorType = 0x24 bDescriptorSubType = 0x02 RAW dump: 0x00 | 0x04, 0x24, 0x02, 0x00 Additional Descriptor bLength = 0x05 bDescriptorType = 0x24 bDescriptorSubType = 0x06 RAW dump: 0x00 | 0x05, 0x24, 0x06, 0x01, 0x02 Additional Descriptor bLength = 0x05 bDescriptorType = 0x24 bDescriptorSubType = 0x01 RAW dump: 0x00 | 0x05, 0x24, 0x01, 0x00, 0x01 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0085 bmAttributes = 0x0003 wMaxPacketSize = 0x0008 bInterval = 0x0010 bRefresh = 0x0000 bSynchAddress = 0x0000 Interface 2 bLength = 0x0009 bDescriptorType = 0x0004 bInterfaceNumber = 0x0002 bAlternateSetting = 0x0000 bNumEndpoints = 0x0002 bInterfaceClass = 0x000a bInterfaceSubClass = 0x0000 bInterfaceProtocol = 0x0000 iInterface = 0x0000 Endpoint 0 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0086 bmAttributes = 0x0002 wMaxPacketSize = 0x0040 bInterval = 0x0000 bRefresh = 0x0000 bSynchAddress = 0x0000 Endpoint 1 bLength = 0x0007 bDescriptorType = 0x0005 bEndpointAddress = 0x0006 bmAttributes = 0x0002 wMaxPacketSize = 0x0040 bInterval = 0x0000 bRefresh = 0x0000 bSynchAddress = 0x0000 Reviewed by: manu MFC after: 1 week Sponsored by: Beckhoff Automation GmbH & Co. KG Differential Revision: https://reviews.freebsd.org/D37942 (cherry picked from commit 8580e334b0757c8d55e51b8dc7fc4051521beedf) --- sys/dev/usb/quirk/usb_quirk.c | 1 + sys/dev/usb/usbdevs | 1 + 2 files changed, 2 insertions(+) diff --git a/sys/dev/usb/quirk/usb_quirk.c b/sys/dev/usb/quirk/usb_quirk.c index e35297b2340c..3dd2aa735fb3 100644 --- a/sys/dev/usb/quirk/usb_quirk.c +++ b/sys/dev/usb/quirk/usb_quirk.c @@ -188,6 +188,7 @@ static struct usb_quirk_entry usb_quirks[USB_DEV_QUIRKS_MAX] = { USB_QUIRK(CURITEL, UM150, 0x0000, 0xffff, UQ_ASSUME_CM_OVER_DATA), USB_QUIRK(CURITEL, UM175, 0x0000, 0xffff, UQ_ASSUME_CM_OVER_DATA), USB_QUIRK(VERTEX, VW110L, 0x0000, 0xffff, UQ_ASSUME_CM_OVER_DATA), + USB_QUIRK(BALTECH, SMARTCARDREADER, 0x0000, 0xffff, UQ_IGNORE_CDC_CM), /* USB Mass Storage Class Quirks */ USB_QUIRK_VP(USB_VENDOR_ASAHIOPTICAL, 0, UQ_MSC_NO_RS_CLEAR_UA, diff --git a/sys/dev/usb/usbdevs b/sys/dev/usb/usbdevs index fcacc1d8e83f..6960ac8a33e2 100644 --- a/sys/dev/usb/usbdevs +++ b/sys/dev/usb/usbdevs @@ -1337,6 +1337,7 @@ product AZUREWAVE RTL8192SU_5 0x3325 RTL8192SU /* Baltech products */ product BALTECH CARDREADER 0x9999 Card reader +product BALTECH SMARTCARDREADER 0xf019 SmartCard reader /* Bayer products */ product BAYER CONTOUR_CABLE 0x6001 FTDI compatible adapter