*BSD News Article 20749


Return to BSD News archive

Newsgroups: comp.os.386bsd.development
Path: sserve!newshost.anu.edu.au!munnari.oz.au!news.Hawaii.Edu!ames!agate!usenet.ins.cwru.edu!magnus.acs.ohio-state.edu!csn!csn!arrayb!cwolff
From: cwolff@intellistor.com (Clint Wolff)
Subject: Re: [Q] How should config file and device probe relate
Message-ID: <1993Sep6.142326.5769@intellistor.com>
Keywords: probe config drivers
Organization: Intellistor, Longmont, CO
References: <2663rn$3k6@vixen.cso.uiuc.edu>
Date: Mon, 6 Sep 93 14:23:26 GMT
Lines: 57

In article <2663rn$3k6@vixen.cso.uiuc.edu> rkb55989@uxa.cso.uiuc.edu (Rafal Boni) writes:
>	
>	(1) I have an Ethernet board that can be configured without any 
>	knowledge of the board's stored configuration.  Basically, the board
>	has a single IO port fixed at 0x100, in addition to it's bank of 
>	regularly used IO ports, and through this port, one can override the 
>	IObase of the board.  Once the IObase is known, one can override the 
>	memsize, memaddr, and IRQ settings.  
>
>	Which one of the following is the correct behavior for the probe 
>	routine: [or, more accurately, will doing things one way or another
>	break expected behavior?? Will doing things one way break the
>	general idea of how this should work??]
>
>		(a) Initialize the board to use it's stored configuration,
>		and if this configuration does not match that given in the
>		the config file, fail the probe
>
Yes.
>
>		(b) Initialize the board to use the parameters given in the 
>		config file, ignoring all paramters stored in the board's 
>		NVRAM, and thus force the board to fit the config file's 
>		idea of where the board should be
>
No, Unless you can configure the board to go back to its old setup after
a reset. There is nothing in the world more annoying (except MCI telephone
salespeople) than having a software package reconfigure your hardware. When
you are done with that package none of your other software works!!!!

Your best bet is to check for the card at the I/O address given in the
config file, and if it doesn't answer - fail. This also allows multiple
boards to be installed in the system at different I/O addresses.
>
>	
>	(2) How is this handled on 4.4/Sun/other BSD or BSD-ish systems??? 
>	Anyone?
>
They look for hardware at the addresses assigned to them. Real computer
manufactures define the address range for every hardware configuration up
front. 
>
>				Any clues from the likes of Chris D. and 
>				the NetBSD group especially welcome...
>
>							Rafal
The NetBSD group has a clue???? :):):):):):):):) (Sorry, I couldn't resist)

-- 
+-----------------------------------------------------------------------------+
| Clint Wolff                                          Blonde and proud of it |
| Fujitsu Computer Products of America - Intellistor Research and Development |
| cwolff@slowboy.intellistor.com       Ex-hacker... Now System Admininstrator |
+-----------------------------------------------------------------------------+
| Boulder, Colorado.......Where the men shave their legs, and the women don't |
+-----------------------------------------------------------------------------+
			I don't work here anymore