From owner-freebsd-arch@FreeBSD.ORG Wed Dec 21 05:55:44 2005 Return-Path: X-Original-To: arch@freebsd.org Delivered-To: freebsd-arch@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 39FE416A41F for ; Wed, 21 Dec 2005 05:55:44 +0000 (GMT) (envelope-from sam@errno.com) Received: from ebb.errno.com (ebb.errno.com [69.12.149.25]) by mx1.FreeBSD.org (Postfix) with ESMTP id DFBAB43D62 for ; Wed, 21 Dec 2005 05:55:43 +0000 (GMT) (envelope-from sam@errno.com) Received: from [10.0.0.199] ([10.0.0.199]) (authenticated bits=0) by ebb.errno.com (8.12.9/8.12.6) with ESMTP id jBL5tgiE020111 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 20 Dec 2005 21:55:43 -0800 (PST) (envelope-from sam@errno.com) Message-ID: <43A8EE23.3010202@errno.com> Date: Tue, 20 Dec 2005 21:54:43 -0800 From: Sam Leffler Organization: Errno Consulting User-Agent: Mozilla Thunderbird 1.0.7 (Macintosh/20050923) X-Accept-Language: en-us, en MIME-Version: 1.0 To: arch@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: firmware loading X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Dec 2005 05:55:44 -0000 Florent Thoumie and I have been working on some generic support for loading firmware using kld's. You can find a proof of concept at: http://www.freebsd.org/~sam/firmware.tgz It has code to manage firmware images and load them on demand by requesting a kld through standard facilities. Firmware is packaged using a genfw program that's included. You can package one or more firmware images in a single kld. I've packaged the iwi firmware as a boot image in a single kld + kld's for each operating mode that have two firmware images. The tarball also includes modified versions of the iwi and ipw drivers to use the code. I tested iwi, Florent is working on ipw. If you're interested in this stuff feel free to pick it up; I've run out of time to work on it. There are some potential issues with holding locks over the linker calls and the genfw program could use some TLC and probably a new name (plus the man page needs to be completed). It appears ispfw can be reworked to use this code. iwi and ipw definitely can use it. Not sure who else can/should use it. Sam From owner-freebsd-arch@FreeBSD.ORG Wed Dec 21 13:53:04 2005 Return-Path: X-Original-To: freebsd-arch@freebsd.org Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0F4FA16A41F; Wed, 21 Dec 2005 13:53:04 +0000 (GMT) (envelope-from max@love2party.net) Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.183]) by mx1.FreeBSD.org (Postfix) with ESMTP id 76C7C43D6E; Wed, 21 Dec 2005 13:53:02 +0000 (GMT) (envelope-from max@love2party.net) Received: from [84.163.236.214] (helo=amd64.laiers.local) by mrelayeu.kundenserver.de (node=mrelayeu4) with ESMTP (Nemesis), id 0ML21M-1Ep4Oj1Gdm-00056M; Wed, 21 Dec 2005 14:52:56 +0100 From: Max Laier Organization: FreeBSD To: freebsd-arch@freebsd.org Date: Wed, 21 Dec 2005 14:52:57 +0100 User-Agent: KMail/1.8.3 References: <43A8EE23.3010202@errno.com> In-Reply-To: <43A8EE23.3010202@errno.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart5592769.eAg4r3ncfo"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <200512211453.03946.max@love2party.net> X-Provags-ID: kundenserver.de abuse@kundenserver.de login:61c499deaeeba3ba5be80f48ecc83056 Cc: Damien Bergamini , flz@freebsd.org Subject: Re: firmware loading X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Dec 2005 13:53:04 -0000 --nextPart5592769.eAg4r3ncfo Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Wednesday 21 December 2005 06:54, Sam Leffler wrote: > Florent Thoumie and I have been working on some generic support for > loading firmware using kld's. You can find a proof of concept at: > > http://www.freebsd.org/~sam/firmware.tgz > > It has code to manage firmware images and load them on demand by > requesting a kld through standard facilities. Firmware is packaged > using a genfw program that's included. You can package one or more > firmware images in a single kld. I've packaged the iwi firmware as a > boot image in a single kld + kld's for each operating mode that have two > firmware images. The tarball also includes modified versions of the iwi > and ipw drivers to use the code. I tested iwi, Florent is working on ipw. > > If you're interested in this stuff feel free to pick it up; I've run out > of time to work on it. There are some potential issues with holding > locks over the linker calls and the genfw program could use some TLC and > probably a new name (plus the man page needs to be completed). I am generally interested and will probably look at it between Christmas an= d=20 the New Year - unless Damien wants to look at it himself. The current sche= me=20 of loading the firmware is disfunctional with a WITNESS enabled kernel (too= =20 much "sleep while holding mutex") and needs to be fixed anyway. Is this work in perforce? Is Florent still actively working on it? > It appears ispfw can be reworked to use this code. iwi and ipw > definitely can use it. Not sure who else can/should use it. =2D-=20 /"\ Best regards, | mlaier@freebsd.org \ / Max Laier | ICQ #67774661 X http://pf4freebsd.love2party.net/ | mlaier@EFnet / \ ASCII Ribbon Campaign | Against HTML Mail and News --nextPart5592769.eAg4r3ncfo Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQBDqV4/XyyEoT62BG0RAjwUAJ4jdTxBdo1x8Uo4nQxpQbycr7Sz7QCeOUoz AEhd1ssViHsxpbZ1LeEGEu4= =1vkc -----END PGP SIGNATURE----- --nextPart5592769.eAg4r3ncfo-- From owner-freebsd-arch@FreeBSD.ORG Wed Dec 21 14:01:38 2005 Return-Path: X-Original-To: freebsd-arch@freebsd.org Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 35DF216A41F; Wed, 21 Dec 2005 14:01:38 +0000 (GMT) (envelope-from flz@xbsd.org) Received: from smtp.xbsd.org (xbsd.org [82.233.2.192]) by mx1.FreeBSD.org (Postfix) with ESMTP id EBC1943D5A; Wed, 21 Dec 2005 14:01:36 +0000 (GMT) (envelope-from flz@xbsd.org) Received: from localhost (localhost.xbsd.org [127.0.0.1]) by smtp.xbsd.org (Postfix) with ESMTP id 13E301165E; Wed, 21 Dec 2005 15:01:36 +0100 (CET) Received: from smtp.xbsd.org ([127.0.0.1]) by localhost (srv1.xbsd.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 51371-09; Wed, 21 Dec 2005 15:01:28 +0100 (CET) Received: from cream.xbsd.org (cream.xbsd.org [192.168.42.6]) by smtp.xbsd.org (Postfix) with ESMTP id C2A0011628; Wed, 21 Dec 2005 15:01:27 +0100 (CET) From: Florent Thoumie To: freebsd-arch@freebsd.org Date: Wed, 21 Dec 2005 15:01:11 +0100 User-Agent: KMail/1.8.2 References: <43A8EE23.3010202@errno.com> <200512211453.03946.max@love2party.net> In-Reply-To: <200512211453.03946.max@love2party.net> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart1850579.GtnsyeTMZR"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <200512211501.22621.flz@xbsd.org> X-Virus-Scanned: amavisd-new at xbsd.org Cc: Max Laier , Damien Bergamini , flz@freebsd.org Subject: Re: firmware loading X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Dec 2005 14:01:38 -0000 --nextPart1850579.GtnsyeTMZR Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Wednesday 21 December 2005 14:52, Max Laier wrote: > On Wednesday 21 December 2005 06:54, Sam Leffler wrote: > > Florent Thoumie and I have been working on some generic support for > > loading firmware using kld's. You can find a proof of concept at: > > > > http://www.freebsd.org/~sam/firmware.tgz > > > > It has code to manage firmware images and load them on demand by > > requesting a kld through standard facilities. Firmware is packaged > > using a genfw program that's included. You can package one or more > > firmware images in a single kld. I've packaged the iwi firmware as a > > boot image in a single kld + kld's for each operating mode that have two > > firmware images. The tarball also includes modified versions of the iwi > > and ipw drivers to use the code. I tested iwi, Florent is working on > > ipw. > > > > If you're interested in this stuff feel free to pick it up; I've run out > > of time to work on it. There are some potential issues with holding > > locks over the linker calls and the genfw program could use some TLC and > > probably a new name (plus the man page needs to be completed). > > I am generally interested and will probably look at it between Christmas > and the New Year - unless Damien wants to look at it himself. The current > scheme of loading the firmware is disfunctional with a WITNESS enabled > kernel (too much "sleep while holding mutex") and needs to be fixed anywa= y. > > Is this work in perforce? Is Florent still actively working on it? I'm actively trying to get familiar with src/sys, which takes most of my=20 time. I won't be able to fix anything in a while though. I've been testing Sam's changes (since he has no ipw(4) hardware) and I've create new ipw/iwi-firmware ports that you will find in [1]. [1] http://people.freebsd.org/~flz/firmware/ =2D-=20 =46lorent Thoumie flz@FreeBSD.org =46reeBSD Committer --nextPart1850579.GtnsyeTMZR Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQBDqWAyMxEkbVFH3PQRAh5gAKCC6V2Wf/HZVh12F8IForZilgO9wACeKJkv wl3HoWGjDEk4tlJ79Ag90Vo= =1LJh -----END PGP SIGNATURE----- --nextPart1850579.GtnsyeTMZR-- From owner-freebsd-arch@FreeBSD.ORG Wed Dec 21 16:18:14 2005 Return-Path: X-Original-To: arch@freebsd.org Delivered-To: freebsd-arch@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DB4AA16A41F for ; Wed, 21 Dec 2005 16:18:14 +0000 (GMT) (envelope-from phk@critter.freebsd.dk) Received: from phk.freebsd.dk (phk.freebsd.dk [130.225.244.222]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6D16843D4C for ; Wed, 21 Dec 2005 16:18:14 +0000 (GMT) (envelope-from phk@critter.freebsd.dk) Received: from critter.freebsd.dk (unknown [192.168.48.2]) by phk.freebsd.dk (Postfix) with ESMTP id 56FD7BC84; Wed, 21 Dec 2005 16:18:11 +0000 (UTC) To: Sam Leffler From: "Poul-Henning Kamp" In-Reply-To: Your message of "Tue, 20 Dec 2005 21:54:43 PST." <43A8EE23.3010202@errno.com> Date: Wed, 21 Dec 2005 17:18:11 +0100 Message-ID: <15635.1135181891@critter.freebsd.dk> Sender: phk@critter.freebsd.dk Cc: arch@freebsd.org Subject: Re: firmware loading X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Dec 2005 16:18:15 -0000 In message <43A8EE23.3010202@errno.com>, Sam Leffler writes: >Florent Thoumie and I have been working on some generic support for >loading firmware using kld's. You can find a proof of concept at: > >http://www.freebsd.org/~sam/firmware.tgz > >It has code to manage firmware images and load them on demand by >requesting a kld through standard facilities. Is the firmware kld unloaded again when no longer in use, or does it stay in KVM once as long as the driver is active ? -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. From owner-freebsd-arch@FreeBSD.ORG Wed Dec 21 16:33:56 2005 Return-Path: X-Original-To: arch@freebsd.org Delivered-To: freebsd-arch@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CCE8A16A41F for ; Wed, 21 Dec 2005 16:33:56 +0000 (GMT) (envelope-from scottl@samsco.org) Received: from pooker.samsco.org (pooker.samsco.org [168.103.85.57]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7EEEB43D62 for ; Wed, 21 Dec 2005 16:33:44 +0000 (GMT) (envelope-from scottl@samsco.org) Received: from [192.168.254.14] (imini.samsco.home [192.168.254.14]) (authenticated bits=0) by pooker.samsco.org (8.13.4/8.13.4) with ESMTP id jBLGWJrm062652; Wed, 21 Dec 2005 09:32:20 -0700 (MST) (envelope-from scottl@samsco.org) Message-ID: <43A98393.5030502@samsco.org> Date: Wed, 21 Dec 2005 09:32:19 -0700 From: Scott Long User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.7.7) Gecko/20050416 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Poul-Henning Kamp References: <15635.1135181891@critter.freebsd.dk> In-Reply-To: <15635.1135181891@critter.freebsd.dk> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.4 required=3.8 tests=ALL_TRUSTED autolearn=failed version=3.1.0 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on pooker.samsco.org Cc: arch@freebsd.org Subject: Re: firmware loading X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Dec 2005 16:33:56 -0000 Poul-Henning Kamp wrote: > In message <43A8EE23.3010202@errno.com>, Sam Leffler writes: > >>Florent Thoumie and I have been working on some generic support for >>loading firmware using kld's. You can find a proof of concept at: >> >>http://www.freebsd.org/~sam/firmware.tgz >> >>It has code to manage firmware images and load them on demand by >>requesting a kld through standard facilities. > > > Is the firmware kld unloaded again when no longer in use, or does it > stay in KVM once as long as the driver is active ? > Right now it stays resident. My understanding is that the wireless cards that this was designed for need to reload their firmware after resume. We don't have any hooks to tell drivers when the filesystem is ready, so the only non-hackish solution right now is to just keep it resident. I agree that this isn't ideal, and I would think that it would be pretty trivial to add an event handler hook to solve this. The other thing that I'm not sure about is whether this being a module dependency will prevent it from being unloaded. I'm not sure how ispfw.ko handles this. Scott From owner-freebsd-arch@FreeBSD.ORG Wed Dec 21 17:12:31 2005 Return-Path: X-Original-To: freebsd-arch@freebsd.org Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 98FFC16A41F; Wed, 21 Dec 2005 17:12:31 +0000 (GMT) (envelope-from sam@errno.com) Received: from ebb.errno.com (ebb.errno.com [69.12.149.25]) by mx1.FreeBSD.org (Postfix) with ESMTP id 34DA843D55; Wed, 21 Dec 2005 17:12:31 +0000 (GMT) (envelope-from sam@errno.com) Received: from [10.0.0.198] ([10.0.0.198]) (authenticated bits=0) by ebb.errno.com (8.12.9/8.12.6) with ESMTP id jBLHCRiE023576 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 21 Dec 2005 09:12:30 -0800 (PST) (envelope-from sam@errno.com) Message-ID: <43A98D3E.6080701@errno.com> Date: Wed, 21 Dec 2005 09:13:34 -0800 From: Sam Leffler User-Agent: Mozilla Thunderbird 1.0.7 (X11/20051207) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Max Laier References: <43A8EE23.3010202@errno.com> <200512211453.03946.max@love2party.net> In-Reply-To: <200512211453.03946.max@love2party.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Damien Bergamini , flz@freebsd.org, freebsd-arch@freebsd.org Subject: Re: firmware loading X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Dec 2005 17:12:31 -0000 Max Laier wrote: > On Wednesday 21 December 2005 06:54, Sam Leffler wrote: > >>Florent Thoumie and I have been working on some generic support for >>loading firmware using kld's. You can find a proof of concept at: >> >>http://www.freebsd.org/~sam/firmware.tgz >> >>It has code to manage firmware images and load them on demand by >>requesting a kld through standard facilities. Firmware is packaged >>using a genfw program that's included. You can package one or more >>firmware images in a single kld. I've packaged the iwi firmware as a >>boot image in a single kld + kld's for each operating mode that have two >>firmware images. The tarball also includes modified versions of the iwi >>and ipw drivers to use the code. I tested iwi, Florent is working on ipw. >> >>If you're interested in this stuff feel free to pick it up; I've run out >>of time to work on it. There are some potential issues with holding >>locks over the linker calls and the genfw program could use some TLC and >>probably a new name (plus the man page needs to be completed). > > > I am generally interested and will probably look at it between Christmas and > the New Year - unless Damien wants to look at it himself. The current scheme > of loading the firmware is disfunctional with a WITNESS enabled kernel (too > much "sleep while holding mutex") and needs to be fixed anyway. I can't recall if that's the driver's lock being held over linker calls that are potentially blocking, but if you can resolve this then I can also re-enable dynamic loading of 802.11 crypto modules. > > Is this work in perforce? Is Florent still actively working on it? It's not in perforce. Florent has already responded. > > >>It appears ispfw can be reworked to use this code. iwi and ipw >>definitely can use it. Not sure who else can/should use it. > > From owner-freebsd-arch@FreeBSD.ORG Wed Dec 21 17:19:50 2005 Return-Path: X-Original-To: arch@freebsd.org Delivered-To: freebsd-arch@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EDA5C16A41F for ; Wed, 21 Dec 2005 17:19:50 +0000 (GMT) (envelope-from sam@errno.com) Received: from ebb.errno.com (ebb.errno.com [69.12.149.25]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0E11A43D77 for ; Wed, 21 Dec 2005 17:19:39 +0000 (GMT) (envelope-from sam@errno.com) Received: from [10.0.0.198] ([10.0.0.198]) (authenticated bits=0) by ebb.errno.com (8.12.9/8.12.6) with ESMTP id jBLHJZiE023616 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 21 Dec 2005 09:19:36 -0800 (PST) (envelope-from sam@errno.com) Message-ID: <43A98EEA.5070405@errno.com> Date: Wed, 21 Dec 2005 09:20:42 -0800 From: Sam Leffler User-Agent: Mozilla Thunderbird 1.0.7 (X11/20051207) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Scott Long References: <15635.1135181891@critter.freebsd.dk> <43A98393.5030502@samsco.org> In-Reply-To: <43A98393.5030502@samsco.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: arch@freebsd.org, Poul-Henning Kamp Subject: Re: firmware loading X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Dec 2005 17:19:51 -0000 Scott Long wrote: > Poul-Henning Kamp wrote: > >> In message <43A8EE23.3010202@errno.com>, Sam Leffler writes: >> >>> Florent Thoumie and I have been working on some generic support for >>> loading firmware using kld's. You can find a proof of concept at: >>> >>> http://www.freebsd.org/~sam/firmware.tgz >>> >>> It has code to manage firmware images and load them on demand by >>> requesting a kld through standard facilities. >> >> >> >> Is the firmware kld unloaded again when no longer in use, or does it >> stay in KVM once as long as the driver is active ? >> > > Right now it stays resident. My understanding is that the wireless > cards that this was designed for need to reload their firmware after > resume. We don't have any hooks to tell drivers when the filesystem > is ready, so the only non-hackish solution right now is to just keep > it resident. I agree that this isn't ideal, and I would think that it > would be pretty trivial to add an event handler hook to solve this. > The other thing that I'm not sure about is whether this being a module > dependency will prevent it from being unloaded. I'm not sure how > ispfw.ko handles this. Actually, it is unloaded on last reference. This is controlled by the caller (there's a flag to firmware_put that says it's ok to unload). Unloading on last ref is the most tricky part of the code as I wanted to handle multiple firmware images packaged in a single kld and that requires some care to be robust. For now consumers need to be somewhat aware of how multi-image kld's are packaged; they must order their get+put calls to put last on the "master image" in a kld. Using kld's to do this adds a level of indirection (over just reading directly from files) but also has lots of advantages. You can trivially link stuff statically into the kernel. You can pre-load stuff from the loader. You can print copyright notices to the console on load. You can also do things like compress the firmware in the kld. The big win is having a common api that hides the implementation details. In this regard the code needs some cleanup so consumers don't have to include linker.h to get the definition of linker_file_t and so they don't know about implementation details. Sam From owner-freebsd-arch@FreeBSD.ORG Wed Dec 21 18:12:10 2005 Return-Path: X-Original-To: arch@freebsd.org Delivered-To: freebsd-arch@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E229D16A41F for ; Wed, 21 Dec 2005 18:12:10 +0000 (GMT) (envelope-from phk@critter.freebsd.dk) Received: from phk.freebsd.dk (phk.freebsd.dk [130.225.244.222]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8153143D49 for ; Wed, 21 Dec 2005 18:12:10 +0000 (GMT) (envelope-from phk@critter.freebsd.dk) Received: from critter.freebsd.dk (unknown [192.168.48.2]) by phk.freebsd.dk (Postfix) with ESMTP id 7E0B0BC66; Wed, 21 Dec 2005 18:12:05 +0000 (UTC) To: Sam Leffler From: "Poul-Henning Kamp" In-Reply-To: Your message of "Wed, 21 Dec 2005 09:20:42 PST." <43A98EEA.5070405@errno.com> Date: Wed, 21 Dec 2005 19:12:05 +0100 Message-ID: <16137.1135188725@critter.freebsd.dk> Sender: phk@critter.freebsd.dk Cc: arch@freebsd.org Subject: Re: firmware loading X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Dec 2005 18:12:11 -0000 In message <43A98EEA.5070405@errno.com>, Sam Leffler writes: >Actually, it is unloaded on last reference. That works for me. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence.