Re: [RFC] I/O Access Abstractions

Jes Sorensen
2001-06-28T16:03:49Z

>>>>> "David" == David Woodhouse <dwmw2@infradead.org> writes:

David> Having per-resource I/O methods would help us to remove some of
David> the cruft which is accumulating in various non-x86 code. Note
David> that the below is the _core_ routines for _one_ board - I'm not
David> even including the extra indirection through the machine vector
David> here....

Have you considered the method used by the 8390 Ethernet driver?
For each device, add a pointer to the registers and a register shift.

I really don't like hacing virtual access functions that makes memory
mapped I/O look the same as I/O operations. For memory mapped I/O you
want to be able to smart optimizations to reduce the access on the PCI
bus (or similar).

Jes