/*
* 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 (c) 2001 by Sun Microsystems, Inc.
* All rights reserved.
*/
#ifndef _SYS_LOMBUS_H
#define _SYS_LOMBUS_H
#pragma ident "%Z%%M% %I% %E% SMI"
#ifdef __cplusplus
extern "C" {
#endif
/*
* Information for client (child) drivers:
*
* Register space definitions
* Fault info access
* Fault codes
*
* LOMbus child regspecs are triples, in the form
* <space>, <base>, <size>
*/
typedef struct {
int lombus_space;
int lombus_base;
int lombus_size;
/*
* Register spaces
*
* Space Size Range Meaning
* (bits)
*
* 0 8 [0 .. 16383] LOM virtual registers
* 1 8 [0] Watchdog pat (on write)
* 2 16 [0] Async event info (read only)
* All 32 [-4 .. -12] Access handle fault info
*/
#define LOMBUS_VREG_SPACE (0)
/*
* Internally-generated errors
*
* Note: LOM-generated errors are 0x00-0x7f and SunVTS uses 0x80-0xff,
* so these start at 0x100
*/
enum lombus_errs {
/*
* Errors in the way the child is accessing the virtual registers.
* These are programming errors and won't go away on retry!
*/
/*
* Error accessing the underlying SIO hardware
* This is unlikely to be recoverable.
*/
/*
* Errors in the LOMbus <-> LOM firmware protocol
* These may or may not be recoverable, depending
* on the state of the LOM.
*/
};
/*
* Time periods, in nanoseconds
*/
#ifdef __cplusplus
}
#endif
#endif /* _SYS_LOMBUS_H */