From owner-freebsd-usb@FreeBSD.ORG Sat Jan 14 10:47:21 2012 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 EEE831065670; Sat, 14 Jan 2012 10:47:21 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe09.c2i.net [212.247.155.2]) by mx1.freebsd.org (Postfix) with ESMTP id 4C7498FC0C; Sat, 14 Jan 2012 10:47:20 +0000 (UTC) X-T2-Spam-Status: No, hits=-0.2 required=5.0 tests=ALL_TRUSTED, BAYES_50 Received: from [188.126.198.129] (account mc467741@c2i.net HELO laptop002.hselasky.homeunix.org) by mailfe09.swip.net (CommuniGate Pro SMTP 5.4.2) with ESMTPA id 53781729; Sat, 14 Jan 2012 11:47:18 +0100 From: Hans Petter Selasky To: Mykhaylo Yehorov Date: Sat, 14 Jan 2012 11:45:05 +0100 User-Agent: KMail/1.13.5 (FreeBSD/8.2-STABLE; KDE/4.4.5; amd64; ; ) References: <201201131705.q0DH5Tko030020@red.freebsd.org> <201201132154.01815.hselasky@c2i.net> In-Reply-To: X-Face: 'mmZ:T{)),Oru^0c+/}w'`gU1$ubmG?lp!=R4Wy\ELYo2)@'UZ24N@d2+AyewRX}mAm; Yp |U[@, _z/([?1bCfM{_"B<.J>mICJCHAzzGHI{y7{%JVz%R~yJHIji`y>Y}k1C4TfysrsUI -%GU9V5]iUZF&nRn9mJ'?&>O MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201201141145.05813.hselasky@c2i.net> Cc: freebsd-gnats-submit@freebsd.org, freebsd-usb@freebsd.org Subject: Re: usb/164090: [umodem] [patch] Add sysctl with ucom unit number 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: Sat, 14 Jan 2012 10:47:22 -0000 On Saturday 14 January 2012 10:51:07 Mykhaylo Yehorov wrote: > On Fri, Jan 13, 2012 at 22:54, Hans Petter Selasky wrote: > > Hi, > > > > Could you patch ucom_set_pnpinfo_usb() instead, so that such a sysctl is > > created for all ucom devices, not only umodem? > > I guess it will be necessary to remove a sysctl oid from a parent > sysctl tree before destroying ucom structures. > It's would be better to do in ucom_detach() but now there is no a > pointer to a parent device structure from there. > > Now all drivers that use ucom pass a pointer to parent softc structure > to ucom_attach(). > Is there any reason for this? > May be it's would be more useful to pass a pointer to a parent device > structure. > > > Can you explain a bit more how you use this information in your scripts? > > I've got a gps receiver and a mobile phone that supported by the umodem > driver. I can attach its in any order. > So I use sysctl to generate gpsd and ppp configs with appropriate > values of serial port. Ok, I see. And you cannot use the information passed through devd by ucom_set_pnpinfo_usb()? --HPS