From owner-freebsd-hackers Mon Apr 16 6:42: 4 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from lisa.darkworld.prv (pD9505AB1.dip.t-dialin.net [217.80.90.177]) by hub.freebsd.org (Postfix) with ESMTP id 847EC37B440 for ; Mon, 16 Apr 2001 06:41:59 -0700 (PDT) (envelope-from d_f0rce@gmx.de) Received: from blade (blade.darkworld.prv [10.10.10.2]) by lisa.darkworld.prv (8.11.1/8.11.0) with SMTP id f3GDfxn00667 for ; Mon, 16 Apr 2001 15:42:01 +0200 (CEST) (envelope-from d_f0rce@gmx.de) From: "Alex" To: Subject: Is it ok to compile a device driver as a module though no load_function is declared in DRIVER_MODULE()? Date: Mon, 16 Apr 2001 15:42:34 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0) Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Hi, i've got a little question about device drivers for FreeBSD. I'm testing my device driver by compiling it as a module and kldloading it. But as I don't want to use it as a module in the future I declared DRIVER_MODULE(..) as follows: DRIVER_MODULE( ir, isa, ir_isa_driver, ir_devclass, 0, 0); As I read on deamonnews that one has to declare a load_function to use a driver as a KLD I'm not sure if the above DRIVER_MODULE() is valid for testing. I can see that my identify and probe functions are called but I'm not sure if this can cause troubles if I don't declare a load_function but let the system get the device by identifying and probing it. Can it? If yes, how can I get "dev" to get my softc structure with device_get_softc(dev) within a load function. Sorry for my bad english. Please answer directly to me as I'm not on the list. Greetings, Alex To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message