From 9640c4dba6b4a8f5e01b2b67fc47a836818bc38d Mon Sep 17 00:00:00 2001 From: Samuel Thibault Date: Wed, 23 Jul 2008 23:38:52 +0000 Subject: 2008-07-23 Barry deFreese * i386/i386/locore.h (copyinmsg, copyoutmsg): Make parameters const void* and void* instead of vm_offset_t. * i386/i386at/com.c (comportdeath): Cast port as ipc_port_t in tty_portdeath call. * i386/i386at/kd.c (kdportdeath): Likewise. * i386/i386at/lpr.c (lprportdeath): Likewise. * i386/i386at/kd_mouse.c (mouse_handle_byte): Cast param to wakeup() as vm_offset_t. * i386/intel/pmap.c (pmap_destroy): Cast arg 2 of kmem_free() to vm_offset_t. * i386/intel/pmap.h: Cast all arg 1 params to kvtophy() to vm_offset_t. * ipc/ipc_kmsg.c: Remove casts from params to copyinmsg and copyoutmsg calls. * ipc/mach_msg.c: Likewise. * kern/exceptions.c: Likewise. * ipc/mach_msg.c: Remove casts from params to copyout calls. * ipc/bootstrap.c: Likewise. * kern/ipc_tt.c (mach_ports_register): Cast memory[i] as ipc_port_t in assignment. --- i386/intel/pmap.c | 2 +- i386/intel/pmap.h | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'i386/intel') diff --git a/i386/intel/pmap.c b/i386/intel/pmap.c index 539e3f0..b08252e 100644 --- a/i386/intel/pmap.c +++ b/i386/intel/pmap.c @@ -927,7 +927,7 @@ void pmap_destroy(p) vm_object_unlock(pmap_object); } } - kmem_free(kernel_map, p->dirbase, INTEL_PGBYTES); + kmem_free(kernel_map, (vm_offset_t)p->dirbase, INTEL_PGBYTES); zfree(pmap_zone, (vm_offset_t) p); } diff --git a/i386/intel/pmap.h b/i386/intel/pmap.h index b16d984..c1d741b 100644 --- a/i386/intel/pmap.h +++ b/i386/intel/pmap.h @@ -234,7 +234,7 @@ pt_entry_t *pmap_pte(pmap_t pmap, vm_offset_t addr); /* \ * If this is the kernel pmap, switch to its page tables. \ */ \ - set_dirbase(kvtophys(tpmap->dirbase)); \ + set_dirbase(kvtophys((vm_offset_t)tpmap->dirbase)); \ } \ else { \ /* \ @@ -252,7 +252,7 @@ pt_entry_t *pmap_pte(pmap_t pmap, vm_offset_t addr); * No need to invalidate the TLB - the entire user pmap \ * will be invalidated by reloading dirbase. \ */ \ - set_dirbase(kvtophys(tpmap->dirbase)); \ + set_dirbase(kvtophys((vm_offset_t)tpmap->dirbase)); \ \ /* \ * Mark that this cpu is using the pmap. \ @@ -341,7 +341,7 @@ pt_entry_t *pmap_pte(pmap_t pmap, vm_offset_t addr); #define PMAP_ACTIVATE_USER(pmap, th, my_cpu) { \ register pmap_t tpmap = (pmap); \ \ - set_dirbase(kvtophys(tpmap->dirbase)); \ + set_dirbase(kvtophys((vm_offset_t)tpmap->dirbase)); \ if (tpmap != kernel_pmap) { \ tpmap->cpus_using = TRUE; \ } \ -- cgit v1.2.3