From owner-freebsd-usb@FreeBSD.ORG Wed Sep 8 07:51:17 2010 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 45C8B10656DC for ; Wed, 8 Sep 2010 07:51:17 +0000 (UTC) (envelope-from nick@van-laarhoven.org) Received: from cpsmtpb-ews08.kpnxchange.com (cpsmtpb-ews08.kpnxchange.com [213.75.39.13]) by mx1.freebsd.org (Postfix) with ESMTP id BF5558FC13 for ; Wed, 8 Sep 2010 07:51:16 +0000 (UTC) Received: from cpbrm-ews14.kpnxchange.com ([10.94.84.145]) by cpsmtpb-ews08.kpnxchange.com with Microsoft SMTPSVC(6.0.3790.4675); Wed, 8 Sep 2010 09:51:15 +0200 Received: from CPSMTPM-EML102.kpnxchange.com ([195.121.3.6]) by cpbrm-ews14.kpnxchange.com with Microsoft SMTPSVC(6.0.3790.4675); Wed, 8 Sep 2010 09:51:15 +0200 Received: from uitsmijter.van-laarhoven.org ([81.207.207.222]) by CPSMTPM-EML102.kpnxchange.com with Microsoft SMTPSVC(7.0.6002.18222); Wed, 8 Sep 2010 09:51:14 +0200 Received: from host77-63-187-248.kpn-gprs.nl (host77-63-187-248.kpn-gprs.nl [77.63.187.248] (may be forged)) (authenticated bits=0) by uitsmijter.van-laarhoven.org (8.14.4/8.14.4) with ESMTP id o887p99p048705; Wed, 8 Sep 2010 09:51:10 +0200 (CEST) (envelope-from nick@van-laarhoven.org) Mime-Version: 1.0 (Apple Message framework v1081) Content-Type: text/plain; charset=us-ascii From: Nick Hibma In-Reply-To: <201009080900.46802.hselasky@c2i.net> Date: Wed, 8 Sep 2010 09:51:08 +0200 Content-Transfer-Encoding: quoted-printable Message-Id: <598B1BC2-3B47-4188-A637-1831C49477B3@van-laarhoven.org> References: <43EC7D78-31E5-4B86-9316-002AE650727A@tlb.org> <20100505121841.ce3cf358.ray@dlink.ua> <03EA4629-81F5-442C-9064-95E1A265D8AD@van-laarhoven.org> <201009080900.46802.hselasky@c2i.net> To: Hans Petter Selasky X-Mailer: Apple Mail (2.1081) X-Spam-Status: No, score=-7.4 required=5.0 tests=FH_HELO_EQ_D_D_D_D, J_CHICKENPOX_12, MAY_BE_FORGED, MR_DIFF_MID, MR_NOT_ATTRIBUTED_IP, RCVD_IN_PBL, RDNS_DYNAMIC, TW_MK, USER_IN_WHITELIST, USER_IN_WHITELIST_TO autolearn=no version=3.3.0 X-Spam-Checker-Version: SpamAssassin 3.3.0 (2010-01-18) on uitsmijter.van-laarhoven.org X-OriginalArrivalTime: 08 Sep 2010 07:51:14.0195 (UTC) FILETIME=[9C6F4630:01CB4F2A] X-RcptDomain: freebsd.org Cc: freebsd-usb@freebsd.org Subject: Re: USB serial device naming X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Sep 2010 07:51:17 -0000 >> Two things are needed: >>=20 >> 1) path to the device so you can distinguish two identical devices. >>=20 >> 2) map u3gN to cuaUX.Y >>=20 >> My problem is the latter: >>=20 >> Processing event '+u3g0 vendor=3D0x0af0 product=3D0x7601 = devclass=3D0xff >> devsubclass=3D0xff sernum=3D"" release=3D0x0000 intclass=3D0xff = intsubclass=3D0xff >> at port=3D2 interface=3D0 vendor=3D0x0af0 product=3D0x7601 = devclass=3D0xff >> devsubclass=3D0xff sernum=3D"" release=3D0x0000 intclass=3D0xff = intsubclass=3D0xff >> on uhub1' Pushing table >=20 > Hi, >=20 >> How do I get to the cuaU10.0 device here? As far as I can see there = is no >> way to do this. >=20 > I think we should use the following format: >=20 > cuaU..[.] >=20 > Then you can match by ugenX.Y unit. Possibly we could add this = information to=20 > the processing event. Yes. We need a mapping from vendor/product/rev -> /dev/ entry and from = location -> /dev/ entry. Adding this cuaU.. string = (not the absence of the sub_unit) to the event would resolve both issues = 1) and 2). /me starts handing out paint and pencils for the bike shed painting to = come... >> The main problem is the strange way the minor number is assigned to = the >> cuaU device. But having the major and minor numbers for the cuaU = device >> per u3g instance would be sufficient. Through a sysctl for example, = or as >> extra information in the attach. >=20 > You mean in the device name, not in the inode? Device name, right. The mknod stuff is too old to be wrong... > Please send a patch for review. Will do in the next two weeks. Nick=