tnf_buf.c revision 7c478bd95313f5f23a4c958a745db2134aa03244
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * CDDL HEADER START
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * The contents of this file are subject to the terms of the
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * Common Development and Distribution License, Version 1.0 only
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * (the "License"). You may not use this file except in compliance
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * with the License.
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * See the License for the specific language governing permissions
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * and limitations under the License.
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * When distributing Covered Code, include this CDDL HEADER in each
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * If applicable, add the following below this CDDL HEADER, with the
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * fields enclosed by brackets "[]" replaced with your own identifying
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * information: Portions Copyright [yyyy] [name of copyright owner]
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * CDDL HEADER END
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * Copyright (c) 1994-2000 by Sun Microsystems, Inc.
faaa489e1cc905efd364e01fe09111173c95db68jeff.schenk * All rights reserved.
#include "tnf_buf.h"
static int spinlock_spl;
enum tnf_alloc_mode);
static tnf_block_header_t *
return (NULL);
if (istag)
goto try_reserved;
for (i = 0; i < TNFW_B_MAXALLOCTRY; i++) {
goto update_hint;
goto loop_fail;
return (block);
next++;
goto got_block;
goto try_loop;
#ifdef DEBUG
return (NULL);
void *destp;
if (istag)
return (NULL);
ulong_t *p, *q;
*p++ = TNF_NULL;
return (destp);
return (cell);
int gen_shift;
ulong_t b;
* interface in sys/machlock.h for locking operations.
gen_shift = 0;
while (b < blocks) {
++gen_shift;
for (; i < blocks; ++i) {