schpc_msg.h revision aac517695f87c6b55a5fefa5a14da8c270097ef4
/*
* CDDL HEADER START
*
* 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
* 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 2005 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _SYS_SCHPC_MSG_H
#define _SYS_SCHPC_MSG_H
/*
* This header file describes the messages that are sent between the
* schpc Hot Plug Controller Driver running on the domain and the System
* Controller.
*/
#ifdef __cplusplus
extern "C" {
#endif
/*
* Format of the Get Slot Status specific part of
* PCI Hot Plug message.
*/
typedef struct {
reserved :2;
/*
* Format of the Set Slot Status specific part of
* PCI Hot Plug message.
*/
typedef struct {
reserved :4;
/*
* Format of the Slot Event specific part of
* the PCI Hot Plug message.
*/
typedef struct {
/* inserted or removed */
reserved :10;
/*
* PCI Hot Plug message
*/
typedef struct {
union {
} pcimsg_type;
} pcimsg_t;
/*
* Keys for the outgoing and incoming mailboxes
*/
/*
* default timeout in seconds for mboxsc_getmsg calls
*/
#define PCSC_TIMEOUT 30
/* Commands */
#define PCIMSG_GETSLOTSTATUS 0x1
#define PCIMSG_SETSLOTSTATUS 0x2
#define PCIMSG_SLOTEVENT 0x3
/* Message Revisions */
#define PCIMSG_REVISION 0x10
#define PCIMSG_REVISION_1_0 0x10
/*
* Values for the slot_condition field of the get slot status command.
*/
#define PCIMSG_SLOTCOND_UNKNOWN 0x0
#define PCIMSG_SLOTCOND_GOOD 0x1
#define PCIMSG_SLOTCOND_REC_FAIL 0x2
#define PCIMSG_SLOTCOND_OCC_FAIL 0x3
/*
* Values for the slot_freq_cap and slot_freq_setting fields of the get
* slot status command.
*/
#define PCIMSG_FREQ_33MHZ 0x0
#define PCIMSG_FREQ_66MHZ 0x1
#define PCIMSG_FREQ_90MHZ 0x2
#define PCIMSG_FREQ_133MHZ 0x3
/*
* Values for the slot_mode_cap and slot_mode_setting of the get
* slot status command.
*/
#define PCIMSG_MODE_CONVEN 0x0
#define PCIMSG_MODE_PCIX 0x1
/*
* Values for the PRSNT signals.
*/
#define PCIMSG_PRSNT_NOADAPTER 0x0
#define PCIMSG_PRSNT_25W 0x1
#define PCIMSG_PRSNT_15W 0x2
#define PCIMSG_PRSNT_7_5W 0x3
/*
* Values to turn on and off slot characteristics.
*/
#define PCIMSG_ON 0x1
#define PCIMSG_OFF 0x0
/*
* Values to set the power, service and fault LEDs
*/
#define PCIMSG_LED_OFF 0x00
#define PCIMSG_LED_ON 0x01
#define PCIMSG_LED_FLASH 0x02
/*
* commands.
*/
#define PCIMSG_REPLY_GOOD 0x0
#define PCIMSG_REPLY_FAIL 0x1
#ifdef __cplusplus
}
#endif
#endif /* _SYS_SCHPC_MSG_H */