Correct pa argument type for pmap_kenter_attr()

Physical addresses are vm_paddr_t, not vm_offset_t.  This can make a difference
when sizeof(vm_offset_t) != sizeof(vm_paddr_t).
This commit is contained in:
Justin Hibbits 2017-05-16 03:31:49 +00:00
parent 611e4bb2eb
commit 611aec2545
3 changed files with 4 additions and 3 deletions

View File

@ -251,7 +251,7 @@ extern struct pmap kernel_pmap_store;
void pmap_bootstrap(vm_offset_t, vm_offset_t); void pmap_bootstrap(vm_offset_t, vm_offset_t);
void pmap_kenter(vm_offset_t va, vm_paddr_t pa); void pmap_kenter(vm_offset_t va, vm_paddr_t pa);
void pmap_kenter_attr(vm_offset_t va, vm_offset_t pa, vm_memattr_t); void pmap_kenter_attr(vm_offset_t va, vm_paddr_t pa, vm_memattr_t);
void pmap_kremove(vm_offset_t); void pmap_kremove(vm_offset_t);
void *pmap_mapdev(vm_paddr_t, vm_size_t); void *pmap_mapdev(vm_paddr_t, vm_size_t);
void *pmap_mapdev_attr(vm_paddr_t, vm_size_t, vm_memattr_t); void *pmap_mapdev_attr(vm_paddr_t, vm_size_t, vm_memattr_t);

View File

@ -105,8 +105,9 @@ bs_gen_map(bus_addr_t addr, bus_size_t size, int flags,
void void
bs_remap_earlyboot(void) bs_remap_earlyboot(void)
{ {
vm_paddr_t pa, spa;
vm_offset_t va;
int i; int i;
vm_offset_t pa, spa, va;
vm_memattr_t ma; vm_memattr_t ma;
for (i = 0; i < earlyboot_map_idx; i++) { for (i = 0; i < earlyboot_map_idx; i++) {

View File

@ -495,7 +495,7 @@ pmap_kenter(vm_offset_t va, vm_paddr_t pa)
} }
void void
pmap_kenter_attr(vm_offset_t va, vm_offset_t pa, vm_memattr_t ma) pmap_kenter_attr(vm_offset_t va, vm_paddr_t pa, vm_memattr_t ma)
{ {
CTR4(KTR_PMAP, "%s(%#x, %#x, %#x)", __func__, va, pa, ma); CTR4(KTR_PMAP, "%s(%#x, %#x, %#x)", __func__, va, pa, ma);