STREAMS-UX Programmer's Guide (February 2007)

STREAMS Utilities Supported by HP-UX
Appendix B
235
NAME
vtop ()Convert virtual address to physical address.
SYNOPSIS
#include <sys/stream.h>
paddr_t vtop(caddr_t vaddr, proc_t *p);
PARAMETERS
vaddr
Virtual address to convert.
p
Pointer to the process structure used. To indicate that the address is in kernel virtual space,
p must be set to NULL.
DESCRIPTION
vtop() converts a virtual address to a physical address.
RETURN VALUES
On success, vtop() returns the physical address. Otherwise, if no physical memory is mapped to the virtual
address or the pointer to the proc_t is not NULL, vtop() returns 0.
CONSTRAINTS
vtop() can be called from thread or interrupt context. Spinlocks can be held across this call.