pcp_common.h revision 5db09ef5a5ba16a4728800a9055f47b3f404a2b3
/*
* 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 2005 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _PCP_COMMON_H
#define _PCP_COMMON_H
#pragma ident "%Z%%M% %I% %E% SMI"
#ifdef __cplusplus
extern "C" {
#endif
/*
* This file is shared by both ALOM and Solaris sides of
* Platform Channel Protocol users. So this file should
* include only common shared things.
*/
/*
* Platform Channel Request Message Header.
*/
typedef struct pcp_req_msg_hdr {
/* backward compatibility */
/*
* Platform Channel Response Message Header.
*/
typedef struct pcp_resp_msg_hdr {
/* backward compatibility */
/*
* magic number for Platform Channel Protocol (PCP)
* ~(rot13("PCP_") = 0xAFBCAFA0
* rot13 is a simple Caesar-cypher encryption that replaces each English letter
* with the one 13 places forward or back along the alphabet.
*/
#define PCP_MAGIC_NUM (0xAFBCAFA0)
/* Platform channel protocol versions. */
#define PCP_PROT_VER_1 1
/* Error codes for 'status' field in response message header */
#define PCP_OK (0) /* message received okay */
/* defines for 'timeout' */
#define PCP_TO_WAIT_FOREVER (0) /* wait forever..(in reality, */
/* it waits until glvc driver */
/* call returns; curently glvc */
/* calls are blocking calls. */
#ifdef __cplusplus
}
#endif
#endif /* _PCP_COMMON_H */