2 * *****************************************************************************
5 * hbaapi.h - general header file for client
6 * and library developers
9 * The contents of this file are subject to the SNIA Public License
10 * Version 1.0 (the "License"); you may not use this file except in
11 * compliance with the License. You may obtain a copy of the License at
13 * /http://www.snia.org/English/Resources/Code/OpenSource.html
15 * Software distributed under the License is distributed on an "AS IS"
16 * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
17 * the License for the specific language governing rights and limitations
20 * The Original Code is SNIA HBA API general header file
22 * The Initial Developer of the Original Code is:
23 * Benjamin F. Kuo, Troika Networks, Inc. (benk@troikanetworks.com)
26 * Tuan Lam, QLogic Corp. (t_lam@qlc.com)
27 * Dan Willie, Emulex Corp. (Dan.Willie@emulex.com)
28 * Dixon Hutchinson, Legato Systems, Inc. (dhutchin@legato.com)
29 * David Dillard, VERITAS Software Corp. (david.dillard@veritas.com)
31 *******************************************************************************
34 * 03/09/2000 Initial Draft
35 * (for other changes... see the CVS logs)
36 *******************************************************************************
47 /* Library version string */
48 #define HBA_LIBVERSION 2
50 /* DLL imports for WIN32 operation */
53 #define HBA_API __declspec(dllexport)
55 #define HBA_API __declspec(dllimport)
61 /* OS specific definitions */
64 typedef unsigned char HBA_UINT8
; // Unsigned 8 bits
65 typedef char HBA_INT8
; // Signed 8 bits
66 typedef unsigned short HBA_UINT16
; // Unsigned 16 bits
67 typedef short HBA_INT16
; // Signed 16 bits
68 typedef unsigned int HBA_UINT32
; // Unsigned 32 bits
69 typedef int HBA_INT32
; // Signed 32 bits
70 typedef void* HBA_PVOID
; // Pointer to void
71 typedef HBA_UINT32 HBA_VOID32
; // Opaque 32 bits
74 /* Don't confuse, _WIN32 with WIN32... OK, how do you accompish that */
76 typedef _int64 HBA_INT64
;
77 typedef unsigned _int64 HBA_UINT64
;
88 #endif /* #ifdef _WIN32 */
92 #include <time.h> /* Needed for struct tm */
94 /* Note this section needs to be cleaned up for various Unix platforms */
95 typedef unsigned char HBA_UINT8
; /* Unsigned 8 bits */
96 typedef char HBA_INT8
; /* Signed 8 bits */
97 typedef unsigned short HBA_UINT16
; /* Unsigned 16 bits */
98 typedef short HBA_INT16
; /* Signed 16 bits */
99 typedef unsigned int HBA_UINT32
; /* Unsigned 32 bits */
100 typedef int HBA_INT32
; /* Signed 32 bits */
101 typedef void* HBA_PVOID
; /* Pointer to void */
102 typedef HBA_UINT32 HBA_VOID32
; /* Opaque 32 bits */
103 typedef long long HBA_INT64
;
104 typedef long long HBA_UINT64
;
106 #endif /* #ifdef WIN32 */
109 /* 4.2.1 Handle to Device */
110 typedef HBA_UINT32 HBA_HANDLE
;
112 #define HBA_HANDLE_INVALID 0
114 /* 4.2.2 Status Return Values */
115 typedef HBA_UINT32 HBA_STATUS
;
117 #define HBA_STATUS_OK 0
118 #define HBA_STATUS_ERROR 1 /* Error */
119 #define HBA_STATUS_ERROR_NOT_SUPPORTED 2 /* Function not supported.*/
120 #define HBA_STATUS_ERROR_INVALID_HANDLE 3 /* invalid handle */
121 #define HBA_STATUS_ERROR_ARG 4 /* Bad argument */
122 #define HBA_STATUS_ERROR_ILLEGAL_WWN 5 /* WWN not recognized */
123 #define HBA_STATUS_ERROR_ILLEGAL_INDEX 6 /* Index not recognized */
124 #define HBA_STATUS_ERROR_MORE_DATA 7 /* Larger buffer required */
125 #define HBA_STATUS_ERROR_STALE_DATA 8 /* Information has changed since
127 * HBA_Refreshinformation */
128 #define HBA_STATUS_SCSI_CHECK_CONDITION 9 /* Obvious */
129 #define HBA_STATUS_ERROR_BUSY 10 /* Adapter busy or reserved,
130 * retry may be effective */
131 #define HBA_STATUS_ERROR_TRY_AGAIN 11 /* Request timedout,
132 * retry may be effective */
133 #define HBA_STATUS_ERROR_UNAVAILABLE 12 /* Referenced HBA has been removed
135 #define HBA_STATUS_ERROR_ELS_REJECT 13 /* The requested ELS was rejected by
136 * the local adapter */
137 #define HBA_STATUS_ERROR_INVALID_LUN 14 /* The specified LUN is not provided
138 * the specified adapter */
139 #define HBA_STATUS_ERROR_INCOMPATIBLE 15 /* An incompatibility has been
140 * detected among the library and driver modules
141 * invoked which will cause one or more functions
142 * in the highest version that all support to
143 * operate incorrectly. The differing function
144 * sets of software modules implementing different
145 * versions of the HBA API specification does not
146 * in itself constitute an incompatibility. Known
147 * interoperability bugs among supposedly
148 * compatible versions should be reported as
149 * incompatibilities, but not all such
150 * interoperability bugs may be known. This value
151 * may be returned by any function that calls a
152 * Vendor Specific Library and returns an
153 * HBA_STATUS, and by HBA_LoadLibrary and
154 * HBA_GetAdapterName. */
156 #define HBA_STATUS_ERROR_AMBIGUOUS_WWN 16 /* Multiple adapters have a matching
157 * WWN. This could occur if the
158 * NodeWWN of multiple adapters is
160 #define HBA_STATUS_ERROR_LOCAL_BUS 17 /* A persistent binding request
161 * included a bad local SCSI bus
163 #define HBA_STATUS_ERROR_LOCAL_TARGET 18 /* A persistent binding request
164 * included a bad local SCSI target
166 #define HBA_STATUS_ERROR_LOCAL_LUN 19 /* A persistent binding request
167 * included a bad local SCSI logical
169 #define HBA_STATUS_ERROR_LOCAL_SCSIID_BOUND 20
170 /* A persistent binding set request
171 * included a local SCSI ID that was
173 #define HBA_STATUS_ERROR_TARGET_FCID 21 /* A persistent binding request
174 * included a bad or unlocatable FCP
176 #define HBA_STATUS_ERROR_TARGET_NODE_WWN 22 /* A persistent binding request
177 * included a bad FCP Target Node
179 #define HBA_STATUS_ERROR_TARGET_PORT_WWN 23 /* A persistent binding request
180 * included a bad FCP Target Port
182 #define HBA_STATUS_ERROR_TARGET_LUN 24 /* A persistent binding request
183 * included an FCP Logical Unit Number
184 * not defined by the identified
186 #define HBA_STATUS_ERROR_TARGET_LUID 25 /* A persistent binding request
187 * included an undefined or otherwise
188 * inaccessible Logical Unit Unique
190 #define HBA_STATUS_ERROR_NO_SUCH_BINDING 26 /* A persistent binding remove request
191 * included a binding which did not
192 * match a binding established by the
194 #define HBA_STATUS_ERROR_NOT_A_TARGET 27 /* A SCSI command was requested to an
195 * Nx_Port that was not a SCSI
197 #define HBA_STATUS_ERROR_UNSUPPORTED_FC4 28 /* A request was made concerning an
198 * unsupported FC-4 protocol */
201 #define HBA_STATUS_ERROR_INCAPABLE 29 /* A request was made to enable
202 * unimplemented capabilities for a
205 /* 4.2.3 Port Operational Modes Values */
206 typedef HBA_UINT32 HBA_PORTTYPE
;
208 #define HBA_PORTTYPE_UNKNOWN 1 /* Unknown */
209 #define HBA_PORTTYPE_OTHER 2 /* Other */
210 #define HBA_PORTTYPE_NOTPRESENT 3 /* Not present */
211 #define HBA_PORTTYPE_NPORT 5 /* Fabric */
212 #define HBA_PORTTYPE_NLPORT 6 /* Public Loop */
213 #define HBA_PORTTYPE_FLPORT 7
214 #define HBA_PORTTYPE_FPORT 8 /* Fabric Port */
215 #define HBA_PORTTYPE_EPORT 9 /* Fabric expansion port */
216 #define HBA_PORTTYPE_GPORT 10 /* Generic Fabric Port */
217 #define HBA_PORTTYPE_LPORT 20 /* Private Loop */
218 #define HBA_PORTTYPE_PTP 21 /* Point to Point */
221 typedef HBA_UINT32 HBA_PORTSTATE
;
222 #define HBA_PORTSTATE_UNKNOWN 1 /* Unknown */
223 #define HBA_PORTSTATE_ONLINE 2 /* Operational */
224 #define HBA_PORTSTATE_OFFLINE 3 /* User Offline */
225 #define HBA_PORTSTATE_BYPASSED 4 /* Bypassed */
226 #define HBA_PORTSTATE_DIAGNOSTICS 5 /* In diagnostics mode */
227 #define HBA_PORTSTATE_LINKDOWN 6 /* Link Down */
228 #define HBA_PORTSTATE_ERROR 7 /* Port Error */
229 #define HBA_PORTSTATE_LOOPBACK 8 /* Loopback */
232 typedef HBA_UINT32 HBA_PORTSPEED
;
233 #define HBA_PORTSPEED_UNKNOWN 0 /* Unknown - transceiver incable
235 #define HBA_PORTSPEED_1GBIT 1 /* 1 GBit/sec */
236 #define HBA_PORTSPEED_2GBIT 2 /* 2 GBit/sec */
237 #define HBA_PORTSPEED_10GBIT 4 /* 10 GBit/sec */
238 #define HBA_PORTSPEED_4GBIT 8 /* 4 GBit/sec */
239 #define HBA_PORTSPEED_8GBIT 16 /* 8 GBit/sec */
240 #define HBA_PORTSPEED_16GBIT 32 /* 16 GBit/sec */
241 #define HBA_PORTSPEED_NOT_NEGOTIATED (1<<15) /* Speed not established */
245 /* 4.2.4 Class of Service Values - See GS-2 Spec.*/
247 typedef HBA_UINT32 HBA_COS
;
250 /* 4.2.5 Fc4Types Values */
252 typedef struct HBA_fc4types
{
253 HBA_UINT8 bits
[32]; /* 32 bytes of FC-4 per GS-2 */
254 } HBA_FC4TYPES
, *PHBA_FC4TYPES
;
256 /* 4.2.6 Basic Types */
258 typedef struct HBA_wwn
{
260 } HBA_WWN
, *PHBA_WWN
;
262 typedef struct HBA_ipaddress
{
263 int ipversion
; /* see enumerations in RNID */
266 unsigned char ipv4address
[4];
267 unsigned char ipv6address
[16];
269 } HBA_IPADDRESS
, *PHBA_IPADDRESS
;
271 typedef HBA_INT8 HBA_BOOLEAN
;
273 /* 4.2.7 Adapter Attributes */
274 typedef struct hba_AdapterAttributes
{
275 char Manufacturer
[64]; /*Emulex */
276 char SerialNumber
[64]; /* A12345 */
277 char Model
[256]; /* QLA2200 */
278 char ModelDescription
[256]; /* Agilent TachLite */
280 char NodeSymbolicName
[256]; /* From GS-3 */
281 char HardwareVersion
[256]; /* Vendor use */
282 char DriverVersion
[256]; /* Vendor use */
283 char OptionROMVersion
[256]; /* Vendor use - i.e. hardware boot ROM*/
284 char FirmwareVersion
[256]; /* Vendor use */
285 HBA_UINT32 VendorSpecificID
; /* Vendor specific */
286 HBA_UINT32 NumberOfPorts
;
287 char DriverName
[256]; /* Binary path and/or name of driver
289 } HBA_ADAPTERATTRIBUTES
, *PHBA_ADAPTERATTRIBUTES
;
291 /* 4.2.8 Port Attributes */
292 typedef struct HBA_PortAttributes
{
296 HBA_PORTTYPE PortType
; /*PTP, Fabric, etc. */
297 HBA_PORTSTATE PortState
;
298 HBA_COS PortSupportedClassofService
;
299 HBA_FC4TYPES PortSupportedFc4Types
;
300 HBA_FC4TYPES PortActiveFc4Types
;
301 char PortSymbolicName
[256];
302 char OSDeviceName
[256]; /* \device\ScsiPort3 */
303 HBA_PORTSPEED PortSupportedSpeed
;
304 HBA_PORTSPEED PortSpeed
;
305 HBA_UINT32 PortMaxFrameSize
;
307 HBA_UINT32 NumberofDiscoveredPorts
;
308 } HBA_PORTATTRIBUTES
, *PHBA_PORTATTRIBUTES
;
312 /* 4.2.9 Port Statistics */
314 typedef struct HBA_PortStatistics
{
315 HBA_INT64 SecondsSinceLastReset
;
322 HBA_INT64 ErrorFrames
;
323 HBA_INT64 DumpedFrames
;
324 HBA_INT64 LinkFailureCount
;
325 HBA_INT64 LossOfSyncCount
;
326 HBA_INT64 LossOfSignalCount
;
327 HBA_INT64 PrimitiveSeqProtocolErrCount
;
328 HBA_INT64 InvalidTxWordCount
;
329 HBA_INT64 InvalidCRCCount
;
330 } HBA_PORTSTATISTICS
, *PHBA_PORTSTATISTICS
;
334 /* 4.2.10 FCP Attributes */
336 typedef enum HBA_fcpbindingtype
{ TO_D_ID
, TO_WWN
, TO_OTHER
} HBA_FCPBINDINGTYPE
;
338 typedef struct HBA_ScsiId
{
339 char OSDeviceName
[256]; /* \device\ScsiPort3 */
340 HBA_UINT32 ScsiBusNumber
; /* Bus on the HBA */
341 HBA_UINT32 ScsiTargetNumber
; /* SCSI Target ID to OS */
342 HBA_UINT32 ScsiOSLun
;
343 } HBA_SCSIID
, *PHBA_SCSIID
;
345 typedef struct HBA_FcpId
{
350 } HBA_FCPID
, *PHBA_FCPID
;
352 typedef struct HBA_LUID
{
353 char buffer
[256]; /* Unique Device Identifier */
354 } HBA_LUID
, *PHBA_LUID
;
356 typedef struct HBA_FcpScsiEntry
{
359 } HBA_FCPSCSIENTRY
, *PHBA_FCPSCSIENTRY
;
361 typedef struct HBA_FcpScsiEntryV2
{
365 } HBA_FCPSCSIENTRYV2
, *PHBA_FCPSCSIENTRYV2
;
367 typedef struct HBA_FCPTargetMapping
{
368 HBA_UINT32 NumberOfEntries
;
369 HBA_FCPSCSIENTRY entry
[1]; /* Variable length array
370 * containing mappings */
371 } HBA_FCPTARGETMAPPING
, *PHBA_FCPTARGETMAPPING
;
373 typedef struct HBA_FCPTargetMappingV2
{
374 HBA_UINT32 NumberOfEntries
;
375 HBA_FCPSCSIENTRYV2 entry
[1]; /* Variable length array
376 * containing mappings */
377 } HBA_FCPTARGETMAPPINGV2
, *PHBA_FCPTARGETMAPPINGV2
;
379 typedef struct HBA_FCPBindingEntry
{
380 HBA_FCPBINDINGTYPE type
;
382 HBA_FCPID FcpId
; /* WWN valid only if type is
383 * to WWN, FcpLun always valid */
385 } HBA_FCPBINDINGENTRY
, *PHBA_FCPBINDINGENTRY
;
387 typedef struct HBA_FCPBinding
{
388 HBA_UINT32 NumberOfEntries
;
389 HBA_FCPBINDINGENTRY entry
[1]; /* Variable length array */
390 } HBA_FCPBINDING
, *PHBA_FCPBINDING
;
392 /* 4.2.11 FC-3 Management Atrributes */
394 typedef enum HBA_wwntype
{ NODE_WWN
, PORT_WWN
} HBA_WWNTYPE
;
396 typedef struct HBA_MgmtInfo
{
400 HBA_UINT32 NumberOfAttachedNodes
;
401 HBA_UINT16 IPVersion
;
403 HBA_UINT8 IPAddress
[16];
405 HBA_UINT16 TopologyDiscoveryFlags
;
406 } HBA_MGMTINFO
, *PHBA_MGMTINFO
;
409 #define HBA_EVENT_LIP_OCCURRED 1
410 #define HBA_EVENT_LINK_UP 2
411 #define HBA_EVENT_LINK_DOWN 3
412 #define HBA_EVENT_LIP_RESET_OCCURRED 4
413 #define HBA_EVENT_RSCN 5
414 #define HBA_EVENT_PROPRIETARY 0xFFFF
416 typedef struct HBA_Link_EventInfo
{
417 HBA_UINT32 PortFcId
; /* Port where event occurred */
418 HBA_UINT32 Reserved
[3];
419 } HBA_LINK_EVENTINFO
, *PHBA_LINK_EVENTINFO
;
421 typedef struct HBA_RSCN_EventInfo
{
422 HBA_UINT32 PortFcId
; /* Port where event occurred */
423 HBA_UINT32 NPortPage
; /* Reference FC-FS for RSCN ELS
424 * "Affected N-Port Pages"*/
425 HBA_UINT32 Reserved
[2];
426 } HBA_RSCN_EVENTINFO
, *PHBA_RSCN_EVENTINFO
;
428 typedef struct HBA_Pty_EventInfo
{
429 HBA_UINT32 PtyData
[4]; /* Proprietary data */
430 } HBA_PTY_EVENTINFO
, *PHBA_PTY_EVENTINFO
;
432 typedef struct HBA_EventInfo
{
433 HBA_UINT32 EventCode
;
435 HBA_LINK_EVENTINFO Link_EventInfo
;
436 HBA_RSCN_EVENTINFO RSCN_EventInfo
;
437 HBA_PTY_EVENTINFO Pty_EventInfo
;
439 } HBA_EVENTINFO
, *PHBA_EVENTINFO
;
441 typedef struct HBA_LibraryAttributes
{
446 struct tm build_date
;
447 } HBA_LIBRARYATTRIBUTES
, *PHBA_LIBRARYATTRIBUTES
;
449 /* Persistant Binding... */
450 typedef HBA_UINT32 HBA_BIND_TYPE
;
451 #define HBA_BIND_TO_D_ID 0x0001
452 #define HBA_BIND_TO_WWPN 0x0002
453 #define HBA_BIND_TO_WWNN 0x0004
454 #define HBA_BIND_TO_LUID 0x0008
455 #define HBA_BIND_TARGETS 0x0800
457 /* A bit mask of Rev 2.0 persistent binding capabilities */
458 typedef HBA_UINT32 HBA_BIND_CAPABILITY
;
459 /* The following are bit flags indicating persistent binding capabilities */
460 #define HBA_CAN_BIND_TO_D_ID 0x0001
461 #define HBA_CAN_BIND_TO_WWPN 0x0002
462 #define HBA_CAN_BIND_TO_WWNN 0x0004
463 #define HBA_CAN_BIND_TO_LUID 0x0008
464 #define HBA_CAN_BIND_ANY_LUNS 0x0400
465 #define HBA_CAN_BIND_TARGETS 0x0800
466 #define HBA_CAN_BIND_AUTOMAP 0x1000
467 #define HBA_CAN_BIND_CONFIGURED 0x2000
469 #define HBA_BIND_STATUS_DISABLED 0x00
470 #define HBA_BIND_STATUS_ENABLED 0x01
472 typedef HBA_UINT32 HBA_BIND_STATUS
;
474 #define HBA_BIND_EFFECTIVE_AT_REBOOT 0x00
475 #define HBA_BIND_EFFECTIVE_IMMEDIATE 0x01
477 typedef HBA_UINT32 HBA_BIND_EFFECTIVE
;
479 typedef struct HBA_FCPBindingEntry2
{
485 } HBA_FCPBINDINGENTRY2
, *PHBA_FCPBINDINGENTRY2
;
487 typedef struct HBA_FcpBinding2
{
488 HBA_UINT32 NumberOfEntries
;
490 entry
[1]; /* Variable length array */
491 } HBA_FCPBINDING2
, *PHBA_FCPBINDING2
;
493 /* FC-4 Instrumentation */
494 typedef struct HBA_FC4Statistics
{
495 HBA_INT64 InputRequests
;
496 HBA_INT64 OutputRequests
;
497 HBA_INT64 ControlRequests
;
498 HBA_INT64 InputMegabytes
;
499 HBA_INT64 OutputMegabytes
;
500 } HBA_FC4STATISTICS
, *PHBA_FC4STATISTICS
;
503 typedef void * HBA_CALLBACKHANDLE
;
504 /* Adapter Level Events */
505 #define HBA_EVENT_ADAPTER_UNKNOWN 0x100
506 #define HBA_EVENT_ADAPTER_ADD 0x101
507 #define HBA_EVENT_ADAPTER_REMOVE 0x102
508 #define HBA_EVENT_ADAPTER_CHANGE 0x103
510 /* Port Level Events */
511 #define HBA_EVENT_PORT_UNKNOWN 0x200
512 #define HBA_EVENT_PORT_OFFLINE 0x201
513 #define HBA_EVENT_PORT_ONLINE 0x202
514 #define HBA_EVENT_PORT_NEW_TARGETS 0x203
515 #define HBA_EVENT_PORT_FABRIC 0x204
517 /* Port Statistics Events */
518 #define HBA_EVENT_PORT_STAT_THRESHOLD 0x301
519 #define HBA_EVENT_PORT_STAT_GROWTH 0x302
521 /* Target Level Events */
522 #define HBA_EVENT_TARGET_UNKNOWN 0x400
523 #define HBA_EVENT_TARGET_OFFLINE 0x401
524 #define HBA_EVENT_TARGET_ONLINE 0x402
525 #define HBA_EVENT_TARGET_REMOVED 0x403
527 /* Fabric Link Events */
528 #define HBA_EVENT_LINK_UNKNOWN 0x500
529 #define HBA_EVENT_LINK_INCIDENT 0x501
531 HBA_API HBA_UINT32
HBA_GetVersion();
534 * Make sure HBA_LoadLibrary returns before any other threads
535 * make calls to the library
537 HBA_API HBA_STATUS
HBA_LoadLibrary(void);
539 HBA_API HBA_STATUS
HBA_FreeLibrary(void);
541 HBA_API HBA_UINT32
HBA_GetNumberOfAdapters(void);
543 HBA_API HBA_STATUS
HBA_GetAdapterName(
544 HBA_UINT32 adapterindex
,
548 HBA_API HBA_HANDLE
HBA_OpenAdapter(
552 HBA_API HBA_STATUS
HBA_OpenAdapterByWWN(
557 HBA_API
void HBA_CloseAdapter(
561 HBA_API HBA_STATUS
HBA_GetAdapterAttributes(
563 HBA_ADAPTERATTRIBUTES
567 HBA_API HBA_STATUS
HBA_GetAdapterPortAttributes(
569 HBA_UINT32 portindex
,
570 HBA_PORTATTRIBUTES
*portattributes
573 HBA_API HBA_STATUS
HBA_GetPortStatistics(
575 HBA_UINT32 portindex
,
576 HBA_PORTSTATISTICS
*portstatistics
579 HBA_API HBA_STATUS
HBA_GetDiscoveredPortAttributes(
581 HBA_UINT32 portindex
,
582 HBA_UINT32 discoveredportindex
,
583 HBA_PORTATTRIBUTES
*portattributes
586 HBA_API HBA_STATUS
HBA_GetPortAttributesByWWN(
589 HBA_PORTATTRIBUTES
*portattributes
592 HBA_API HBA_STATUS
HBA_SendCTPassThruV2(
596 HBA_UINT32 ReqBufferSize
,
598 HBA_UINT32
*pRspBufferSize
601 /* Depricated, but supported */
602 HBA_API HBA_STATUS
HBA_SendCTPassThru(
605 HBA_UINT32 ReqBufferSize
,
607 HBA_UINT32 RspBufferSize
610 HBA_API
void HBA_RefreshAdapterConfiguration();
612 HBA_API HBA_STATUS
HBA_GetEventBuffer(
614 HBA_EVENTINFO
*EventBuffer
,
615 HBA_UINT32
*EventBufferCount
618 HBA_API HBA_STATUS
HBA_SetRNIDMgmtInfo(
623 HBA_API HBA_STATUS
HBA_GetRNIDMgmtInfo(
628 HBA_API HBA_STATUS
HBA_SendRNIDV2(
633 HBA_UINT32 NodeIdDataFormat
,
635 HBA_UINT32
*pRspBufferSize
638 /* Depricated, but supported */
639 HBA_API HBA_STATUS
HBA_SendRNID(
644 HBA_UINT32
*pRspBufferSize
647 HBA_API HBA_STATUS
HBA_SendRLS (
652 HBA_UINT32
*pRspBufferSize
655 HBA_API HBA_STATUS
HBA_SendRPL (
659 HBA_UINT32 agent_domain
,
660 HBA_UINT32 portindex
,
662 HBA_UINT32
*pRspBufferSize
665 HBA_API HBA_STATUS
HBA_SendRPS (
669 HBA_UINT32 agent_domain
,
671 HBA_UINT32 object_port_number
,
673 HBA_UINT32
*pRspBufferSize
676 HBA_API HBA_STATUS
HBA_SendSRL (
682 HBA_UINT32
*pRspBufferSize
685 HBA_API HBA_STATUS
HBA_SendLIRR (
692 HBA_UINT32
*pRspBufferSize
696 HBA_API HBA_STATUS
HBA_GetFC4Statistics (
700 HBA_FC4STATISTICS
*pstatistics
703 HBA_API HBA_STATUS
HBA_GetFCPStatistics (
705 const HBA_SCSIID
*lunit
,
706 HBA_FC4STATISTICS
*pstatistics
);
708 HBA_API
void HBA_RefreshInformation(
712 HBA_API
void HBA_ResetStatistics(
717 HBA_API HBA_STATUS
HBA_GetFcpTargetMapping(
723 HBA_API HBA_STATUS
HBA_GetFcpTargetMappingV2(
726 HBA_FCPTARGETMAPPINGV2
730 HBA_API HBA_STATUS
HBA_GetBindingCapability(
733 HBA_BIND_CAPABILITY
*pcapability
736 HBA_API HBA_STATUS
HBA_GetBindingSupport(
739 HBA_BIND_CAPABILITY
*pcapability
742 HBA_API HBA_STATUS
HBA_SetBindingSupport(
745 HBA_BIND_CAPABILITY capability
748 HBA_API HBA_STATUS
HBA_SetPersistentBindingV2(
751 const HBA_FCPBINDING2
755 HBA_API HBA_STATUS
HBA_GetPersistentBindingV2(
758 HBA_FCPBINDING2
*binding
761 HBA_API HBA_STATUS
HBA_RemovePersistentBinding(
764 const HBA_FCPBINDING2
768 /* Depricated, but supported */
769 HBA_API HBA_STATUS
HBA_GetFcpPersistentBinding(
771 HBA_FCPBINDING
*binding
774 HBA_API HBA_STATUS
HBA_RemoveAllPersistentBindings(
779 HBA_STATUS
HBA_ScsiInquiryV2 (
782 HBA_WWN discoveredPortWWN
,
787 HBA_UINT32
*pRspBufferSize
,
788 HBA_UINT8
*pScsiStatus
,
790 HBA_UINT32
*pSenseBufferSize
793 /* Depricated, but supported */
794 HBA_API HBA_STATUS
HBA_SendScsiInquiry (
801 HBA_UINT32 RspBufferSize
,
803 HBA_UINT32 SenseBufferSize
806 HBA_API HBA_STATUS
HBA_ScsiReportLUNsV2(
809 HBA_WWN discoveredPortWWN
,
811 HBA_UINT32
*pRespBufferSize
,
812 HBA_UINT8
*pScsiStatus
,
814 HBA_UINT32
*pSenseBufferSize
817 /* Depricated, but supported */
818 HBA_API HBA_STATUS
HBA_SendReportLUNs (
822 HBA_UINT32 RspBufferSize
,
824 HBA_UINT32 SenseBufferSize
827 HBA_API HBA_STATUS
HBA_ScsiReadCapacityV2(
830 HBA_WWN discoveredPortWWN
,
833 HBA_UINT32
*pRspBufferSize
,
834 HBA_UINT8
*pScsiStatus
,
836 HBA_UINT32
*SenseBufferSize
839 /* Depricated, but supported */
840 HBA_API HBA_STATUS
HBA_SendReadCapacity (
845 HBA_UINT32 RspBufferSize
,
847 HBA_UINT32 SenseBufferSize
850 HBA_API HBA_UINT32
HBA_GetVendorLibraryAttributes (
851 HBA_UINT32 adapter_index
,
852 HBA_LIBRARYATTRIBUTES
856 HBA_API HBA_STATUS
HBA_RemoveCallback(
857 HBA_CALLBACKHANDLE callbackHandle
860 HBA_API HBA_STATUS
HBA_RegisterForAdapterAddEvents(
867 HBA_CALLBACKHANDLE
*callbackHandle
870 HBA_API HBA_STATUS
HBA_RegisterForAdapterEvents(
878 HBA_CALLBACKHANDLE
*callbackHandle
881 HBA_API HBA_STATUS
HBA_RegisterForAdapterPortEvents(
885 HBA_UINT32 eventType
,
886 HBA_UINT32 fabricPortID
891 HBA_CALLBACKHANDLE
*callbackHandle
894 HBA_API HBA_STATUS
HBA_RegisterForAdapterPortStatEvents(
903 HBA_PORTSTATISTICS stats
,
905 HBA_CALLBACKHANDLE
*callbackHandle
909 HBA_API HBA_STATUS
HBA_RegisterForTargetEvents(
913 HBA_WWN discoveredPortWWN
,
919 HBA_WWN discoveredPortWWN
,
920 HBA_CALLBACKHANDLE
*callbackHandle
,
921 HBA_UINT32 allTargets
924 HBA_API HBA_STATUS
HBA_RegisterForLinkEvents(
929 HBA_UINT32 eventType
,
931 HBA_UINT32 RLIRBufferSize
935 HBA_UINT32 RLIRBufferSize
,
937 HBA_CALLBACKHANDLE
*callbackHandle
940 /* Wrapper library specific entry points */
942 HBA_API HBA_UINT32
HBA_GetWrapperLibraryAttributes (
943 HBA_LIBRARYATTRIBUTES
947 #endif /* HBA_API_H */