From nobody Wed Apr 13 23:43:46 2022 X-Original-To: dev-commits-src-all@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 6D55E1B31698; Wed, 13 Apr 2022 23:43:46 +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 4Kdzgk2gBMz3kdb; Wed, 13 Apr 2022 23:43:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1649893426; 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=u+bvymQZiKMCDjgbgnOGi3D1jrdzPbhqukHNIvCfdAw=; b=m1/u6BhlRzx+KJzRqeOpP+d0NNNX5kORa8nwl7yYi6q4EnQgEGj+RessqmAb6oAv9/Wigw 6RHfiB23Sma4myMIlXEH89jmukQG0vqjKvo7LTBMgIEhxs/v5wBnBKP1W+EpxvqiHf0sP6 uJM9fRBkto0/3ZgIiv/0F1rn7YIgMyxlU35QX8OP9yHZVbHsnya7SwvbVCbdNvxlGX614Y 3It2KIAWwb+8AK29kdpOtgPBS3oUWmkmZ/Km3aDVROB4uIDN768bB4wqSu3INEWYijMFtu wK88hJd2UG55ma8NdsWCK+nJ1epe7+fuX5I0NMD7DQzwII5I7GrrS8bSTUYYCQ== 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 3BF9615D88; Wed, 13 Apr 2022 23:43:46 +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 23DNhkuP028578; Wed, 13 Apr 2022 23:43:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 23DNhkHP028577; Wed, 13 Apr 2022 23:43:46 GMT (envelope-from git) Date: Wed, 13 Apr 2022 23:43:46 GMT Message-Id: <202204132343.23DNhkHP028577@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Greg Lehey Subject: git: d45fa9f42406 - stable/13 - Add devices and quirks for some Olympus cameras. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: grog X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d45fa9f42406121e34ea265969663d812fa57e13 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1649893426; 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=u+bvymQZiKMCDjgbgnOGi3D1jrdzPbhqukHNIvCfdAw=; b=C3SWPjAmSoBgRC472A9v3I8s3mhdhxJlM84jraTMGvVfUypgEgy/vHRRvyXj6nYmc9y8z7 LKwGPTN2XhJR0cPXN5Mfs5y4pwHlvvsxEsYESUHw3XO6vQrKTr2o/tMcasDQuyt3oJUYAd 4eJpFgC/lLWKe53QwSkOpDXj46ZmXrsP9iGYEct0TPoQNFPgHo0s9/QsbtFQD+Hw3YUXUJ PrS0RineyQsnfM32h7rGDcU7sAbtncIb+OgPsVnwaKmo+lo2/OF5fHyQwvaJ0s8YcjTi10 G9s/FfqU5//1+Pxzva+chk12A3Rbwaa0HTbIC1EAV8WIpu43GvxuFzBDCnjLow== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1649893426; a=rsa-sha256; cv=none; b=mMgSbowvcmTbcROtBZAKEHVgZIfKyU8ZPiXVzF6oeVzjqK3Hhg7Mj7R1r55SgXgkmuzn+t Os5apR79LoDGDT0r9FTVvpcmGakggckfQDDQPRCntpIz5xkelglrMEPB8Yt6i5sdGMI76L ICiWIqH9mbbv8MzwPrc2aCev50UhtzwGLXy3/SxeAvj55VgM33wZET8bnm/+nOEIpWSjfy ybH3uvYWuwKpY7rVHLI3cLeKUl03f7F1ueW8Je4TSgceX6tR5Slb6Qr1VwV3ABrOdwlaLn PWVnY4lAkoiqrzILv7G6tXZfZPehs49kQ1QqMBM2dOPFfk/PBRCxYHUg4uzJhg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by grog: URL: https://cgit.FreeBSD.org/src/commit/?id=d45fa9f42406121e34ea265969663d812fa57e13 commit d45fa9f42406121e34ea265969663d812fa57e13 Author: Greg Lehey AuthorDate: 2022-03-23 01:40:28 +0000 Commit: Greg Lehey CommitDate: 2022-04-13 23:40:37 +0000 Add devices and quirks for some Olympus cameras. Reviewed by: hps@ Fixes: Problems attaching Olympus cameras. (cherry picked from commit 31e076d70b5fc06e9cd9ecfe19296d4fe6a8a5a5) --- sys/dev/usb/quirk/usb_quirk.c | 35 ++++++++++++++++++++++++++++++++++- sys/dev/usb/usbdevs | 14 ++++++++++++++ 2 files changed, 48 insertions(+), 1 deletion(-) diff --git a/sys/dev/usb/quirk/usb_quirk.c b/sys/dev/usb/quirk/usb_quirk.c index cab6f1b7c074..d86ca5643515 100644 --- a/sys/dev/usb/quirk/usb_quirk.c +++ b/sys/dev/usb/quirk/usb_quirk.c @@ -353,6 +353,39 @@ static struct usb_quirk_entry usb_quirks[USB_DEV_QUIRKS_MAX] = { USB_QUIRK(OLYMPUS, C1, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_WRONG_CSWSIG), USB_QUIRK(OLYMPUS, C700, 0x0000, 0xffff, UQ_MSC_NO_GETMAXLUN), + /* Selected Olympus DSLR and EVIL models. See ../usbdevs for more + * details. + * + * Not all quirks apply to all models. The commented-out entries are + * correct for that model. + */ + USB_QUIRK(OLYMPUS, E_1, 0x0000, 0xffff, UQ_MSC_NO_GETMAXLUN, + UQ_MSC_NO_TEST_UNIT_READY, UQ_MSC_NO_PREVENT_ALLOW, + UQ_MSC_NO_SYNC_CACHE), + /* + * Product code 0x118. + * USB_QUIRK(OLYMPUS, E_300, 0x0000, 0xffff, UQ_MSC_NO_GETMAXLUN, + * UQ_MSC_NO_TEST_UNIT_READY, UQ_MSC_NO_PREVENT_ALLOW, + * UQ_MSC_NO_SYNC_CACHE), + * USB_QUIRK(OLYMPUS, E_30, 0x0000, 0xffff, UQ_MSC_NO_GETMAXLUN, + * UQ_MSC_NO_TEST_UNIT_READY, UQ_MSC_NO_PREVENT_ALLOW, + * UQ_MSC_NO_SYNC_CACHE), */ + USB_QUIRK(OLYMPUS, E_330, 0x0000, 0xffff, UQ_MSC_NO_GETMAXLUN, + UQ_MSC_NO_TEST_UNIT_READY, UQ_MSC_NO_PREVENT_ALLOW, + UQ_MSC_NO_SYNC_CACHE, UQ_MSC_NO_START_STOP), + USB_QUIRK(OLYMPUS, E_PM1, 0x0000, 0xffff, UQ_MSC_NO_GETMAXLUN, + UQ_MSC_NO_TEST_UNIT_READY, UQ_MSC_NO_PREVENT_ALLOW, + UQ_MSC_NO_SYNC_CACHE, UQ_MSC_NO_START_STOP), + /* Product code 0x12e. + * USB_QUIRK(OLYMPUS, E_PM2, 0x0000, 0xffff, 0), + * USB_QUIRK(OLYMPUS, E_M1MarkII, 0x0000, 0xffff, UQ_MSC_NO_GETMAXLUN, + * UQ_MSC_NO_TEST_UNIT_READY, UQ_MSC_NO_PREVENT_ALLOW, + * UQ_MSC_NO_SYNC_CACHE), + * USB_QUIRK(OLYMPUS, E_M5MarkIII, 0x0000, 0xffff, 0), + */ + USB_QUIRK(OLYMPUS, E_M1, 0x0000, 0xffff, UQ_MSC_NO_GETMAXLUN, + UQ_MSC_NO_TEST_UNIT_READY, UQ_MSC_NO_PREVENT_ALLOW, + UQ_MSC_NO_SYNC_CACHE, UQ_MSC_NO_START_STOP), USB_QUIRK(ONSPEC, SDS_HOTFIND_D, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_GETMAXLUN, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(ONSPEC, CFMS_RW, 0x0000, 0xffff, UQ_MSC_FORCE_PROTO_SCSI), @@ -1042,7 +1075,7 @@ usb_quirk_init(void *arg) { char envkey[sizeof(USB_QUIRK_ENVROOT) + 2]; /* 2 digits max, 0 to 99 */ int i; - + /* initialize mutex */ mtx_init(&usb_quirk_mtx, "USB quirk", NULL, MTX_DEF); diff --git a/sys/dev/usb/usbdevs b/sys/dev/usb/usbdevs index 84ff3598750a..b07be3edd241 100644 --- a/sys/dev/usb/usbdevs +++ b/sys/dev/usb/usbdevs @@ -3533,6 +3533,20 @@ product OLIMEX ARM_USB_OCD_H 0x002b FTDI compatible adapter /* Olympus products */ product OLYMPUS C1 0x0102 C-1 Digital Camera product OLYMPUS C700 0x0105 C-700 Ultra Zoom +/* Current Olympus DSLRs and EVIL cameras reuse the same product code and + * bcdDevice for multiple models. This may result in problems with newer + * cameras. */ +/* Olympus DSLRs */ +product OLYMPUS E_1 0x0102 +product OLYMPUS E_300 0x0118 +product OLYMPUS E_330 0x0118 +product OLYMPUS E_30 0x0118 +/* Olympus EVIL cameras */ +product OLYMPUS E_PM1 0x012c +product OLYMPUS E_PM2 0x012e +product OLYMPUS E_M1 0x012e +product OLYMPUS E_M1MarkII 0x012e +product OLYMPUS E_M5MarkIII 0x012e /* OmniVision Technologies, Inc. products */ product OMNIVISION OV511 0x0511 OV511 Camera