zuluvm.h revision 7c478bd95313f5f23a4c958a745db2134aa03244
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (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
* 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]
*
* CDDL HEADER END
*/
/*
* Copyright 2003 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef __ZULUVM_INCL__
#define __ZULUVM_INCL__
#pragma ident "%Z%%M% %I% %E% SMI"
#ifdef __cplusplus
extern "C" {
#endif
/* zulud interface */
#ifndef _ASM
#include <sys/dditypes.h>
typedef struct {
int tlbtype;
typedef struct {
int version;
int (*dma_suspend_ack)(void *handle);
} zulud_ops_t;
#endif
#define ZULUVM_SUCCESS 0
#define ZULUVM_ERROR 1
#define ZULUVM_NO_TTE 2
#define ZULUVM_INVALID_MISS 3
#define ZULUVM_NO_DEV 4
#define ZULUVM_NO_HAT 5
#define ZULUVM_NO_MAP 6
#define ZULUVM_VERSION_MISMATCH 7
#define ZULUVM_TTE_DELAY 8
#define ZULUVM_MISS_CANCELED 9
#define ZULUVM_BAD_IDX 10
#define ZULUVM_WATCH_POINT 11
#define ZULUVM_NO_SUPPORT 12
#define ZULUVM_CTX_LOCKED 13
#define ZULUVM_ITLB_FLAG 0x1
#define ZULUVM_DMA_FLAG 0x2
#define ZULUVM_DMA_MASK 0x3
#define ZULUVM_DMA1 0
#define ZULUVM_DMA2 ZULUVM_DMA_FLAG
#define ZULUVM_ITLB1 ZULUVM_ITLB_FLAG
#define ZULUVM_INVAL 0x4
#ifndef _ASM
/* zuluvm interface */
typedef void * zuluvm_info_t;
int zuluvm_fini(void);
#endif
#ifdef __cplusplus
}
#endif
#endif /* __ZULUVM_INCL__ */