diff options
author | benno <benno@FreeBSD.org> | 2003-01-30 11:28:29 +0000 |
---|---|---|
committer | benno <benno@FreeBSD.org> | 2003-01-30 11:28:29 +0000 |
commit | cd92290e8c2bc2039d8a1a472e4d42887f371374 (patch) | |
tree | 7b695d7b8ce12002a7349ccc8f1ac49d380ada3f /sys/powerpc/include/bus.h | |
parent | 63f9ad87909a7752f8eef1f5749481d4a4c6d174 (diff) | |
download | FreeBSD-src-cd92290e8c2bc2039d8a1a472e4d42887f371374.zip FreeBSD-src-cd92290e8c2bc2039d8a1a472e4d42887f371374.tar.gz |
Rework of how memory resources are discovered and dealt with in macio.
- Store the OpenFirmware "reg" property in the macio ivars.
- Use a struct to define the structure of a "reg" property entry.
- Discover all memory ranges, not just the first.
- In ata_macio, manage our own range and hand out our own allocations using
bus_space_subregion.
- Fix bus_space_subregion to handle subregions of sparse maps.
Diffstat (limited to 'sys/powerpc/include/bus.h')
-rw-r--r-- | sys/powerpc/include/bus.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/powerpc/include/bus.h b/sys/powerpc/include/bus.h index 5b8f9b3..79e367a 100644 --- a/sys/powerpc/include/bus.h +++ b/sys/powerpc/include/bus.h @@ -148,9 +148,9 @@ bus_space_map(t, addr, size, flags, bshp) ! not implemented ! * Get a new handle for a subregion of an already-mapped area of bus space. */ -#define bus_space_subregion(t, bsh, offset, size, bshp) \ - ((*(bshp) = (bus_space_handle_t)__ppc_ba(t, bsh, offset)), 0) - +#define bus_space_subregion(t, bsh, offset, size, bshp) \ + ((*(bshp) = (bus_space_handle_t)__ppc_ba( \ + (t & ~PPC_BUS_MEM_MASK), bsh, offset)), 0) /* * int bus_space_alloc(bus_space_tag_t t, bus_addr_t rstart, * bus_addr_t rend, bus_size_t size, bus_size_t align, |