xref: /titanic_41/usr/src/man/man9f/scsi_free_consistent_buf.9f (revision e5351341b58845eee9d722bd71543d5a7c26b6cc)
te
Copyright (c) 2006, Sun Microsystems, Inc.,
All Rights Reserved
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]
SCSI_FREE_CONSISTENT_BUF 9F "Jan 16, 2006"
NAME
scsi_free_consistent_buf - free a previously allocated SCSI DMA I/O buffer
SYNOPSIS

#include <sys/scsi/scsi.h>



void scsi_free_consistent_buf(struct buf *bp);
INTERFACE LEVEL

Solaris DDI specific (Solaris DDI).

PARAMETERS
bp

Pointer to the buf(9S) structure.

DESCRIPTION

The scsi_free_consistent_buf() function frees a buffer header and consistent data buffer that was previously allocated using scsi_alloc_consistent_buf(9F).

CONTEXT

The scsi_free_consistent_buf() function can be called from user, interrupt, or kernel context.

SEE ALSO

freerbuf(9F), scsi_alloc_consistent_buf(9F), buf(9S)

Writing Device Drivers

WARNING

The scsi_free_consistent_buf() function will call freerbuf(9F) to free the buf(9S) that was allocated before or during the call to scsi_alloc_consistent_buf(9F).

If consistent memory is bound to a scsi_pkt(9S), the pkt should be destroyed before freeing the consistent memory.