Date: Fri, 24 Jun 2011 11:21:05 -0600 From: Warner Losh <imp@bsdimp.com> To: Hans Petter Selasky <hselasky@c2i.net> Cc: freebsd-bugs@FreeBSD.org, freebsd-hackers@FreeBSD.org, Robert Millan <rmh@debian.org>, freebsd-current@FreeBSD.org, freebsd-usb@FreeBSD.org, FreeBSD-gnats-submit@FreeBSD.org Subject: Re: misc/157903: automated kldload for USB class devices Message-ID: <A40DE5DA-B710-40A3-88A3-D4A36A0C8E19@bsdimp.com> In-Reply-To: <201106241511.44977.hselasky@c2i.net> References: <201106151523.p5FFN73i075030@red.freebsd.org> <201106241246.51881.hselasky@c2i.net> <BANLkTinvC=j=wsM7EaKTfA3-R8gji_xkEA@mail.gmail.com> <201106241511.44977.hselasky@c2i.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Jun 24, 2011, at 7:11 AM, Hans Petter Selasky wrote: > On Friday 24 June 2011 14:59:37 Robert Millan wrote: >> 2011/6/24 Hans Petter Selasky <hselasky@c2i.net>: >>>> Very nice. But why not use variable names instead of hardcoding >>>> numbers? It makes the output much easier to understand. >>>=20 >>> To save memory. >>=20 >> I haven't inspected devd code, but I was under the assumption that >> variables only lived untill resolved. What would be the point of = keeping >> them in memory after devd has finished parsing the config files? >=20 > Hi, >=20 > I haven't checked that, though if you want the readable version, then = you need=20 > to check the source code. >=20 > However I could add some code to print a vendor ID comment, based on = usbdevs. devd keeps them in memory and expands them when the commands are = executed. It will use more memory and be slower if you have lots of = variables. Now much more memory and how much slower? I kinda doubt = you'd notice on modern gear. Warner
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?A40DE5DA-B710-40A3-88A3-D4A36A0C8E19>