From owner-freebsd-usb@freebsd.org Tue Apr 26 20:14:01 2016 Return-Path: Delivered-To: freebsd-usb@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 5BF5AB1D33C for ; Tue, 26 Apr 2016 20:14:01 +0000 (UTC) (envelope-from karl@denninger.net) Received: from mail.denninger.net (wsip-70-169-168-7.pn.at.cox.net [70.169.168.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 29B3E1314 for ; Tue, 26 Apr 2016 20:14:00 +0000 (UTC) (envelope-from karl@denninger.net) Received: from [192.168.1.40] (Karl-Desktop.Denninger.net [192.168.1.40]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.denninger.net (Postfix) with ESMTPSA id B2770206EF9 for ; Tue, 26 Apr 2016 15:06:12 -0500 (CDT) To: freebsd-usb@freebsd.org From: Karl Denninger Subject: Byte-banging a USB device attached on ugen Message-ID: Date: Tue, 26 Apr 2016 15:06:01 -0500 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.0 MIME-Version: 1.0 Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg=sha-512; boundary="------------ms010506080501050601050508" X-Content-Filtered-By: Mailman/MimeDel 2.1.21 X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Apr 2016 20:14:01 -0000 This is a cryptographically signed message in MIME format. --------------ms010506080501050601050508 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable So I've got one of these.... ugen0.5: at usbus0 Which is a CM15. It does not appear to attach as an HID or expose a serial-like interface (on a tty or cua device node.) I have documentation of two end-points that this device uses, one for transmitting data to the host and one for receiving commands from the host, along with the byte-format protocol that is expected on each. As such if I can determine how to programmatically access those two end-points I should be good. What I'm having trouble finding documentation on is how to open the device and attach a byte stream to those endpoints on FreeBSD (e.g. how to get it open and specify which endpoint to associate with the handle) and once I do, can I expect to use the usual select() paradigm to see if they're ready for read (e.g. something is on the bus inbound to me) and ready for write (can be written to.) Is there a pointer available somewhere to a code fragment that shows how to do this? I also want to get the device specification as part of the setup, obviously, to make sure I'm talking to the right device and not some other random thing that was plugged in -- my intent is to handle the situation where my code can detect a hot-plug (or unplug) of the device and initialize and/or shut down the channel accordingly and thus I want to iterate over the ugen devices I find and check them for the correct device specification. Thanks in advance! --=20 Karl Denninger karl@denninger.net /The Market Ticker/ /[S/MIME encrypted email preferred]/ --------------ms010506080501050601050508 Content-Type: application/pkcs7-signature; name="smime.p7s" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="smime.p7s" Content-Description: S/MIME Cryptographic Signature MIAGCSqGSIb3DQEHAqCAMIACAQExDzANBglghkgBZQMEAgMFADCABgkqhkiG9w0BBwEAAKCC Bl8wggZbMIIEQ6ADAgECAgEpMA0GCSqGSIb3DQEBCwUAMIGQMQswCQYDVQQGEwJVUzEQMA4G A1UECBMHRmxvcmlkYTESMBAGA1UEBxMJTmljZXZpbGxlMRkwFwYDVQQKExBDdWRhIFN5c3Rl bXMgTExDMRwwGgYDVQQDExNDdWRhIFN5c3RlbXMgTExDIENBMSIwIAYJKoZIhvcNAQkBFhND dWRhIFN5c3RlbXMgTExDIENBMB4XDTE1MDQyMTAyMjE1OVoXDTIwMDQxOTAyMjE1OVowWjEL MAkGA1UEBhMCVVMxEDAOBgNVBAgTB0Zsb3JpZGExGTAXBgNVBAoTEEN1ZGEgU3lzdGVtcyBM TEMxHjAcBgNVBAMTFUthcmwgRGVubmluZ2VyIChPQ1NQKTCCAiIwDQYJKoZIhvcNAQEBBQAD ggIPADCCAgoCggIBALm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Vhnfn7iR/t2nCGCkqvn9z1IIc5DdQrf5p z/oxqu+icbPjGBVbPMAqUzB2n+TcyFkIsZibQoho+mJoK6XwI2sLsLk5FUpu00v20NdNZXRP vWsTecRRPHZXapjAZQ86Kh6KR92m5qr4uGo0MH3HiQY5Rdw9a8josG/meai5O0C9BPIzfGYU W8Gq6r57GS1hTdGJyDFVznIjfvdGstIfMKeYz1dvwK7J3VMEvGinqrWIcqzp3UqhyJ/Apxrq qkkIk3C9vO4W4J5d8TxKzVrghbQAAAAAAAA= --------------ms010506080501050601050508-- From owner-freebsd-usb@freebsd.org Wed Apr 27 05:27:15 2016 Return-Path: Delivered-To: freebsd-usb@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 52592B1D485 for ; Wed, 27 Apr 2016 05:27:15 +0000 (UTC) (envelope-from julian@freebsd.org) Received: from vps1.elischer.org (vps1.elischer.org [204.109.63.16]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "vps1.elischer.org", Issuer "CA Cert Signing Authority" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 319E41D27 for ; Wed, 27 Apr 2016 05:27:14 +0000 (UTC) (envelope-from julian@freebsd.org) Received: from Julian-MBP3.local (50-196-156-133-static.hfc.comcastbusiness.net [50.196.156.133]) (authenticated bits=0) by vps1.elischer.org (8.15.2/8.15.2) with ESMTPSA id u3R5RANF057826 (version=TLSv1.2 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO) for ; Tue, 26 Apr 2016 22:27:13 -0700 (PDT) (envelope-from julian@freebsd.org) Subject: Re: Byte-banging a USB device attached on ugen To: freebsd-usb@freebsd.org References: From: Julian Elischer Message-ID: <9ea9f4ec-f6be-eaca-54cb-4013a3e0c7be@freebsd.org> Date: Wed, 27 Apr 2016 13:27:04 +0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:45.0) Gecko/20100101 Thunderbird/45.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Apr 2016 05:27:15 -0000 On 27/04/2016 4:06 AM, Karl Denninger wrote: > So I've got one of these.... > > ugen0.5: at usbus0 > > Which is a CM15. > > It does not appear to attach as an HID or expose a serial-like interface > (on a tty or cua device node.) > > I have documentation of two end-points that this device uses, one for > transmitting data to the host and one for receiving commands from the > host, along with the byte-format protocol that is expected on each. As > such if I can determine how to programmatically access those two > end-points I should be good. > > What I'm having trouble finding documentation on is how to open the > device and attach a byte stream to those endpoints on FreeBSD (e.g. how > to get it open and specify which endpoint to associate with the handle) > and once I do, can I expect to use the usual select() paradigm to see if > they're ready for read (e.g. something is on the bus inbound to me) and > ready for write (can be written to.) > > Is there a pointer available somewhere to a code fragment that shows how > to do this? I also want to get the device specification as part of the > setup, obviously, to make sure I'm talking to the right device and not > some other random thing that was plugged in -- my intent is to handle > the situation where my code can detect a hot-plug (or unplug) of the > device and initialize and/or shut down the channel accordingly and thus > I want to iterate over the ugen devices I find and check them for the > correct device specification. what you are looking for is libusb I think. https://www.freebsd.org/cgi/man.cgi?apropos=0&sektion=3&query=libusb20&manpath=FreeBSD+5.0-current&format=html you should also look at the webcamd which I think uses it. > > Thanks in advance! > From owner-freebsd-usb@freebsd.org Wed Apr 27 15:22:52 2016 Return-Path: Delivered-To: freebsd-usb@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 44E28B1EB7A for ; Wed, 27 Apr 2016 15:22:52 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 355F6146A for ; Wed, 27 Apr 2016 15:22:52 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id u3RFMpbw047213 for ; Wed, 27 Apr 2016 15:22:52 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-usb@FreeBSD.org Subject: [Bug 208605] Kernel panic when unplug and replug USB WiFi dongle. Date: Wed, 27 Apr 2016 15:22:52 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: wireless X-Bugzilla-Version: 11.0-CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: johannes@brilliantservice.co.jp X-Bugzilla-Status: Closed X-Bugzilla-Resolution: FIXED X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-wireless@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_status resolution Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Apr 2016 15:22:52 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D208605 Johannes Lundberg changed: What |Removed |Added ---------------------------------------------------------------------------- Status|New |Closed Resolution|--- |FIXED --- Comment #4 from Johannes Lundberg --- Seems to been fixed. No more crashes now. Thank you! --=20 You are receiving this mail because: You are on the CC list for the bug.= From owner-freebsd-usb@freebsd.org Sat Apr 30 00:00:21 2016 Return-Path: Delivered-To: freebsd-usb@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 06C4AB20050 for ; Sat, 30 Apr 2016 00:00:21 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EA6261181 for ; Sat, 30 Apr 2016 00:00:20 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id u3U00KtI071290 for ; Sat, 30 Apr 2016 00:00:20 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-usb@FreeBSD.org Subject: [Bug 208632] 11.0-CURRENT crashes after removing TP-LINK TL-WN725N USB Wi-Fi adapter (urtwn) Date: Sat, 30 Apr 2016 00:00:21 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 11.0-CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Many People X-Bugzilla-Who: johannes@brilliantservice.co.jp X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-usb@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Apr 2016 00:00:21 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D208632 Johannes Lundberg changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |johannes@brilliantservice.c | |o.jp --- Comment #3 from Johannes Lundberg --- Solved with fix in bug #208605, comment #3 ? --=20 You are receiving this mail because: You are the assignee for the bug.= From owner-freebsd-usb@freebsd.org Sat Apr 30 14:06:42 2016 Return-Path: Delivered-To: freebsd-usb@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 3DB79B1FFF7 for ; Sat, 30 Apr 2016 14:06:42 +0000 (UTC) (envelope-from karl@denninger.net) Received: from mail.denninger.net (wsip-70-169-168-7.pn.at.cox.net [70.169.168.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DE2A81367 for ; Sat, 30 Apr 2016 14:06:41 +0000 (UTC) (envelope-from karl@denninger.net) Received: from [192.168.1.40] (Karl-Desktop.Denninger.net [192.168.1.40]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.denninger.net (Postfix) with ESMTPSA id 163CE198BEA for ; Sat, 30 Apr 2016 09:06:33 -0500 (CDT) To: freebsd-usb@freebsd.org From: Karl Denninger Subject: Prevent attach of modem serial emulated device on USB attach? Message-ID: <08f991ca-0c97-3d29-8b56-5a4ac9f904f3@denninger.net> Date: Sat, 30 Apr 2016 09:06:13 -0500 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.0 MIME-Version: 1.0 Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg=sha-512; boundary="------------ms020800070801030408070802" X-Content-Filtered-By: Mailman/MimeDel 2.1.22 X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Apr 2016 14:06:42 -0000 This is a cryptographically signed message in MIME format. --------------ms020800070801030408070802 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable So I have managed to get access via ugen to one of the USB devices I want to talk to. I would like to generalize that in a library, but am confounded by a /second /device that comes up "looking like a modem", although it is not. This is convenient if you want to open and deal with it like a modem, but unfortunately that attachment appears to prevent me from successfully using it with the ugen interface at the same time, as the attachment looks like it "eats" the inbound byte stream. Is there a reasonably-easy way to /prevent /FreeBSD from declaring this device eligible to be attached as if it was a character-style modem, leaving it only on ugen? I have figured out how to use devd to change permissions on attach, but not how to prevent it from attaching a generic USB device to a specific driver. --=20 Karl Denninger karl@denninger.net /The Market Ticker/ /[S/MIME encrypted email preferred]/ --------------ms020800070801030408070802 Content-Type: application/pkcs7-signature; name="smime.p7s" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="smime.p7s" Content-Description: S/MIME Cryptographic Signature MIAGCSqGSIb3DQEHAqCAMIACAQExDzANBglghkgBZQMEAgMFADCABgkqhkiG9w0BBwEAAKCC Bl8wggZbMIIEQ6ADAgECAgEpMA0GCSqGSIb3DQEBCwUAMIGQMQswCQYDVQQGEwJVUzEQMA4G A1UECBMHRmxvcmlkYTESMBAGA1UEBxMJTmljZXZpbGxlMRkwFwYDVQQKExBDdWRhIFN5c3Rl bXMgTExDMRwwGgYDVQQDExNDdWRhIFN5c3RlbXMgTExDIENBMSIwIAYJKoZIhvcNAQkBFhND dWRhIFN5c3RlbXMgTExDIENBMB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kkwGIfYbwATetsCYfepCcKxRDuLw42a8O2+2fxJKw y4LJFGXqNgd/1ETebJyKCrEO+wQsUodOQ0Ti87zgIIbd72vMAsHxjazlBklKthun2jvpEMvD C833PjO/xj9qIaJk6MmyXOec6mN25XzrBWtvramcF99TSRF83fEwHr4bDhJUBD9teKIVOtiR ZCJ7dgBMXXXbNY1LgOgLohJQgtVDsrhVdjsngAcqUxltHyH2Ih501vJfM/oSMJ+71rqptSSK tS33ZXPgo6eNKBjpX/1AvXv1Sz+Y1uDIy8wYkrvSEWCCojHCU9jwx6jdRK7aYhBaraE2b9ul WDBfb2/dhzI41TOPsrQMGt+Xe8k5Yz+blQiEzH9uKpRIPBCIW12xWwi2ZSAIUV26aA6DiOPz V71/HMzN1TGO16XCdbCbiJ4KLVBTPbg2JU05JUrCsSjJNqssyWmZcX1hVJuB2fX9rsS62vWY YC0uqomdmsGuBurOzfCcMhZPMegAAAAAAAA= --------------ms020800070801030408070802-- From owner-freebsd-usb@freebsd.org Sat Apr 30 14:11:52 2016 Return-Path: Delivered-To: freebsd-usb@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 D447AB2211D for ; Sat, 30 Apr 2016 14:11:52 +0000 (UTC) (envelope-from hps@selasky.org) Received: from mail.turbocat.net (heidi.turbocat.net [88.198.202.214]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9F2E8151E for ; Sat, 30 Apr 2016 14:11:52 +0000 (UTC) (envelope-from hps@selasky.org) Received: from laptop015.home.selasky.org (unknown [62.141.129.119]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.turbocat.net (Postfix) with ESMTPSA id 993BF1FE022; Sat, 30 Apr 2016 16:11:49 +0200 (CEST) Subject: Re: Prevent attach of modem serial emulated device on USB attach? To: Karl Denninger , freebsd-usb@freebsd.org References: <08f991ca-0c97-3d29-8b56-5a4ac9f904f3@denninger.net> From: Hans Petter Selasky Message-ID: <5724BDEB.3060502@selasky.org> Date: Sat, 30 Apr 2016 16:15:07 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0 MIME-Version: 1.0 In-Reply-To: <08f991ca-0c97-3d29-8b56-5a4ac9f904f3@denninger.net> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Apr 2016 14:11:52 -0000 On 04/30/16 16:06, Karl Denninger wrote: > So I have managed to get access via ugen to one of the USB devices I > want to talk to. > > I would like to generalize that in a library, but am confounded by a > /second /device that comes up "looking like a modem", although it is > not. This is convenient if you want to open and deal with it like a > modem, but unfortunately that attachment appears to prevent me from > successfully using it with the ugen interface at the same time, as the > attachment looks like it "eats" the inbound byte stream. > > Is there a reasonably-easy way to /prevent /FreeBSD from declaring this > device eligible to be attached as if it was a character-style modem, > leaving it only on ugen? I have figured out how to use devd to change > permissions on attach, but not how to prevent it from attaching a > generic USB device to a specific driver. > Hi, Did you try: libusb_detach_kernel_driver() or libusb20_dev_detach_kernel_driver() --HPS From owner-freebsd-usb@freebsd.org Sat Apr 30 15:09:16 2016 Return-Path: Delivered-To: freebsd-usb@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 B0063B22FBE for ; Sat, 30 Apr 2016 15:09:16 +0000 (UTC) (envelope-from karl@denninger.net) Received: from mail.denninger.net (wsip-70-169-168-7.pn.at.cox.net [70.169.168.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 63B7F14E8 for ; Sat, 30 Apr 2016 15:09:15 +0000 (UTC) (envelope-from karl@denninger.net) Received: from [192.168.1.40] (Karl-Desktop.Denninger.net [192.168.1.40]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.denninger.net (Postfix) with ESMTPSA id A9B05198E95 for ; Sat, 30 Apr 2016 10:09:11 -0500 (CDT) Subject: Re: Prevent attach of modem serial emulated device on USB attach? References: <08f991ca-0c97-3d29-8b56-5a4ac9f904f3@denninger.net> <5724BDEB.3060502@selasky.org> To: freebsd-usb@freebsd.org From: Karl Denninger Message-ID: <8c60b86f-de54-f80d-741d-170829dac1c8@denninger.net> Date: Sat, 30 Apr 2016 10:08:52 -0500 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.0 MIME-Version: 1.0 In-Reply-To: <5724BDEB.3060502@selasky.org> Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg=sha-512; boundary="------------ms060605000002090804080904" X-Content-Filtered-By: Mailman/MimeDel 2.1.22 X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Apr 2016 15:09:16 -0000 This is a cryptographically signed message in MIME format. --------------ms060605000002090804080904 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 4/30/2016 09:15, Hans Petter Selasky wrote: > On 04/30/16 16:06, Karl Denninger wrote: >> So I have managed to get access via ugen to one of the USB devices I >> want to talk to. >> >> I would like to generalize that in a library, but am confounded by a >> /second /device that comes up "looking like a modem", although it is >> not. This is convenient if you want to open and deal with it like a >> modem, but unfortunately that attachment appears to prevent me from >> successfully using it with the ugen interface at the same time, as the= >> attachment looks like it "eats" the inbound byte stream. >> >> Is there a reasonably-easy way to /prevent /FreeBSD from declaring thi= s >> device eligible to be attached as if it was a character-style modem, >> leaving it only on ugen? I have figured out how to use devd to change= >> permissions on attach, but not how to prevent it from attaching a >> generic USB device to a specific driver. >> > > Hi, > > Did you try: > > libusb_detach_kernel_driver() or > > libusb20_dev_detach_kernel_driver() > > --HPS I can probably code that into the application but what I'm looking for is something that can be stuck into devd's config (or similar) that will prevent the attachment in the first place when the device is plugged in. The issue is that I have multiple "things" that I want to talk to in this application at the same time, multiplexing them via threads and select(). One of them is only a serial driven thing, and thus I have to live with the reality of a USB serial dongle for those machines that don't have a built-in serial port. Ideally, I'd like to talk to everything that can come up on USB native via the ugen interface, which (for my purposes) is quite good since I don't mind having a second file handle open for write and, what's better, is that since I can open the control instance without blowing things up if someone else has the device open for some purpose I can make very sure I have the right device with the vendor and product Ids before I start trying to talk to i= t. Unfortunately if it's a serial port all I can do is try to probe it, and hope that my off-baud (if I get it wrong) inquiry strings don't cause the device to go insane since (and here's the really bad news) the serial-only one doesn't honor modem control lines as a means of insuring a hard reset. Unfortunately since serial USB interfaces have no consistent order, especially if plugged in after boot, I can't hard-code a config file entry either. If I can prevent this other device from attaching in the first place to a modem port via umodem then at application start I can iterate over the /dev/usb/x.y.0 nodes and, when I find the rights ones, open them up.=20 This leaves me only one possibility in the supported interfaces for a device that appears as a serial interface which will greatly reduce the risk of making that particular device insane. While I can "detach" at program start this doesn't help me with a hot-plug possibility; if I can't prevent the attachment in the first place then I may as well live with the risk of fraggling the "wrong" serial device since if someone plugs or unplugs while it's running I have to accept that risk anyway. --=20 Karl Denninger karl@denninger.net /The Market Ticker/ /[S/MIME encrypted email preferred]/ --------------ms060605000002090804080904 Content-Type: application/pkcs7-signature; name="smime.p7s" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="smime.p7s" Content-Description: S/MIME Cryptographic Signature MIAGCSqGSIb3DQEHAqCAMIACAQExDzANBglghkgBZQMEAgMFADC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gkqhkiG 9w0BCQEWE0N1ZGEgU3lzdGVtcyBMTEMgQ0ECASkwDQYJKoZIhvcNAQEBBQAEggIApcvQ5Mbe pevkO2XvmyM9w1gSVvn5BPFdY63+oeciOtDGlZ+PCVnWzMCTuxFKfSawtRe5f1CuHGe1sDii D0iZgTAZ9PstO1HH6gTvaxfQX2t59jv25MgLWp2uj/BsqY/3fb7VQwzRrexr/U6Ovs8+K/sd POuKgNsoFeG6ChgcaKNuOGFlq3M6eAs/LMUQ/dswJcw+c1SnFGVSqqx1MhS7ZLY69q3GEZbl dcPDPqcWzxCvg5n/IRoD34FWXn2nAjPM9kaBHPpmePTLlW0MERzImZgoVlRP9xeDS8sVdqJZ uJv29VemJUntL7gLVpreoWq1uQuPIb8x03SHKD8+c4Ja+2uZSrF3+ZrLQ8tbTvqvsHfzXRpg BRB0AxnRckxTkNwBgCp4vN8TuIWzKCku0nd82KuBuaBDKwxGvbbik0I3mmBFwtFUuI5H5qoT QYlNbx0bsP1Hgy+Zo7g/3G0T8V8P5eCGoUs3KfbJa1nEc8HhidaNSKF8d6yg5c/RuyBYm7Mw ptfiLHPVwn3CQwE806ijsOzFkvBMPpT8GGjhJEzuHn5jTYZBBdguuk0JDJ2y3IDPuzOWcIBt OxfpGDQ7qi9v2aros9aBcjXbGUs3tTvUMwWRu2v9cBm/uV97laqscqT2XPWhXUPkNoHoj/Vy 5oqWmjjQfQim+ybjlDLioYbYF14AAAAAAAA= --------------ms060605000002090804080904-- From owner-freebsd-usb@freebsd.org Sat Apr 30 15:20:59 2016 Return-Path: Delivered-To: freebsd-usb@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 A877CB0F1E7 for ; Sat, 30 Apr 2016 15:20:59 +0000 (UTC) (envelope-from hps@selasky.org) Received: from mail.turbocat.net (mail.turbocat.net [IPv6:2a01:4f8:d16:4514::2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 421F119A2 for ; Sat, 30 Apr 2016 15:20:59 +0000 (UTC) (envelope-from hps@selasky.org) Received: from laptop015.home.selasky.org (unknown [62.141.129.119]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.turbocat.net (Postfix) with ESMTPSA id 8EEA21FE022; Sat, 30 Apr 2016 17:20:55 +0200 (CEST) Subject: Re: Prevent attach of modem serial emulated device on USB attach? To: Karl Denninger , freebsd-usb@freebsd.org References: <08f991ca-0c97-3d29-8b56-5a4ac9f904f3@denninger.net> <5724BDEB.3060502@selasky.org> <8c60b86f-de54-f80d-741d-170829dac1c8@denninger.net> From: Hans Petter Selasky Message-ID: <5724CE1D.3070105@selasky.org> Date: Sat, 30 Apr 2016 17:24:13 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0 MIME-Version: 1.0 In-Reply-To: <8c60b86f-de54-f80d-741d-170829dac1c8@denninger.net> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Apr 2016 15:20:59 -0000 On 04/30/16 17:08, Karl Denninger wrote: > > > On 4/30/2016 09:15, Hans Petter Selasky wrote: >> On 04/30/16 16:06, Karl Denninger wrote: >>> So I have managed to get access via ugen to one of the USB devices I >>> want to talk to. >>> >>> I would like to generalize that in a library, but am confounded by a >>> /second /device that comes up "looking like a modem", although it is >>> not. This is convenient if you want to open and deal with it like a >>> modem, but unfortunately that attachment appears to prevent me from >>> successfully using it with the ugen interface at the same time, as the >>> attachment looks like it "eats" the inbound byte stream. >>> >>> Is there a reasonably-easy way to /prevent /FreeBSD from declaring this >>> device eligible to be attached as if it was a character-style modem, >>> leaving it only on ugen? I have figured out how to use devd to change >>> permissions on attach, but not how to prevent it from attaching a >>> generic USB device to a specific driver. >>> >> >> Hi, >> >> Did you try: >> >> libusb_detach_kernel_driver() or >> >> libusb20_dev_detach_kernel_driver() >> >> --HPS > > I can probably code that into the application but what I'm looking for > is something that can be stuck into devd's config (or similar) that will > prevent the attachment in the first place when the device is plugged in. > > The issue is that I have multiple "things" that I want to talk to in > this application at the same time, multiplexing them via threads and > select(). One of them is only a serial driven thing, and thus I have to > live with the reality of a USB serial dongle for those machines that > don't have a built-in serial port. Ideally, I'd like to talk to > everything that can come up on USB native via the ugen interface, which > (for my purposes) is quite good since I don't mind having a second file > handle open for write and, what's better, is that since I can open the > control instance without blowing things up if someone else has the > device open for some purpose I can make very sure I have the right > device with the vendor and product Ids before I start trying to talk to it. > > Unfortunately if it's a serial port all I can do is try to probe it, and > hope that my off-baud (if I get it wrong) inquiry strings don't cause > the device to go insane since (and here's the really bad news) the > serial-only one doesn't honor modem control lines as a means of insuring > a hard reset. Unfortunately since serial USB interfaces have no > consistent order, especially if plugged in after boot, I can't hard-code > a config file entry either. > > If I can prevent this other device from attaching in the first place to > a modem port via umodem then at application start I can iterate over the > /dev/usb/x.y.0 nodes and, when I find the rights ones, open them up. > This leaves me only one possibility in the supported interfaces for a > device that appears as a serial interface which will greatly reduce the > risk of making that particular device insane. > > While I can "detach" at program start this doesn't help me with a > hot-plug possibility; if I can't prevent the attachment in the first > place then I may as well live with the risk of fraggling the "wrong" > serial device since if someone plugs or unplugs while it's running I > have to accept that risk anyway. > Hi, This sounds like an USB quirk. We currently don't have such a quirk, but feel free to make a PR for it. A temporary workaround is to unconfigure the device in devd, until the real driver comes around: usbconfig -d X.Y set_config 255 We could possibly add a quirk to leave devices unconfigured after plug. --HPS From owner-freebsd-usb@freebsd.org Sat Apr 30 15:28:58 2016 Return-Path: Delivered-To: freebsd-usb@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 E7031B0F3D6 for ; Sat, 30 Apr 2016 15:28:58 +0000 (UTC) (envelope-from karl@denninger.net) Received: from mail.denninger.net (wsip-70-169-168-7.pn.at.cox.net [70.169.168.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9E5EA1C1C for ; Sat, 30 Apr 2016 15:28:58 +0000 (UTC) (envelope-from karl@denninger.net) Received: from [192.168.1.40] (Karl-Desktop.Denninger.net [192.168.1.40]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.denninger.net (Postfix) with ESMTPSA id D3110198FA3 for ; Sat, 30 Apr 2016 10:28:56 -0500 (CDT) Subject: Re: Prevent attach of modem serial emulated device on USB attach? To: freebsd-usb@freebsd.org References: <08f991ca-0c97-3d29-8b56-5a4ac9f904f3@denninger.net> <5724BDEB.3060502@selasky.org> <8c60b86f-de54-f80d-741d-170829dac1c8@denninger.net> <5724CE1D.3070105@selasky.org> From: Karl Denninger Message-ID: Date: Sat, 30 Apr 2016 10:28:36 -0500 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.0 MIME-Version: 1.0 In-Reply-To: <5724CE1D.3070105@selasky.org> Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg=sha-512; boundary="------------ms040803000207030400090005" X-Content-Filtered-By: Mailman/MimeDel 2.1.22 X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Apr 2016 15:28:59 -0000 This is a cryptographically signed message in MIME format. --------------ms040803000207030400090005 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 4/30/2016 10:24, Hans Petter Selasky wrote: > On 04/30/16 17:08, Karl Denninger wrote: >> >> >> On 4/30/2016 09:15, Hans Petter Selasky wrote: >>> On 04/30/16 16:06, Karl Denninger wrote: >>>> So I have managed to get access via ugen to one of the USB devices I= >>>> want to talk to. >>>> >>>> I would like to generalize that in a library, but am confounded by a= >>>> /second /device that comes up "looking like a modem", although it is= >>>> not. This is convenient if you want to open and deal with it like a= >>>> modem, but unfortunately that attachment appears to prevent me from >>>> successfully using it with the ugen interface at the same time, as t= he >>>> attachment looks like it "eats" the inbound byte stream. >>>> >>>> Is there a reasonably-easy way to /prevent /FreeBSD from declaring >>>> this >>>> device eligible to be attached as if it was a character-style modem,= >>>> leaving it only on ugen? I have figured out how to use devd to chan= ge >>>> permissions on attach, but not how to prevent it from attaching a >>>> generic USB device to a specific driver. >>>> >>> >>> Hi, >>> >>> Did you try: >>> >>> libusb_detach_kernel_driver() or >>> >>> libusb20_dev_detach_kernel_driver() >>> >>> --HPS >> >> I can probably code that into the application but what I'm looking for= >> is something that can be stuck into devd's config (or similar) that wi= ll >> prevent the attachment in the first place when the device is plugged i= n. >> >> The issue is that I have multiple "things" that I want to talk to in >> this application at the same time, multiplexing them via threads and >> select(). One of them is only a serial driven thing, and thus I have = to >> live with the reality of a USB serial dongle for those machines that >> don't have a built-in serial port. Ideally, I'd like to talk to >> everything that can come up on USB native via the ugen interface, whic= h >> (for my purposes) is quite good since I don't mind having a second fil= e >> handle open for write and, what's better, is that since I can open the= >> control instance without blowing things up if someone else has the >> device open for some purpose I can make very sure I have the right >> device with the vendor and product Ids before I start trying to talk >> to it. >> >> Unfortunately if it's a serial port all I can do is try to probe it, a= nd >> hope that my off-baud (if I get it wrong) inquiry strings don't cause >> the device to go insane since (and here's the really bad news) the >> serial-only one doesn't honor modem control lines as a means of insuri= ng >> a hard reset. Unfortunately since serial USB interfaces have no >> consistent order, especially if plugged in after boot, I can't hard-co= de >> a config file entry either. >> >> If I can prevent this other device from attaching in the first place t= o >> a modem port via umodem then at application start I can iterate over t= he >> /dev/usb/x.y.0 nodes and, when I find the rights ones, open them up. >> This leaves me only one possibility in the supported interfaces for a >> device that appears as a serial interface which will greatly reduce th= e >> risk of making that particular device insane. >> >> While I can "detach" at program start this doesn't help me with a >> hot-plug possibility; if I can't prevent the attachment in the first >> place then I may as well live with the risk of fraggling the "wrong" >> serial device since if someone plugs or unplugs while it's running I >> have to accept that risk anyway. >> > > Hi, > > This sounds like an USB quirk. We currently don't have such a quirk, > but feel free to make a PR for it. > > A temporary workaround is to unconfigure the device in devd, until the > real driver comes around: > > usbconfig -d X.Y set_config 255 > > We could possibly add a quirk to leave devices unconfigured after plug.= > > --HPS Is that persistent (and if so, where is it written?) I didn't find documentation on that command in usbconfig's man page... I don't think sending a PR for this is the right thing to do since other people who use this same device may *want* the serial interface emulation..... --=20 Karl Denninger karl@denninger.net /The Market Ticker/ /[S/MIME encrypted email preferred]/ --------------ms040803000207030400090005 Content-Type: application/pkcs7-signature; name="smime.p7s" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="smime.p7s" Content-Description: S/MIME Cryptographic Signature MIAGCSqGSIb3DQEHAqCAMIACAQExDzANBglghkgBZQMEAgMFADCABgkqhkiG9w0BBwEAAKCC Bl8wggZbMIIEQ6ADAgECAgEpMA0GCSqGSIb3DQEBCwUAMIGQMQswCQYDVQQGEwJVUzEQMA4G A1UECBMHRmxvcmlkYTESMBAGA1UEBxMJTmljZXZpbGxlMRkwFwYDVQQKExBDdWRhIFN5c3Rl bXMgTExDMRwwGgYDVQQDExNDdWRhIFN5c3RlbXMgTExDIENBMSIwIAYJKoZIhvcNAQkBFhND dWRhIFN5c3RlbXMgTExDIENBMB4XDTE1MDQyMTAyMjE1OVoXDTIwMDQxOTAyMjE1OVowWjEL MAkGA1UEBhMCVVMxEDAOBgNVBAgTB0Zsb3JpZGExGTAXBgNVBAoTEEN1ZGEgU3lzdGVtcyBM TEMxHjAcBgNV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lTFdWqLrXpFEkbxFyboIjCi1y0KKseoTGkow2gp/bF8to6Ky1y X5uOreakR3wS3cyoOPSq5AzjVI3POyovRCs6zO+HI39+PIQQopCAY9JZPPMqEvW5c4OijHb0 GxSi/g2PZUdioEKiPn38VfErI8/cQb/rO/3t+cfBY6fLFyEco+9ns7LADDW6KmDY9MV6OVZu iVP/vCu+LSwSlwVNnbqGJU4tbKoqwMHFwoiyF45XBjK79G5XUBTHUwIGdsF66vci5up86I2D D5kfJYsFbDVc4WpUZF0iT9u0XXRIiiP7xDwzW5CKIGYfVZqwHzl/345pBKs9TX6XWtf+MHy4 RDdVYZLUu1JCEqXOXpMoxn3++0IAAAAAAAA= --------------ms040803000207030400090005-- From owner-freebsd-usb@freebsd.org Sat Apr 30 17:27:53 2016 Return-Path: Delivered-To: freebsd-usb@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 0A1D2B221E5 for ; Sat, 30 Apr 2016 17:27:53 +0000 (UTC) (envelope-from hps@selasky.org) Received: from mail.turbocat.net (heidi.turbocat.net [88.198.202.214]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C77C41FAE for ; Sat, 30 Apr 2016 17:27:52 +0000 (UTC) (envelope-from hps@selasky.org) Received: from laptop015.home.selasky.org (unknown [62.141.129.119]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.turbocat.net (Postfix) with ESMTPSA id BECB81FE022; Sat, 30 Apr 2016 19:27:49 +0200 (CEST) Subject: Re: Prevent attach of modem serial emulated device on USB attach? To: Karl Denninger , freebsd-usb@freebsd.org References: <08f991ca-0c97-3d29-8b56-5a4ac9f904f3@denninger.net> <5724BDEB.3060502@selasky.org> <8c60b86f-de54-f80d-741d-170829dac1c8@denninger.net> <5724CE1D.3070105@selasky.org> From: Hans Petter Selasky Message-ID: <5724EBDC.7070903@selasky.org> Date: Sat, 30 Apr 2016 19:31:08 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Apr 2016 17:27:53 -0000 On 04/30/16 17:28, Karl Denninger wrote: > Is that persistent (and if so, where is it written?) I didn't find > documentation on that command in usbconfig's man page... Hi, man usb_quirk --HPS