From owner-freebsd-arch Sat Aug 4 12: 3:25 2001 Delivered-To: freebsd-arch@freebsd.org Received: from scientia.demon.co.uk (scientia.demon.co.uk [212.228.14.13]) by hub.freebsd.org (Postfix) with ESMTP id A803537B401 for ; Sat, 4 Aug 2001 12:03:20 -0700 (PDT) (envelope-from ben@FreeBSD.org) Received: from strontium.shef.vinosystems.com ([192.168.91.36] ident=root) by scientia.demon.co.uk with esmtp (Exim 3.30 #1) id 15T6hi-0007pq-00; Sat, 04 Aug 2001 20:03:18 +0100 Received: (from ben@localhost) by strontium.shef.vinosystems.com (8.11.4/8.11.4) id f74J3IX41536; Sat, 4 Aug 2001 20:03:18 +0100 (BST) (envelope-from ben@FreeBSD.org) X-Authentication-Warning: strontium.shef.vinosystems.com: ben set sender to ben@FreeBSD.org using -f Date: Sat, 4 Aug 2001 20:03:18 +0100 From: Ben Smithurst To: Dima Dorfman Cc: arch@freebsd.org Subject: Re: Library routine to load a kld if it already isn't Message-ID: <20010804200318.D66860@strontium.shef.vinosystems.com> References: <20010804074928.A66860@strontium.shef.vinosystems.com> <20010804133840.067FB3E31@bazooka.unixfreak.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-md5; protocol="application/pgp-signature"; boundary="JYK4vJDZwFMowpUq" Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010804133840.067FB3E31@bazooka.unixfreak.org> X-PGP-Key: http://www.smithurst.org/ben/pgp-key.txt Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --JYK4vJDZwFMowpUq Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Dima Dorfman wrote: > Adding error possibilities is a change in the interface, and shouldn't > done lightly. Nonetheless, I agree with your idea in general, > although the text you propose is inaccurate. It doesn't use > modfind(2), it uses kldnext(2), kldfirstmod(2), modfnext(2), > modstat(2), and kldload(2). Of all of those, only kldstat(2) should > fail. Sorry, I meant modstat(), not modfind() -- I listed just those two functions since they're the only ones a failure of will result in the code returning -1 as far as I can see. --=20 Ben Smithurst / ben@FreeBSD.org FreeBSD: The Power To Serve http://www.FreeBSD.org/ --JYK4vJDZwFMowpUq Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (FreeBSD) Comment: For info see http://www.gnupg.org iD8DBQE7bEb0bPzJ+yzvRCwRAihDAJ4zQM+YUL7o8b5ZQFgL2V81LI89NgCghBLQ tz7jnfwIDVg2CVeioxE8RYw= =tLG7 -----END PGP SIGNATURE----- --JYK4vJDZwFMowpUq-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message