'\" te .\" Copyright (c) 1992, Sun Microsystems, Inc. All Rights Reserved. .\" Copyright 1989 AT&T .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License. .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License. .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner] .TH BP_MAPIN 9F "Sep 13, 1992" .SH NAME bp_mapin \- allocate virtual address space .SH SYNOPSIS .LP .nf #include <sys/types.h> #include <sys/buf.h> \fBvoid\fR \fBbp_mapin\fR(\fBstruct buf *\fR\fIbp\fR); .fi .SH INTERFACE LEVEL .sp .LP Architecture independent level 1 (DDI/DKI). .SH PARAMETERS .sp .ne 2 .na \fB\fIbp\fR \fR .ad .RS 7n Pointer to the buffer header structure. .RE .SH DESCRIPTION .sp .LP \fBbp_mapin()\fR is used to map virtual address space to a page list maintained by the buffer header during a paged- \fBI/O \fRrequest. \fBbp_mapin()\fR allocates system virtual address space, maps that space to the page list, and returns the starting address of the space in the \fBbp->b_un.b_addr\fR field of the \fBbuf\fR(9S) structure. Virtual address space is then deallocated using the \fBbp_mapout\fR(9F) function. .sp .LP If a null page list is encountered, \fBbp_mapin()\fR returns without allocating space and no mapping is performed. .SH CONTEXT .sp .LP \fBbp_mapin()\fR can be called from user and kernel contexts. .SH SEE ALSO .sp .LP \fBbp_mapout\fR(9F), \fBbuf\fR(9S) .sp .LP \fIWriting Device Drivers\fR