PATH 
ADC Home > Documentation > Hardware > Device Managers and Drivers > PCI Card Services > Designing PCI Cards and Drivers for Power Macintosh Computers


  

Mapping Tables

The logical and physical mapping tables are where PrepareMemoryForIO returns the addresses the driver can use to access the client's buffer. The first entry of a range's mappings will be the exact mapping of the first prepared address in that range, regardless of page alignment, while the remaining entries will be page aligned. If multiple address ranges were specified, the mapping table is a concatenation, in order, of the mappings for each range.

There are no explicit length fields in the mapping tables. Instead, entry lengths are implied by the entry's position in the range's mappings, the overall range length, and the page size. The length of the first entry generally runs to the next page alignment, the length of the intermediate entries (if any) is the page size, and the length of the last element in the range is what remains by subtracting the previous lengths from the overall range length. If the prepared range fits within a single page, there is only one prepared entry and its length is equal to the range length.


© 1999 Apple Computer, Inc. – (Last Updated 26 March 99)