Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 30 May 2000 12:05:27 -0600
From:      Warner Losh <imp@village.org>
To:        Doug Rabson <dfr@nlsystems.com>
Cc:        Bob Kot <bobkat@azstarnet.com>, freebsd-hackers@FreeBSD.ORG
Subject:   Re: subr_bus.c | kldload | kldunload 
Message-ID:  <200005301805.MAA17843@harmony.village.org>
In-Reply-To: Your message of "Tue, 30 May 2000 08:50:50 BST." <Pine.BSF.4.21.0005300845580.2947-100000@salmon.nlsystems.com> 
References:  <Pine.BSF.4.21.0005300845580.2947-100000@salmon.nlsystems.com>  

next in thread | previous in thread | raw e-mail | index | archive | help
In message <Pine.BSF.4.21.0005300845580.2947-100000@salmon.nlsystems.com> Doug Rabson writes:
: Without seeing the code, it appears that you are creating a new device
: instance each time the module is loaded. Probably you should try to only
: do this the first time (e.g. by looking to see if device msm0
: exists). This part of the interface could use some improvement.

Yes.  I've had to explain very carefully that the instance tree is
different than strucutres used to hold the drivers so it is OK for the 
underlying driver to go away (assuming the usual caveats about
disconnecting interrupts and the like).  This does makeit hard to
debug the identify routine if you are trying to automagically detect
the device, or if you are using the hints mechanism to move the device 
after the first load of the driver.

: > Knowing that my in-experienced approach at getting my msm_probe()
: > and msm_attach() to execute may not be the right way to do things,
: > I will start by just asking for a referral to some other driver 
: > that is implemented as a module with the newbus architecture, that 
: > will kldload / kldunload with no side effects and that preferably is 
: > an ISA device. If no one responds to this request I will repost with
: > actual code and a laundry list of observed symptoms.
: 
: Warner Losh might be able to help you out here.

There is my iopener led driver that might be a good stard.  I'm
writing some articles about this now, but have been so swamped that
I'm not sure when I'll get them done :-(.  You can download the led
driver from:
	http://people.freebsd.org/~imp/led.tar.gz
Please let me know if you have problems with this, or comments on
this.

Warner


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200005301805.MAA17843>