xref: /titanic_52/usr/src/uts/sun/sys/scsi/adapters/ifpio.h (revision db194e27210d166c10116b0681469ae6aa0fdb64)
17c478bd9Sstevel@tonic-gate /*
2*db194e27Sadailey  * CDDL HEADER START
3*db194e27Sadailey  *
4*db194e27Sadailey  * The contents of this file are subject to the terms of the
5*db194e27Sadailey  * Common Development and Distribution License (the "License").
6*db194e27Sadailey  * You may not use this file except in compliance with the License.
7*db194e27Sadailey  *
8*db194e27Sadailey  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9*db194e27Sadailey  * or http://www.opensolaris.org/os/licensing.
10*db194e27Sadailey  * See the License for the specific language governing permissions
11*db194e27Sadailey  * and limitations under the License.
12*db194e27Sadailey  *
13*db194e27Sadailey  * When distributing Covered Code, include this CDDL HEADER in each
14*db194e27Sadailey  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15*db194e27Sadailey  * If applicable, add the following below this CDDL HEADER, with the
16*db194e27Sadailey  * fields enclosed by brackets "[]" replaced with your own identifying
17*db194e27Sadailey  * information: Portions Copyright [yyyy] [name of copyright owner]
18*db194e27Sadailey  *
19*db194e27Sadailey  * CDDL HEADER END
20*db194e27Sadailey  */
21*db194e27Sadailey /*
22*db194e27Sadailey  * Copyright 1999 Sun Microsystems, Inc. All rights reserved.
23*db194e27Sadailey  * Use is subject to license terms.
247c478bd9Sstevel@tonic-gate  */
257c478bd9Sstevel@tonic-gate 
267c478bd9Sstevel@tonic-gate #ifndef	_SYS_SCSI_ADAPTERS_IFPIO_H
277c478bd9Sstevel@tonic-gate #define	_SYS_SCSI_ADAPTERS_IFPIO_H
287c478bd9Sstevel@tonic-gate 
297c478bd9Sstevel@tonic-gate #pragma ident	"%Z%%M%	%I%	%E% SMI"
307c478bd9Sstevel@tonic-gate 
317c478bd9Sstevel@tonic-gate /*
327c478bd9Sstevel@tonic-gate  * Include any headers you depend on.
337c478bd9Sstevel@tonic-gate  */
347c478bd9Sstevel@tonic-gate 
357c478bd9Sstevel@tonic-gate #ifdef	__cplusplus
367c478bd9Sstevel@tonic-gate extern "C" {
377c478bd9Sstevel@tonic-gate #endif
387c478bd9Sstevel@tonic-gate 
397c478bd9Sstevel@tonic-gate #define	IFP_IOC	('I' << 8)
407c478bd9Sstevel@tonic-gate 
417c478bd9Sstevel@tonic-gate /*
427c478bd9Sstevel@tonic-gate  * Get ifp device map ioctl.
437c478bd9Sstevel@tonic-gate  */
447c478bd9Sstevel@tonic-gate #define	IFPIOCGMAP		(IFP_IOC|1)	/* Get device map/wwn's */
457c478bd9Sstevel@tonic-gate #define	IFPIO_ADISC_ELS		(IFP_IOC|2)	/* Get ADISC info */
467c478bd9Sstevel@tonic-gate #define	IFPIO_FORCE_LIP		(IFP_IOC|3)	/* Force a LIP */
477c478bd9Sstevel@tonic-gate #define	IFPIO_LINKSTATUS	(IFP_IOC|4)	/* Link Status */
487c478bd9Sstevel@tonic-gate #define	IFPIO_DIAG_GET_FWREV	(IFP_IOC|5)	/* SunVTS diag get fw rev */
497c478bd9Sstevel@tonic-gate #define	IFPIO_DIAG_NOP		(IFP_IOC|6)	/* SunVTS diag NOOP */
507c478bd9Sstevel@tonic-gate #define	IFPIO_DIAG_MBOXCMD	(IFP_IOC|7)	/* SunVTS diag mbox cmds */
517c478bd9Sstevel@tonic-gate #define	IFPIO_LOOPBACK_FRAME	(IFP_IOC|8)	/* Diagnostic loopback */
527c478bd9Sstevel@tonic-gate #define	IFPIO_DIAG_SELFTEST	(IFP_IOC|9)	/* Diagnostic selftest */
537c478bd9Sstevel@tonic-gate #define	IFPIO_BOARD_INFO	(IFP_IOC|10)	/* Get device id and rev's */
547c478bd9Sstevel@tonic-gate #define	IFPIO_FCODE_DOWNLOAD	(IFP_IOC|11)	/* Download fcode to flash */
557c478bd9Sstevel@tonic-gate 
567c478bd9Sstevel@tonic-gate struct ifp_board_info {
577c478bd9Sstevel@tonic-gate 	uint16_t	ifpd_major;		/* FW major revision */
587c478bd9Sstevel@tonic-gate 	uint16_t	ifpd_minor;		/* FW minor revision */
597c478bd9Sstevel@tonic-gate 	uint16_t	ifpd_subminor;		/* FW subminor revision */
607c478bd9Sstevel@tonic-gate 	uint16_t	chip_rev;		/* chip revision level */
617c478bd9Sstevel@tonic-gate 	uint16_t	ctrl_id;		/* 2100 or 2200 */
627c478bd9Sstevel@tonic-gate };
637c478bd9Sstevel@tonic-gate typedef struct ifp_board_info ifp_board_info_t;
647c478bd9Sstevel@tonic-gate 
657c478bd9Sstevel@tonic-gate struct ifp_diag_fw_rev {
667c478bd9Sstevel@tonic-gate 	uint16_t	ifpd_major;		/* FW major revision */
677c478bd9Sstevel@tonic-gate 	uint16_t	ifpd_minor;		/* FW minor revision */
687c478bd9Sstevel@tonic-gate };
697c478bd9Sstevel@tonic-gate typedef struct ifp_diag_fw_rev ifp_diag_fw_rev_t;
707c478bd9Sstevel@tonic-gate 
717c478bd9Sstevel@tonic-gate struct ifp_lb_frame_cmd {
727c478bd9Sstevel@tonic-gate 	uint16_t	options;		/* diag loop-back options */
737c478bd9Sstevel@tonic-gate 	uint32_t	iter_cnt;		/* count of loopback ops */
747c478bd9Sstevel@tonic-gate 	uint32_t	xfer_cnt;		/* transmit/receive xfer len */
757c478bd9Sstevel@tonic-gate 	caddr_t		xmit_addr;		/* transmit data address */
767c478bd9Sstevel@tonic-gate 	caddr_t		recv_addr;		/* receive data address */
777c478bd9Sstevel@tonic-gate 
787c478bd9Sstevel@tonic-gate 	uint16_t	status;			/* completion status */
797c478bd9Sstevel@tonic-gate 	uint16_t	crc_cnt;		/* crc error count */
807c478bd9Sstevel@tonic-gate 	uint16_t	disparity_cnt;		/* disparity error count */
817c478bd9Sstevel@tonic-gate 	uint16_t	frame_len_err_cnt;	/* frame length error count */
827c478bd9Sstevel@tonic-gate 	uint32_t	fail_iter_cnt;		/* failing iteration count */
837c478bd9Sstevel@tonic-gate };
847c478bd9Sstevel@tonic-gate typedef struct ifp_lb_frame_cmd ifp_lb_frame_cmd_t;
857c478bd9Sstevel@tonic-gate 
867c478bd9Sstevel@tonic-gate #if defined(_LP64)
877c478bd9Sstevel@tonic-gate struct ifp_lb_frame_cmd32 {
887c478bd9Sstevel@tonic-gate 	uint16_t	options;		/* diag loop-back options */
897c478bd9Sstevel@tonic-gate 	uint32_t	iter_cnt;		/* count of loopback ops */
907c478bd9Sstevel@tonic-gate 	uint32_t	xfer_cnt;		/* transmit/receive xfer len */
917c478bd9Sstevel@tonic-gate 	caddr32_t	xmit_addr;		/* transmit data address */
927c478bd9Sstevel@tonic-gate 	caddr32_t	recv_addr;		/* receive data address */
937c478bd9Sstevel@tonic-gate 
947c478bd9Sstevel@tonic-gate 	uint16_t	status;			/* completion status */
957c478bd9Sstevel@tonic-gate 	uint16_t	crc_cnt;		/* crc error count */
967c478bd9Sstevel@tonic-gate 	uint16_t	disparity_cnt;		/* disparity error count */
977c478bd9Sstevel@tonic-gate 	uint16_t	frame_len_err_cnt;	/* frame length error count */
987c478bd9Sstevel@tonic-gate 	uint32_t	fail_iter_cnt;		/* failing iteration count */
997c478bd9Sstevel@tonic-gate };
1007c478bd9Sstevel@tonic-gate #endif
1017c478bd9Sstevel@tonic-gate 
1027c478bd9Sstevel@tonic-gate /* defines for options field */
1037c478bd9Sstevel@tonic-gate #define	LOOP_10BIT	0x0000		/* loopback at 10 bit interface */
1047c478bd9Sstevel@tonic-gate #define	LOOP_1BIT	0x0001		/* loopback at 1 bit interface */
1057c478bd9Sstevel@tonic-gate #define	LOOP_EXTERNAL	0x0002		/* loopback on external loop */
1067c478bd9Sstevel@tonic-gate #define	LOOP_XMIT_OFF	0x0004		/* transmitter powered off */
1077c478bd9Sstevel@tonic-gate #define	LOOP_XMIT_RAM	0x0010		/* xmit data from system ram */
1087c478bd9Sstevel@tonic-gate #define	LOOP_RECV_RAM	0x0020		/* receive data to system ram */
1097c478bd9Sstevel@tonic-gate #define	LOOP_ERR_STOP	0x0080		/* stop test on error */
1107c478bd9Sstevel@tonic-gate 
1117c478bd9Sstevel@tonic-gate struct ifp_diag_selftest {
1127c478bd9Sstevel@tonic-gate 	uint16_t	status;			/* completion status */
1137c478bd9Sstevel@tonic-gate 	uint16_t	test_num;		/* failing test number */
1147c478bd9Sstevel@tonic-gate 	uint16_t	fail_addr;		/* failure address */
1157c478bd9Sstevel@tonic-gate 	uint16_t	fail_data;		/* failure data */
1167c478bd9Sstevel@tonic-gate };
1177c478bd9Sstevel@tonic-gate typedef struct ifp_diag_selftest ifp_diag_selftest_t;
1187c478bd9Sstevel@tonic-gate 
1197c478bd9Sstevel@tonic-gate /* offset of the fcode from begining of file */
1207c478bd9Sstevel@tonic-gate #define	FCODE_OFFSET	0x20
1217c478bd9Sstevel@tonic-gate struct ifp_download {
1227c478bd9Sstevel@tonic-gate 	uint32_t	dl_fcode_len;		/* length of the fcode array */
1237c478bd9Sstevel@tonic-gate 	uint16_t	dl_chip_id;		/* Chip id for FCODE */
1247c478bd9Sstevel@tonic-gate 	uchar_t	dl_fcode[1];		/* the fcode */
1257c478bd9Sstevel@tonic-gate };
1267c478bd9Sstevel@tonic-gate typedef struct ifp_download ifp_download_t;
1277c478bd9Sstevel@tonic-gate 
1287c478bd9Sstevel@tonic-gate #define	IFP_NUM_ENTRIES_IN_MAP	127
1297c478bd9Sstevel@tonic-gate #define	IFP_DIAG_MAX_MBOX	10
1307c478bd9Sstevel@tonic-gate 
1317c478bd9Sstevel@tonic-gate struct ifp_al_addr_pair {
1327c478bd9Sstevel@tonic-gate 	uchar_t	ifp_al_pa;
1337c478bd9Sstevel@tonic-gate 	uchar_t	ifp_hard_address;
1347c478bd9Sstevel@tonic-gate 	uchar_t	ifp_inq_dtype;
1357c478bd9Sstevel@tonic-gate 	uchar_t	ifp_node_wwn[FC_WWN_SIZE];
1367c478bd9Sstevel@tonic-gate 	uchar_t	ifp_port_wwn[FC_WWN_SIZE];
1377c478bd9Sstevel@tonic-gate };
1387c478bd9Sstevel@tonic-gate typedef struct ifp_al_addr_pair ifp_al_addr_pair_t;
1397c478bd9Sstevel@tonic-gate 
1407c478bd9Sstevel@tonic-gate struct ifp_al_map {
1417c478bd9Sstevel@tonic-gate 	short			ifp_count;
1427c478bd9Sstevel@tonic-gate 	ifp_al_addr_pair_t	ifp_addr_pair[IFP_NUM_ENTRIES_IN_MAP];
1437c478bd9Sstevel@tonic-gate 	ifp_al_addr_pair_t	ifp_hba_addr;
1447c478bd9Sstevel@tonic-gate };
1457c478bd9Sstevel@tonic-gate typedef struct ifp_al_map ifp_al_map_t;
1467c478bd9Sstevel@tonic-gate 
1477c478bd9Sstevel@tonic-gate struct adisc_payload {
1487c478bd9Sstevel@tonic-gate 	uint_t	adisc_hardaddr;
1497c478bd9Sstevel@tonic-gate 	uchar_t	adisc_portwwn[8];
1507c478bd9Sstevel@tonic-gate 	uchar_t	adisc_nodewwn[8];
1517c478bd9Sstevel@tonic-gate 	uint_t	adisc_dest;
1527c478bd9Sstevel@tonic-gate };
1537c478bd9Sstevel@tonic-gate 
1547c478bd9Sstevel@tonic-gate struct rls_payload {
1557c478bd9Sstevel@tonic-gate 	uint_t	rls_portno;
1567c478bd9Sstevel@tonic-gate 	uint_t	rls_linkfail;
1577c478bd9Sstevel@tonic-gate 	uint_t	rls_syncfail;
1587c478bd9Sstevel@tonic-gate 	uint_t	rls_sigfail;
1597c478bd9Sstevel@tonic-gate 	uint_t	rls_primitiverr;
1607c478bd9Sstevel@tonic-gate 	uint_t	rls_invalidword;
1617c478bd9Sstevel@tonic-gate 	uint_t	rls_invalidcrc;
1627c478bd9Sstevel@tonic-gate };
1637c478bd9Sstevel@tonic-gate typedef struct rls_payload rls_payload_t;
1647c478bd9Sstevel@tonic-gate 
1657c478bd9Sstevel@tonic-gate struct ifp_target_stats {
1667c478bd9Sstevel@tonic-gate 	int	logouts_recvd;
1677c478bd9Sstevel@tonic-gate 					/*
1687c478bd9Sstevel@tonic-gate 					 * unsolicited LOGOs recvd from
1697c478bd9Sstevel@tonic-gate 					 * target
1707c478bd9Sstevel@tonic-gate 					 */
1717c478bd9Sstevel@tonic-gate 	int	task_mgmt_failures;
1727c478bd9Sstevel@tonic-gate 	int	data_ro_mismatches;
1737c478bd9Sstevel@tonic-gate 	int	dl_len_mismatches;
1747c478bd9Sstevel@tonic-gate };
1757c478bd9Sstevel@tonic-gate typedef struct ifp_target_stats ifp_target_stats_t;
1767c478bd9Sstevel@tonic-gate 
1777c478bd9Sstevel@tonic-gate struct ifp_stats {
1787c478bd9Sstevel@tonic-gate 	int	version;		/* version of this struct */
1797c478bd9Sstevel@tonic-gate 	int	lip_count;		/* lips forced by ifp */
1807c478bd9Sstevel@tonic-gate 	int	ncmds;			/* outstanding commands */
1817c478bd9Sstevel@tonic-gate 	ifp_target_stats_t tstats[IFP_NUM_ENTRIES_IN_MAP]; /* per tgt stats */
1827c478bd9Sstevel@tonic-gate };
1837c478bd9Sstevel@tonic-gate typedef struct ifp_stats ifp_stats_t;
1847c478bd9Sstevel@tonic-gate 
1857c478bd9Sstevel@tonic-gate /* XXX temp hack to get sf/socal ioctls used by luxadm to work with ifp */
1867c478bd9Sstevel@tonic-gate 
1877c478bd9Sstevel@tonic-gate #if !defined(SFIOCGMAP)
1887c478bd9Sstevel@tonic-gate #define	SFIOCGMAP		((0xda << 8)|1)
1897c478bd9Sstevel@tonic-gate #endif
1907c478bd9Sstevel@tonic-gate #if !defined(FCIO_GETMAP)
1917c478bd9Sstevel@tonic-gate #define	FCIO_GETMAP		(('F' << 8)|175)
1927c478bd9Sstevel@tonic-gate struct lilpmap {
1937c478bd9Sstevel@tonic-gate 	ushort_t lilp_magic;
1947c478bd9Sstevel@tonic-gate 	ushort_t lilp_myalpa;
1957c478bd9Sstevel@tonic-gate 	uchar_t  lilp_length;
1967c478bd9Sstevel@tonic-gate 	uchar_t  lilp_list[127];
1977c478bd9Sstevel@tonic-gate };
1987c478bd9Sstevel@tonic-gate #endif
1997c478bd9Sstevel@tonic-gate 
2007c478bd9Sstevel@tonic-gate /*
2017c478bd9Sstevel@tonic-gate  * Structure used for diag loopback commands.
2027c478bd9Sstevel@tonic-gate  * This is copied from socalvar.h and must
2037c478bd9Sstevel@tonic-gate  * remain the same as for the socal driver.
2047c478bd9Sstevel@tonic-gate  */
2057c478bd9Sstevel@tonic-gate typedef	struct flb_hdr {
2067c478bd9Sstevel@tonic-gate 	uint_t max_length;
2077c478bd9Sstevel@tonic-gate 	uint_t length;
2087c478bd9Sstevel@tonic-gate } flb_hdr_t;
2097c478bd9Sstevel@tonic-gate /* This is the max loopback transfer size */
2107c478bd9Sstevel@tonic-gate #define	MAX_LOOPBACK		65536
2117c478bd9Sstevel@tonic-gate 
2127c478bd9Sstevel@tonic-gate #if !defined(FCIO_FORCE_LIP)
2137c478bd9Sstevel@tonic-gate #define	FCIO_FORCE_LIP		(('F' << 8)|177)
2147c478bd9Sstevel@tonic-gate #endif
2157c478bd9Sstevel@tonic-gate #if !defined(FCIO_LINKSTATUS)
2167c478bd9Sstevel@tonic-gate #define	FCIO_LINKSTATUS		(('F' << 8)|183)
2177c478bd9Sstevel@tonic-gate #endif
2187c478bd9Sstevel@tonic-gate #if !defined(FCIO_FCODE_MCODE_VERSION)
2197c478bd9Sstevel@tonic-gate #define	FCIO_FCODE_MCODE_VERSION	(('F' << 8)|202)
2207c478bd9Sstevel@tonic-gate #endif
2217c478bd9Sstevel@tonic-gate struct ifp_fm_version {
2227c478bd9Sstevel@tonic-gate 	int	fcode_ver_len;
2237c478bd9Sstevel@tonic-gate 	int	mcode_ver_len;
2247c478bd9Sstevel@tonic-gate 	int	prom_ver_len;
2257c478bd9Sstevel@tonic-gate 	caddr_t	fcode_ver;
2267c478bd9Sstevel@tonic-gate 	caddr_t	mcode_ver;
2277c478bd9Sstevel@tonic-gate 	caddr_t	prom_ver;
2287c478bd9Sstevel@tonic-gate };
2297c478bd9Sstevel@tonic-gate #if defined(_LP64)
2307c478bd9Sstevel@tonic-gate struct ifp_fm_version32 {
2317c478bd9Sstevel@tonic-gate 	int		fcode_ver_len;
2327c478bd9Sstevel@tonic-gate 	int		mcode_ver_len;
2337c478bd9Sstevel@tonic-gate 	int		prom_ver_len;
2347c478bd9Sstevel@tonic-gate 	caddr32_t	fcode_ver;
2357c478bd9Sstevel@tonic-gate 	caddr32_t	mcode_ver;
2367c478bd9Sstevel@tonic-gate 	caddr32_t	prom_ver;
2377c478bd9Sstevel@tonic-gate };
2387c478bd9Sstevel@tonic-gate #endif
2397c478bd9Sstevel@tonic-gate 
2407c478bd9Sstevel@tonic-gate /* XXX end temp hack to get sf/socal ioctls used by luxadm to work with ifp */
2417c478bd9Sstevel@tonic-gate 
2427c478bd9Sstevel@tonic-gate struct ifp_diag_mbox {
2437c478bd9Sstevel@tonic-gate 	ushort_t	ifp_in_mbox[8];	/* in regs -- from ISP */
2447c478bd9Sstevel@tonic-gate 	ushort_t	ifp_out_mbox[8];	/* out regs -- to ISP */
2457c478bd9Sstevel@tonic-gate };
2467c478bd9Sstevel@tonic-gate typedef struct ifp_diag_mbox ifp_diag_mbox_t;
2477c478bd9Sstevel@tonic-gate 
2487c478bd9Sstevel@tonic-gate struct ifp_diag_regs {
2497c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_mailbox[8];
2507c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_hccr;
2517c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_bus_sema;
2527c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_isr;
2537c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_icr;
2547c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_icsr;
2557c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_cdma_count;
2567c478bd9Sstevel@tonic-gate 	uint_t			ifpd_cdma_addr;
2577c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_cdma_status;
2587c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_cdma_control;
2597c478bd9Sstevel@tonic-gate 	uint_t			ifpd_rdma_count;
2607c478bd9Sstevel@tonic-gate 	uint_t			ifpd_rdma_addr;
2617c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_rdma_status;
2627c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_rdma_control;
2637c478bd9Sstevel@tonic-gate 	uint_t			ifpd_tdma_count;
2647c478bd9Sstevel@tonic-gate 	uint_t			ifpd_tdma_addr;
2657c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_tdma_status;
2667c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_tdma_control;
2677c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_risc_reg[16];
2687c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_risc_psr;
2697c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_risc_ivr;
2707c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_risc_pcr;
2717c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_risc_rar0;
2727c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_risc_rar1;
2737c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_risc_lcr;
2747c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_risc_pc;
2757c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_risc_mtr;
2767c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_risc_sp;
2777c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_request_in;
2787c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_request_out;
2797c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_response_in;
2807c478bd9Sstevel@tonic-gate 	ushort_t		ifpd_response_out;
2817c478bd9Sstevel@tonic-gate 	void			*ifpd_current_req_ptr;
2827c478bd9Sstevel@tonic-gate 	void			*ifpd_base_req_ptr;
2837c478bd9Sstevel@tonic-gate 	void			*ifpd_current_resp_ptr;
2847c478bd9Sstevel@tonic-gate 	void			*ifpd_base_resp_ptr;
2857c478bd9Sstevel@tonic-gate };
2867c478bd9Sstevel@tonic-gate typedef struct ifp_diag_regs ifp_diag_regs_t;
2877c478bd9Sstevel@tonic-gate 
2887c478bd9Sstevel@tonic-gate struct ifp_diag_cmd {
2897c478bd9Sstevel@tonic-gate 	short		ifp_cmds_rev;		/* revision */
2907c478bd9Sstevel@tonic-gate 	short		ifp_cmds_current_rev;	/* rev driver expects */
2917c478bd9Sstevel@tonic-gate 	short		ifp_cmds_count;		/* number of cmds */
2927c478bd9Sstevel@tonic-gate 	short		ifp_cmds_done;		/* number of cmds done */
2937c478bd9Sstevel@tonic-gate 	ifp_diag_regs_t	ifp_regs;		/* reg dump area */
2947c478bd9Sstevel@tonic-gate 	ifp_diag_mbox_t	ifp_mbox[IFP_DIAG_MAX_MBOX];	/* mbox values */
2957c478bd9Sstevel@tonic-gate };
2967c478bd9Sstevel@tonic-gate typedef struct ifp_diag_cmd ifp_diag_cmd_t;
2977c478bd9Sstevel@tonic-gate 
2987c478bd9Sstevel@tonic-gate #define	IFP_DIAG_CMD_REV	0x1		/* diag cmd rev supported */
2997c478bd9Sstevel@tonic-gate 
3007c478bd9Sstevel@tonic-gate #ifdef	__cplusplus
3017c478bd9Sstevel@tonic-gate }
3027c478bd9Sstevel@tonic-gate #endif
3037c478bd9Sstevel@tonic-gate 
3047c478bd9Sstevel@tonic-gate #endif	/* _SYS_SCSI_ADAPTERS_IFPIO_H */
305