Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 14 Jul 1997 08:14:04 +0200 (MET DST)
From:      Luigi Rizzo <luigi@labinfo.iet.unipi.it>
To:        rhh@ct.picker.com (Randall Hopper)
Cc:        hasty@rah.star-gate.com, multimedia@FreeBSD.ORG
Subject:   Re: guspnp9 feedback
Message-ID:  <199707140614.IAA10040@labinfo.iet.unipi.it>
In-Reply-To: <19970713163210.43120@ct.picker.com> from "Randall Hopper" at Jul 13, 97 04:31:51 pm

next in thread | previous in thread | raw e-mail | index | archive | help
> As I said, it's not just the return type.
> 
> < long attach_awe_obsolete(long mem_start, struct address_info *hw_config);
> > void attach_awe_obsolete(struct address_info *hw_config);

I have removed mem_start since the parameter was useless (just passed
across functions) in all drivers I had seen, and only served to
clutter the code. I did not touch the awe driver since I wanted to
talk to Randall first (and did not expect so much activity during
this weekend, which I have spent on the beach playing with my son
instead :)

The intent is to remove mem_start from all attach routines. All
relevent info can be supplied through hw_config if needed (perhaps
we need to add some field to the structure, but the interface would
not change). The return type of the attach routine has been set
(temporarily ?) to void since in the drivers I had seen attach()
could never fail, nor it was generally tested for failute.

I do not think it is a particularly good idea to have attach()
return void, but since there was no error checking anyways, I did
it as a first cut.

In the probe/attach sequence I notice that some drivers do call the
probe() routine again in the attach(). This seems pointless since there
should be no attach if the previous probe failed.

Also, the probe code can probably benefit from the addition of proper
support for PnP boards, since these boards identify clearly themselves
in the PnP id and do not require black magic in the probe routine.

	Cheers
	Luigi
-----------------------------+--------------------------------------
Luigi Rizzo                  |  Dip. di Ingegneria dell'Informazione
email: luigi@iet.unipi.it    |  Universita' di Pisa
tel: +39-50-568533           |  via Diotisalvi 2, 56126 PISA (Italy)
fax: +39-50-568522           |  http://www.iet.unipi.it/~luigi/
_____________________________|______________________________________



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