diff --git a/sys/kern/subr_devmap.c b/sys/kern/subr_devmap.c --- a/sys/kern/subr_devmap.c +++ b/sys/kern/subr_devmap.c @@ -41,6 +41,8 @@ #include #endif +#define DEVMAP_PADDR_NOTFOUND ((vm_paddr_t)(-1)) + static const struct devmap_entry *devmap_table; static boolean_t devmap_bootstrap_done = false; @@ -198,7 +200,7 @@ * Look up the given physical address in the static mapping data and return the * corresponding virtual address, or NULL if not found. */ -void * +static void * devmap_ptov(vm_paddr_t pa, vm_size_t size) { const struct devmap_entry *pd; @@ -218,7 +220,7 @@ * Look up the given virtual address in the static mapping data and return the * corresponding physical address, or DEVMAP_PADDR_NOTFOUND if not found. */ -vm_paddr_t +static vm_paddr_t devmap_vtop(void * vpva, vm_size_t size) { const struct devmap_entry *pd; diff --git a/sys/sys/devmap.h b/sys/sys/devmap.h --- a/sys/sys/devmap.h +++ b/sys/sys/devmap.h @@ -76,20 +76,6 @@ */ void devmap_bootstrap(void); -/* - * Translate between virtual and physical addresses within a region that is - * static-mapped by the devmap code. If the given address range isn't - * static-mapped, then ptov returns NULL and vtop returns DEVMAP_PADDR_NOTFOUND. - * The latter implies that you can't vtop just the last byte of physical address - * space. This is not as limiting as it might sound, because even if a device - * occupies the end of the physical address space, you're only prevented from - * doing vtop for that single byte. If you vtop a size bigger than 1 it works. - */ -#define DEVMAP_PADDR_NOTFOUND ((vm_paddr_t)(-1)) - -void * devmap_ptov(vm_paddr_t _pa, vm_size_t _sz); -vm_paddr_t devmap_vtop(void * _va, vm_size_t _sz); - /* Print the static mapping table; used for bootverbose output. */ void devmap_print_table(void);