2 .\" Copyright (c) 2006, Sun Microsystems, Inc.,
3 .\" All Rights Reserved
4 .\" 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.
5 .\" 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.
6 .\" 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]
7 .TH SCSI_FREE_CONSISTENT_BUF 9F "Jan 16, 2006"
9 scsi_free_consistent_buf \- free a previously allocated SCSI DMA I/O buffer
13 #include <sys/scsi/scsi.h>
17 \fBvoid\fR \fBscsi_free_consistent_buf\fR(\fBstruct buf *\fR\fIbp\fR);
23 Solaris DDI specific (Solaris DDI).
31 Pointer to the \fBbuf\fR(9S) structure.
37 The \fBscsi_free_consistent_buf()\fR function frees a buffer header and
38 consistent data buffer that was previously allocated using
39 \fBscsi_alloc_consistent_buf\fR(9F).
43 The \fBscsi_free_consistent_buf()\fR function can be called from user,
44 interrupt, or kernel context.
48 \fBfreerbuf\fR(9F), \fBscsi_alloc_consistent_buf\fR(9F), \fBbuf\fR(9S)
51 \fIWriting Device Drivers\fR
55 The \fBscsi_free_consistent_buf()\fR function will call \fBfreerbuf\fR(9F) to
56 free the \fBbuf\fR(9S) that was allocated before or during the call to
57 \fBscsi_alloc_consistent_buf\fR(9F).
60 If consistent memory is bound to a \fBscsi_pkt\fR(9S), the pkt should be
61 destroyed before freeing the consistent memory.