1*fcf3ce44SJohn Forte /*
2*fcf3ce44SJohn Forte  * CDDL HEADER START
3*fcf3ce44SJohn Forte  *
4*fcf3ce44SJohn Forte  * The contents of this file are subject to the terms of the
5*fcf3ce44SJohn Forte  * Common Development and Distribution License (the "License").
6*fcf3ce44SJohn Forte  * You may not use this file except in compliance with the License.
7*fcf3ce44SJohn Forte  *
8*fcf3ce44SJohn Forte  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9*fcf3ce44SJohn Forte  * or http://www.opensolaris.org/os/licensing.
10*fcf3ce44SJohn Forte  * See the License for the specific language governing permissions
11*fcf3ce44SJohn Forte  * and limitations under the License.
12*fcf3ce44SJohn Forte  *
13*fcf3ce44SJohn Forte  * When distributing Covered Code, include this CDDL HEADER in each
14*fcf3ce44SJohn Forte  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15*fcf3ce44SJohn Forte  * If applicable, add the following below this CDDL HEADER, with the
16*fcf3ce44SJohn Forte  * fields enclosed by brackets "[]" replaced with your own identifying
17*fcf3ce44SJohn Forte  * information: Portions Copyright [yyyy] [name of copyright owner]
18*fcf3ce44SJohn Forte  *
19*fcf3ce44SJohn Forte  * CDDL HEADER END
20*fcf3ce44SJohn Forte  */
21*fcf3ce44SJohn Forte /*
22*fcf3ce44SJohn Forte  * Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
23*fcf3ce44SJohn Forte  * Use is subject to license terms.
24*fcf3ce44SJohn Forte  */
25*fcf3ce44SJohn Forte 
26*fcf3ce44SJohn Forte /*
27*fcf3ce44SJohn Forte  * SES State definitions
28*fcf3ce44SJohn Forte  */
29*fcf3ce44SJohn Forte 
30*fcf3ce44SJohn Forte /*
31*fcf3ce44SJohn Forte  * I18N message number ranges
32*fcf3ce44SJohn Forte  *  This file: 16500 - 16999
33*fcf3ce44SJohn Forte  *  Shared common messages: 1 - 1999
34*fcf3ce44SJohn Forte  */
35*fcf3ce44SJohn Forte 
36*fcf3ce44SJohn Forte #ifndef	_A_STATE_H
37*fcf3ce44SJohn Forte #define	_A_STATE_H
38*fcf3ce44SJohn Forte 
39*fcf3ce44SJohn Forte 
40*fcf3ce44SJohn Forte #ifdef	__cplusplus
41*fcf3ce44SJohn Forte extern "C" {
42*fcf3ce44SJohn Forte #endif
43*fcf3ce44SJohn Forte 
44*fcf3ce44SJohn Forte /*
45*fcf3ce44SJohn Forte  * Include any headers you depend on.
46*fcf3ce44SJohn Forte  */
47*fcf3ce44SJohn Forte #include	<sys/fibre-channel/fcio.h>
48*fcf3ce44SJohn Forte #define	_SYS_FC4_FCAL_LINKAPP_H
49*fcf3ce44SJohn Forte #include	<sys/fc4/fcio.h>
50*fcf3ce44SJohn Forte #include <gfc.h>
51*fcf3ce44SJohn Forte #include <g_state.h>
52*fcf3ce44SJohn Forte #include <a5k.h>
53*fcf3ce44SJohn Forte 
54*fcf3ce44SJohn Forte /*
55*fcf3ce44SJohn Forte  * Definitions for send/receive diagnostic command
56*fcf3ce44SJohn Forte  */
57*fcf3ce44SJohn Forte #define	HEADER_LEN		4
58*fcf3ce44SJohn Forte #define	MAX_REC_DIAG_LENGTH	0xfffe
59*fcf3ce44SJohn Forte 
60*fcf3ce44SJohn Forte 
61*fcf3ce44SJohn Forte 
62*fcf3ce44SJohn Forte typedef struct	rec_diag_hdr {
63*fcf3ce44SJohn Forte 	uchar_t		page_code;
64*fcf3ce44SJohn Forte 	uchar_t		sub_enclosures;
65*fcf3ce44SJohn Forte 	ushort_t	page_len;
66*fcf3ce44SJohn Forte } Rec_diag_hdr;
67*fcf3ce44SJohn Forte 
68*fcf3ce44SJohn Forte /* struct for list of gfc_map_t */
69*fcf3ce44SJohn Forte typedef struct gfc_map_mp {
70*fcf3ce44SJohn Forte 	gfc_map_t   map;
71*fcf3ce44SJohn Forte 	struct gfc_map_mp *map_next;
72*fcf3ce44SJohn Forte } gfc_map_mp_t;
73*fcf3ce44SJohn Forte 
74*fcf3ce44SJohn Forte /*
75*fcf3ce44SJohn Forte  * We should use the scsi_capacity structure in impl/commands.h
76*fcf3ce44SJohn Forte  * but it uses u_long's to define 32 bit values.
77*fcf3ce44SJohn Forte  */
78*fcf3ce44SJohn Forte typedef	struct	capacity_data_struct {
79*fcf3ce44SJohn Forte 	uint_t	last_block_addr;
80*fcf3ce44SJohn Forte 	uint_t	block_size;
81*fcf3ce44SJohn Forte } Read_capacity_data;
82*fcf3ce44SJohn Forte 
83*fcf3ce44SJohn Forte /* Function prototypes defined for liba5k modules */
84*fcf3ce44SJohn Forte /* diag.c */
85*fcf3ce44SJohn Forte extern int	l_dev_bypass_enable(struct  path_struct *, int, int,
86*fcf3ce44SJohn Forte 		int, int);
87*fcf3ce44SJohn Forte extern int	l_bp_bypass_enable(char *, int, int, int, int, int);
88*fcf3ce44SJohn Forte extern int	d_p_enable(char *, int);
89*fcf3ce44SJohn Forte extern int	d_p_bypass(char *, int);
90*fcf3ce44SJohn Forte 
91*fcf3ce44SJohn Forte /* lhot.c */
92*fcf3ce44SJohn Forte extern int	is_null_wwn(uchar_t *);
93*fcf3ce44SJohn Forte 
94*fcf3ce44SJohn Forte /* mon.c */
95*fcf3ce44SJohn Forte extern int	l_ex_open_test(struct dlist *, char *, int);
96*fcf3ce44SJohn Forte extern int	l_get_conflict(char *, char **, int);
97*fcf3ce44SJohn Forte extern int	l_new_password(char *, char *);
98*fcf3ce44SJohn Forte extern int	l_get_mode_pg(char *, uchar_t **, int);
99*fcf3ce44SJohn Forte extern void	l_element_msg_string(uchar_t, char *);
100*fcf3ce44SJohn Forte extern int	l_check_file(char *, int);
101*fcf3ce44SJohn Forte extern int	l_get_pid_from_path(const char *, const gfc_map_t *, int *);
102*fcf3ce44SJohn Forte 
103*fcf3ce44SJohn Forte #ifdef	__cplusplus
104*fcf3ce44SJohn Forte }
105*fcf3ce44SJohn Forte #endif
106*fcf3ce44SJohn Forte 
107*fcf3ce44SJohn Forte #endif	/* _A_STATE_H */
108