Subject: Re: bus_space_handle_t and bus_space_tag_t
To: None <current-users@netbsd.org>
From: Matthew Fredette <fredette@MIT.EDU>
List: current-users
Date: 11/06/2001 13:33:21
> >bus_space_tag_t describes the implementation of bus space.
> 
> >bus_space_handle_t describes an individial mapping of bus space.
> 
> So, can a given handle ever be used with more than one tag?  If not, why
> not include a pointer to the relevant tag in the handle?  I may not be
> quite following this yet.
> 
> -s

Keeping them separate is a win on systems where devices are always
mapped into kernel virtual space, like on the sun2.  Then a
bus_space_handle_t is really just a simple pointer, and
bus_space_read_N is just a single dereference.  If a handle were a
pointer to some compound object, bus_space_read_N would have to do two
dereferences.

Matt

--
Matt Fredette
http://mit.edu/fredette/www