Subject: Re: Updated 98265A and MI SCSI driver (Re: 98658 SCSI adaptor and MISCSI)
To: None <port-hp300@netbsd.org>
From: Izumi Tsutsui <tsutsui@ceres.dti.ne.jp>
List: port-hp300
Date: 07/06/2003 13:38:05
[well, I posted a patch here but it's so large and seems caught by filter..]
In article <030701083648.M0116880@mirage.ceres.dti.ne.jp>
I wrote:
> In article <HHB23s.vM@tac.nyc.ny.us>
> christos@zoulas.com wrote:
>
> > I think we should have methods for the sparse address space, and
> > not commit the MI driver in the MD directory.
>
> Okay, I'll consider how to implement the methods on hp300.
I've written some code to support the methods:
http://www.ceres.dti.ne.jp/~tsutsui/netbsd/hp300-MI-SCSI-20030705.diff
- Introduce "struct bus_space_tag" in bus.h, which contains bustype and
pointers all bus_space access functions.
- Each bus_space function (defined in bus.h) now checks
the corresponding function pointer first and calls it if it's valid,
otherwise uses the conventional methods.
- Drivers which require special access methods have to copy bus_space_tag
and override necessary functions in their attachments.
"to copy and modify bus_space_tag in each driver" seems a bit ugly,
but it's the way used on other ports..
---
Izumi Tsutsui
tsutsui@ceres.dti.ne.jp