powerpc: Fix bus_space_unmap
Previously it failed to compile since the macro passed too many arguments to the function. Fix by adding the bus handle to the function and adding an implementation that calls pmap_unmapdev. Reviewed by: jhibbits Differential Revision: https://reviews.freebsd.org/D43440
This commit is contained in:
@@ -103,7 +103,7 @@ struct bus_space {
|
||||
/* mapping/unmapping */
|
||||
int (*bs_map)(bus_addr_t, bus_size_t, int,
|
||||
bus_space_handle_t *);
|
||||
void (*bs_unmap)(bus_size_t);
|
||||
void (*bs_unmap)(bus_space_handle_t, bus_size_t);
|
||||
int (*bs_subregion)(bus_space_handle_t, bus_size_t,
|
||||
bus_size_t, bus_space_handle_t *);
|
||||
|
||||
|
||||
@@ -140,8 +140,13 @@ bs_remap_earlyboot(void)
|
||||
}
|
||||
|
||||
static void
|
||||
bs_gen_unmap(bus_size_t size __unused)
|
||||
bs_gen_unmap(bus_space_handle_t bsh, bus_size_t size)
|
||||
{
|
||||
|
||||
if (!pmap_bootstrapped)
|
||||
return;
|
||||
|
||||
pmap_unmapdev((void *)bsh, size);
|
||||
}
|
||||
|
||||
static int
|
||||
|
||||
Reference in New Issue
Block a user