Go to the documentation of this file.
6 #define nblank(x) _nblank(x)[0]
14 #ifndef AAC_DRIVER_BUILD
15 # define AAC_DRIVER_BUILD 29800
16 # define AAC_DRIVER_BRANCH "-ms"
18 #define MAXIMUM_NUM_CONTAINERS 32
20 #define AAC_NUM_MGT_FIB 8
21 #define AAC_NUM_IO_FIB (512 - AAC_NUM_MGT_FIB)
22 #define AAC_NUM_FIB (AAC_NUM_IO_FIB + AAC_NUM_MGT_FIB)
24 #define AAC_MAX_LUN (8)
26 #define AAC_MAX_HOSTPHYSMEMPAGES (0xfffff)
27 #define AAC_MAX_32BIT_SGBCOUNT ((unsigned short)256)
29 #define AAC_DEBUG_INSTRUMENT_AIF_DELETE
34 #define CONTAINER_CHANNEL (0)
35 #define CONTAINER_TO_CHANNEL(cont) (CONTAINER_CHANNEL)
36 #define CONTAINER_TO_ID(cont) (cont)
37 #define CONTAINER_TO_LUN(cont) (0)
39 #define aac_phys_to_logical(x) ((x)+1)
40 #define aac_logical_to_phys(x) ((x)?(x)-1:0)
178 #define NUMBER_OF_COMM_QUEUES 8 // 4 command; 4 response
179 #define HOST_HIGH_CMD_ENTRIES 4
180 #define HOST_NORM_CMD_ENTRIES 8
181 #define ADAP_HIGH_CMD_ENTRIES 4
182 #define ADAP_NORM_CMD_ENTRIES 512
183 #define HOST_HIGH_RESP_ENTRIES 4
184 #define HOST_NORM_RESP_ENTRIES 512
185 #define ADAP_HIGH_RESP_ENTRIES 4
186 #define ADAP_NORM_RESP_ENTRIES 8
188 #define TOTAL_QUEUE_ENTRIES \
189 (HOST_NORM_CMD_ENTRIES + HOST_HIGH_CMD_ENTRIES + ADAP_NORM_CMD_ENTRIES + ADAP_HIGH_CMD_ENTRIES + \
190 HOST_NORM_RESP_ENTRIES + HOST_HIGH_RESP_ENTRIES + ADAP_NORM_RESP_ENTRIES + ADAP_HIGH_RESP_ENTRIES)
197 #define QUEUE_ALIGNMENT 16
228 #define HostNormCmdQue 1
229 #define HostHighCmdQue 2
230 #define HostNormRespQue 3
231 #define HostHighRespQue 4
232 #define AdapNormRespNotFull 5
233 #define AdapHighRespNotFull 6
234 #define AdapNormCmdNotFull 7
235 #define AdapHighCmdNotFull 8
236 #define SynchCommandComplete 9
237 #define AdapInternalError 0xfe
245 #define AdapNormCmdQue 2
246 #define AdapHighCmdQue 3
247 #define AdapNormRespQue 6
248 #define AdapHighRespQue 7
249 #define HostShutdown 8
250 #define HostPowerFail 9
251 #define FatalCommError 10
252 #define HostNormRespNotFull 11
253 #define HostHighRespNotFull 12
254 #define HostNormCmdNotFull 13
255 #define HostHighCmdNotFull 14
257 #define AdapPrintfDone 16
279 #define FIB_MAGIC 0x0001
280 #define FIB_MAGIC2 0x0004
281 #define FIB_MAGIC2_64 0x0005
333 #define TestCommandResponse 1
334 #define TestAdapterCommand 2
338 #define LastTestCommand 100
339 #define ReinitHostNormCommandQueue 101
340 #define ReinitHostHighCommandQueue 102
341 #define ReinitHostHighRespQueue 103
342 #define ReinitHostNormRespQueue 104
343 #define ReinitAdapNormCommandQueue 105
344 #define ReinitAdapHighCommandQueue 107
345 #define ReinitAdapHighRespQueue 108
346 #define ReinitAdapNormRespQueue 109
347 #define InterfaceShutdown 110
348 #define DmaCommandFib 120
349 #define StartProfile 121
350 #define TermProfile 122
351 #define SpeedTest 123
352 #define TakeABreakPt 124
353 #define RequestPerfData 125
354 #define SetInterruptDefTimer 126
355 #define SetInterruptDefCount 127
356 #define GetInterruptDefStatus 128
357 #define LastCommCommand 129
361 #define NuFileSystem 300
363 #define HostFileSystem 302
364 #define LastFileSystemCommand 303
368 #define ContainerCommand 500
369 #define ContainerCommand64 501
370 #define ContainerRawIo 502
371 #define ContainerRawIo2 503
375 #define ScsiPortCommand 600
376 #define ScsiPortCommand64 601
380 #define AifRequest 700
381 #define CheckRevision 701
382 #define FsaHostShutdown 702
383 #define RequestAdapterInfo 703
384 #define IsAdapterPaused 704
385 #define SendHostTime 705
386 #define RequestSupplementAdapterInfo 706
387 #define LastMiscCommand 707
425 #define ADAPTER_INIT_STRUCT_REVISION 3
426 #define ADAPTER_INIT_STRUCT_REVISION_4 4 // rocket science
427 #define ADAPTER_INIT_STRUCT_REVISION_6 6
428 #define ADAPTER_INIT_STRUCT_REVISION_7 7
450 #define INITFLAGS_NEW_COMM_SUPPORTED 0x00000001
451 #define INITFLAGS_DRIVER_USES_UTC_TIME 0x00000010
452 #define INITFLAGS_DRIVER_SUPPORTS_PM 0x00000020
453 #define INITFLAGS_NEW_COMM_TYPE1_SUPPORTED 0x00000040
454 #define INITFLAGS_FAST_JBOD_SUPPORTED 0x00000080
455 #define INITFLAGS_NEW_COMM_TYPE2_SUPPORTED 0x00000100
478 #define FSAFS_NTC_GET_ADAPTER_FIB_CONTEXT 0x030b
479 #define FSAFS_NTC_FIB_CONTEXT 0x030c
492 int (*
adapter_sync_cmd)(
struct aac_dev *
dev,
u32 command,
u32 p1,
u32 p2,
u32 p3,
u32 p4,
u32 p5,
u32 p6,
u32 *
status,
u32 *
r1,
u32 *
r2,
u32 *
r3,
u32 *
r4);
527 #define AAC_QUIRK_31BIT 0x0001
534 #define AAC_QUIRK_34SG 0x0002
539 #define AAC_QUIRK_SLAVE 0x0004
544 #define AAC_QUIRK_MASTER 0x0008
551 #define AAC_QUIRK_17SG 0x0010
557 #define AAC_QUIRK_SCSI_32 0x0020
628 #define Mailbox0 SaDbCSR.MAILBOX0
629 #define Mailbox1 SaDbCSR.MAILBOX1
630 #define Mailbox2 SaDbCSR.MAILBOX2
631 #define Mailbox3 SaDbCSR.MAILBOX3
632 #define Mailbox4 SaDbCSR.MAILBOX4
633 #define Mailbox5 SaDbCSR.MAILBOX5
634 #define Mailbox6 SaDbCSR.MAILBOX6
635 #define Mailbox7 SaDbCSR.MAILBOX7
637 #define DoorbellReg_p SaDbCSR.PRISETIRQ
638 #define DoorbellReg_s SaDbCSR.SECSETIRQ
639 #define DoorbellClrReg_p SaDbCSR.PRICLEARIRQ
642 #define DOORBELL_0 0x0001
643 #define DOORBELL_1 0x0002
644 #define DOORBELL_2 0x0004
645 #define DOORBELL_3 0x0008
646 #define DOORBELL_4 0x0010
647 #define DOORBELL_5 0x0020
648 #define DOORBELL_6 0x0040
651 #define PrintfReady DOORBELL_5
652 #define PrintfDone DOORBELL_5
659 #define Sa_MINIPORT_REVISION 1
661 #define sa_readw(AEP, CSR) readl(&((AEP)->regs.sa->CSR))
662 #define sa_readl(AEP, CSR) readl(&((AEP)->regs.sa->CSR))
663 #define sa_writew(AEP, CSR, value) writew(value, &((AEP)->regs.sa->CSR))
664 #define sa_writel(AEP, CSR, value) writel(value, &((AEP)->regs.sa->CSR))
700 #define INBOUNDDOORBELL_0 0x00000001
701 #define INBOUNDDOORBELL_1 0x00000002
702 #define INBOUNDDOORBELL_2 0x00000004
703 #define INBOUNDDOORBELL_3 0x00000008
704 #define INBOUNDDOORBELL_4 0x00000010
705 #define INBOUNDDOORBELL_5 0x00000020
706 #define INBOUNDDOORBELL_6 0x00000040
708 #define OUTBOUNDDOORBELL_0 0x00000001
709 #define OUTBOUNDDOORBELL_1 0x00000002
710 #define OUTBOUNDDOORBELL_2 0x00000004
711 #define OUTBOUNDDOORBELL_3 0x00000008
712 #define OUTBOUNDDOORBELL_4 0x00000010
714 #define InboundDoorbellReg MUnit.IDR
715 #define OutboundDoorbellReg MUnit.ODR
723 #define rx_readb(AEP, CSR) readb(&((AEP)->regs.rx->CSR))
724 #define rx_readl(AEP, CSR) readl(&((AEP)->regs.rx->CSR))
725 #define rx_writeb(AEP, CSR, value) writeb(value, &((AEP)->regs.rx->CSR))
726 #define rx_writel(AEP, CSR, value) writel(value, &((AEP)->regs.rx->CSR))
732 #define rkt_mu_registers rx_mu_registers
733 #define rkt_inbound rx_inbound
741 #define rkt_readb(AEP, CSR) readb(&((AEP)->regs.rkt->CSR))
742 #define rkt_readl(AEP, CSR) readl(&((AEP)->regs.rkt->CSR))
743 #define rkt_writeb(AEP, CSR, value) writeb(value, &((AEP)->regs.rkt->CSR))
744 #define rkt_writel(AEP, CSR, value) writel(value, &((AEP)->regs.rkt->CSR))
750 #define src_inbound rx_inbound
782 #define src_readb(AEP, CSR) readb(&((AEP)->regs.src.bar0->CSR))
783 #define src_readl(AEP, CSR) readl(&((AEP)->regs.src.bar0->CSR))
784 #define src_writeb(AEP, CSR, value) writeb(value, \
785 &((AEP)->regs.src.bar0->CSR))
786 #define src_writel(AEP, CSR, value) writel(value, \
787 &((AEP)->regs.src.bar0->CSR))
789 #define SRC_ODR_SHIFT 12
790 #define SRC_IDR_SHIFT 9
952 #define AAC_FEATURE_FALCON cpu_to_le32(0x00000010)
953 #define AAC_FEATURE_JBOD cpu_to_le32(0x08000000)
955 #define AAC_OPTION_MU_RESET cpu_to_le32(0x00000001)
956 #define AAC_OPTION_IGNORE_RESET cpu_to_le32(0x00000002)
957 #define AAC_OPTION_POWER_MANAGEMENT cpu_to_le32(0x00000004)
958 #define AAC_OPTION_DOORBELL_RESET cpu_to_le32(0x00004000)
959 #define AAC_SIS_VERSION_V3 3
960 #define AAC_SIS_SLOT_UNKNOWN 0xFF
962 #define GetBusInfo 0x00000009
987 #define AAC_BAT_REQ_PRESENT (1)
988 #define AAC_BAT_REQ_NOTPRESENT (2)
989 #define AAC_BAT_OPT_PRESENT (3)
990 #define AAC_BAT_OPT_NOTPRESENT (4)
991 #define AAC_BAT_NOT_SUPPORTED (5)
995 #define AAC_CPU_SIMULATOR (1)
996 #define AAC_CPU_I960 (2)
997 #define AAC_CPU_STRONGARM (3)
1002 #define AAC_OPT_SNAPSHOT cpu_to_le32(1)
1003 #define AAC_OPT_CLUSTERS cpu_to_le32(1<<1)
1004 #define AAC_OPT_WRITE_CACHE cpu_to_le32(1<<2)
1005 #define AAC_OPT_64BIT_DATA cpu_to_le32(1<<3)
1006 #define AAC_OPT_HOST_TIME_FIB cpu_to_le32(1<<4)
1007 #define AAC_OPT_RAID50 cpu_to_le32(1<<5)
1008 #define AAC_OPT_4GB_WINDOW cpu_to_le32(1<<6)
1009 #define AAC_OPT_SCSI_UPGRADEABLE cpu_to_le32(1<<7)
1010 #define AAC_OPT_SOFT_ERR_REPORT cpu_to_le32(1<<8)
1011 #define AAC_OPT_SUPPORTED_RECONDITION cpu_to_le32(1<<9)
1012 #define AAC_OPT_SGMAP_HOST64 cpu_to_le32(1<<10)
1013 #define AAC_OPT_ALARM cpu_to_le32(1<<11)
1014 #define AAC_OPT_NONDASD cpu_to_le32(1<<12)
1015 #define AAC_OPT_SCSI_MANAGED cpu_to_le32(1<<13)
1016 #define AAC_OPT_RAID_SCSI_MODE cpu_to_le32(1<<14)
1017 #define AAC_OPT_SUPPLEMENT_ADAPTER_INFO cpu_to_le32(1<<16)
1018 #define AAC_OPT_NEW_COMM cpu_to_le32(1<<17)
1019 #define AAC_OPT_NEW_COMM_64 cpu_to_le32(1<<18)
1020 #define AAC_OPT_NEW_COMM_TYPE1 cpu_to_le32(1<<28)
1021 #define AAC_OPT_NEW_COMM_TYPE2 cpu_to_le32(1<<29)
1022 #define AAC_OPT_NEW_COMM_TYPE3 cpu_to_le32(1<<30)
1023 #define AAC_OPT_NEW_COMM_TYPE4 cpu_to_le32(1<<31)
1099 #ifndef AAC_MIN_FOOTPRINT_SIZE
1100 # define AAC_MIN_FOOTPRINT_SIZE 8192
1101 # define AAC_MIN_SRC_BAR0_SIZE 0x400000
1102 # define AAC_MIN_SRC_BAR1_SIZE 0x800
1103 # define AAC_MIN_SRCV_BAR0_SIZE 0x100000
1104 # define AAC_MIN_SRCV_BAR1_SIZE 0x400
1135 # define AAC_COMM_PRODUCER 0
1136 # define AAC_COMM_MESSAGE 1
1137 # define AAC_COMM_MESSAGE_TYPE1 3
1138 # define AAC_COMM_MESSAGE_TYPE2 4
1152 #define aac_adapter_interrupt(dev) \
1153 (dev)->a_ops.adapter_interrupt(dev)
1155 #define aac_adapter_notify(dev, event) \
1156 (dev)->a_ops.adapter_notify(dev, event)
1158 #define aac_adapter_disable_int(dev) \
1159 (dev)->a_ops.adapter_disable_int(dev)
1161 #define aac_adapter_enable_int(dev) \
1162 (dev)->a_ops.adapter_enable_int(dev)
1164 #define aac_adapter_sync_cmd(dev, command, p1, p2, p3, p4, p5, p6, status, r1, r2, r3, r4) \
1165 (dev)->a_ops.adapter_sync_cmd(dev, command, p1, p2, p3, p4, p5, p6, status, r1, r2, r3, r4)
1167 #define aac_adapter_check_health(dev) \
1168 (dev)->a_ops.adapter_check_health(dev)
1170 #define aac_adapter_restart(dev,bled) \
1171 (dev)->a_ops.adapter_restart(dev,bled)
1173 #define aac_adapter_ioremap(dev, size) \
1174 (dev)->a_ops.adapter_ioremap(dev, size)
1176 #define aac_adapter_deliver(fib) \
1177 ((fib)->dev)->a_ops.adapter_deliver(fib)
1179 #define aac_adapter_bounds(dev,cmd,lba) \
1180 dev->a_ops.adapter_bounds(dev,cmd,lba)
1182 #define aac_adapter_read(fib,cmd,lba,count) \
1183 ((fib)->dev)->a_ops.adapter_read(fib,cmd,lba,count)
1185 #define aac_adapter_write(fib,cmd,lba,count,fua) \
1186 ((fib)->dev)->a_ops.adapter_write(fib,cmd,lba,count,fua)
1188 #define aac_adapter_scsi(fib,cmd) \
1189 ((fib)->dev)->a_ops.adapter_scsi(fib,cmd)
1191 #define aac_adapter_comm(dev,comm) \
1192 (dev)->a_ops.adapter_comm(dev, comm)
1194 #define FIB_CONTEXT_FLAG_TIMED_OUT (0x00000001)
1195 #define FIB_CONTEXT_FLAG (0x00000002)
1196 #define FIB_CONTEXT_FLAG_WAIT (0x00000004)
1197 #define FIB_CONTEXT_FLAG_FASTRESP (0x00000008)
1204 #define GetAttributes 1
1205 #define SetAttributes 2
1211 #define MakeDirectory 8
1212 #define SymbolicLink 9
1215 #define RemoveDirectoryx 12
1218 #define ReadDirectory 15
1219 #define ReadDirectoryPlus 16
1220 #define FileSystemStatus 17
1221 #define FileSystemInfo 18
1222 #define PathConfigure 19
1229 #define SimReadWrite 26
1230 #define SetFileSystemStatus 27
1231 #define BlockRead 28
1232 #define BlockWrite 29
1233 #define NvramIoctl 30
1234 #define FsSyncWait 31
1235 #define ClearArchiveBit 32
1238 #define AssignAcl 35
1239 #define FaultInsertion 36
1240 #define CrazyCache 37
1242 #define MAX_FSACOMMAND_NUM 38
1260 #define ST_NOTDIR 20
1267 #define ST_WOULDBLOCK 35
1268 #define ST_NAMETOOLONG 63
1269 #define ST_NOTEMPTY 66
1272 #define ST_REMOTE 71
1273 #define ST_NOT_READY 72
1274 #define ST_BADHANDLE 10001
1275 #define ST_NOT_SYNC 10002
1276 #define ST_BAD_COOKIE 10003
1277 #define ST_NOTSUPP 10004
1278 #define ST_TOOSMALL 10005
1279 #define ST_SERVERFAULT 10006
1280 #define ST_BADTYPE 10007
1281 #define ST_JUKEBOX 10008
1282 #define ST_NOTMOUNTED 10009
1283 #define ST_MAINTMODE 10010
1284 #define ST_STALEACL 10011
1290 #define CACHE_CSTABLE 1
1291 #define CACHE_UNSTABLE 2
1298 #define CMFILE_SYNCH_NVRAM 1
1299 #define CMDATA_SYNCH_NVRAM 2
1300 #define CMFILE_SYNCH 3
1301 #define CMDATA_SYNCH 4
1302 #define CMUNSTABLE 5
1304 #define RIO_TYPE_WRITE 0x0000
1305 #define RIO_TYPE_READ 0x0001
1306 #define RIO_SUREWRITE 0x0008
1308 #define RIO2_IO_TYPE 0x0003
1309 #define RIO2_IO_TYPE_WRITE 0x0000
1310 #define RIO2_IO_TYPE_READ 0x0001
1311 #define RIO2_IO_TYPE_VERIFY 0x0002
1312 #define RIO2_IO_ERROR 0x0004
1313 #define RIO2_IO_SUREWRITE 0x0008
1314 #define RIO2_SGL_CONFORMANT 0x0010
1315 #define RIO2_SG_FORMAT 0xF000
1316 #define RIO2_SG_FORMAT_ARC 0x0000
1317 #define RIO2_SG_FORMAT_SRL 0x1000
1318 #define RIO2_SG_FORMAT_IEEE1212 0x2000
1400 #define CT_FLUSH_CACHE 129
1424 #define CT_POWER_MANAGEMENT 245
1425 #define CT_PM_START_UNIT 2
1426 #define CT_PM_STOP_UNIT 3
1427 #define CT_PM_UNIT_IMMEDIATE 1
1436 #define CT_PAUSE_IO 65
1437 #define CT_RELEASE_IO 66
1483 #define AAC_SENSE_BUFFERSIZE 30
1497 #define SRB_NoDataXfer 0x0000
1498 #define SRB_DisableDisconnect 0x0004
1499 #define SRB_DisableSynchTransfer 0x0008
1500 #define SRB_BypassFrozenQueue 0x0010
1501 #define SRB_DisableAutosense 0x0020
1502 #define SRB_DataIn 0x0040
1503 #define SRB_DataOut 0x0080
1508 #define SRBF_ExecuteScsi 0x0000
1509 #define SRBF_ClaimDevice 0x0001
1510 #define SRBF_IO_Control 0x0002
1511 #define SRBF_ReceiveEvent 0x0003
1512 #define SRBF_ReleaseQueue 0x0004
1513 #define SRBF_AttachDevice 0x0005
1514 #define SRBF_ReleaseDevice 0x0006
1515 #define SRBF_Shutdown 0x0007
1516 #define SRBF_Flush 0x0008
1517 #define SRBF_AbortCommand 0x0010
1518 #define SRBF_ReleaseRecovery 0x0011
1519 #define SRBF_ResetBus 0x0012
1520 #define SRBF_ResetDevice 0x0013
1521 #define SRBF_TerminateIO 0x0014
1522 #define SRBF_FlushQueue 0x0015
1523 #define SRBF_RemoveDevice 0x0016
1524 #define SRBF_DomainValidation 0x0017
1529 #define SRB_STATUS_PENDING 0x00
1530 #define SRB_STATUS_SUCCESS 0x01
1531 #define SRB_STATUS_ABORTED 0x02
1532 #define SRB_STATUS_ABORT_FAILED 0x03
1533 #define SRB_STATUS_ERROR 0x04
1534 #define SRB_STATUS_BUSY 0x05
1535 #define SRB_STATUS_INVALID_REQUEST 0x06
1536 #define SRB_STATUS_INVALID_PATH_ID 0x07
1537 #define SRB_STATUS_NO_DEVICE 0x08
1538 #define SRB_STATUS_TIMEOUT 0x09
1539 #define SRB_STATUS_SELECTION_TIMEOUT 0x0A
1540 #define SRB_STATUS_COMMAND_TIMEOUT 0x0B
1541 #define SRB_STATUS_MESSAGE_REJECTED 0x0D
1542 #define SRB_STATUS_BUS_RESET 0x0E
1543 #define SRB_STATUS_PARITY_ERROR 0x0F
1544 #define SRB_STATUS_REQUEST_SENSE_FAILED 0x10
1545 #define SRB_STATUS_NO_HBA 0x11
1546 #define SRB_STATUS_DATA_OVERRUN 0x12
1547 #define SRB_STATUS_UNEXPECTED_BUS_FREE 0x13
1548 #define SRB_STATUS_PHASE_SEQUENCE_FAILURE 0x14
1549 #define SRB_STATUS_BAD_SRB_BLOCK_LENGTH 0x15
1550 #define SRB_STATUS_REQUEST_FLUSHED 0x16
1551 #define SRB_STATUS_DELAYED_RETRY 0x17
1552 #define SRB_STATUS_INVALID_LUN 0x20
1553 #define SRB_STATUS_INVALID_TARGET_ID 0x21
1554 #define SRB_STATUS_BAD_FUNCTION 0x22
1555 #define SRB_STATUS_ERROR_RECOVERY 0x23
1556 #define SRB_STATUS_NOT_STARTED 0x24
1557 #define SRB_STATUS_NOT_IN_USE 0x30
1558 #define SRB_STATUS_FORCE_ABORT 0x31
1559 #define SRB_STATUS_DOMAIN_VALIDATION_FAIL 0x32
1566 #define VM_NameServe 1
1567 #define VM_ContainerConfig 2
1569 #define VM_FilesystemIoctl 4
1570 #define VM_CloseAll 5
1571 #define VM_CtBlockRead 6
1572 #define VM_CtBlockWrite 7
1573 #define VM_SliceBlockRead 8
1574 #define VM_SliceBlockWrite 9
1575 #define VM_DriveBlockRead 10
1576 #define VM_DriveBlockWrite 11
1577 #define VM_EnclosureMgt 12
1578 #define VM_Unused 13
1579 #define VM_CtBlockVerify 14
1580 #define VM_CtPerf 15
1581 #define VM_CtBlockRead64 16
1582 #define VM_CtBlockWrite64 17
1583 #define VM_CtBlockVerify64 18
1584 #define VM_CtHostRead64 19
1585 #define VM_CtHostWrite64 20
1586 #define VM_DrvErrTblLog 21
1587 #define VM_NameServe64 22
1589 #define MAX_VMCOMMAND_NUM 23
1618 #define CT_GET_CONFIG_STATUS 147
1630 #define CFACT_CONTINUE 0
1631 #define CFACT_PAUSE 1
1632 #define CFACT_ABORT 2
1653 #define CT_COMMIT_CONFIG 152
1664 #define CT_GET_CONTAINER_COUNT 4
1700 #define FSCS_NOTCLEAN 0x0001
1701 #define FSCS_READONLY 0x0002
1702 #define FSCS_HIDDEN 0x0004
1703 #define FSCS_NOT_READY 0x0008
1718 #define CT_READ_NAME 130
1742 #define CT_CID_TO_32BITS_UID 165
1803 #define CTL_CODE(function, method) ( \
1804 (4<< 16) | ((function) << 2) | (method) \
1812 #define METHOD_BUFFERED 0
1813 #define METHOD_NEITHER 3
1819 #define FSACTL_SENDFIB CTL_CODE(2050, METHOD_BUFFERED)
1820 #define FSACTL_SEND_RAW_SRB CTL_CODE(2067, METHOD_BUFFERED)
1821 #define FSACTL_DELETE_DISK 0x163
1822 #define FSACTL_QUERY_DISK 0x173
1823 #define FSACTL_OPEN_GET_ADAPTER_FIB CTL_CODE(2100, METHOD_BUFFERED)
1824 #define FSACTL_GET_NEXT_ADAPTER_FIB CTL_CODE(2101, METHOD_BUFFERED)
1825 #define FSACTL_CLOSE_GET_ADAPTER_FIB CTL_CODE(2102, METHOD_BUFFERED)
1826 #define FSACTL_MINIPORT_REV_CHECK CTL_CODE(2107, METHOD_BUFFERED)
1827 #define FSACTL_GET_PCI_INFO CTL_CODE(2119, METHOD_BUFFERED)
1828 #define FSACTL_FORCE_DELETE_DISK CTL_CODE(2120, METHOD_NEITHER)
1829 #define FSACTL_GET_CONTAINERS 2131
1830 #define FSACTL_SEND_LARGE_FIB CTL_CODE(2138, METHOD_BUFFERED)
1850 u32 NoResponseRecved;
1867 #define FIB_COUNTER_INCREMENT(counter) (counter)++
1869 #define FIB_COUNTER_INCREMENT(counter)
1877 #define BREAKPOINT_REQUEST 0x00000004
1878 #define INIT_STRUCT_BASE_ADDRESS 0x00000005
1879 #define READ_PERMANENT_PARAMETERS 0x0000000a
1880 #define WRITE_PERMANENT_PARAMETERS 0x0000000b
1881 #define HOST_CRASHING 0x0000000d
1882 #define SEND_SYNCHRONOUS_FIB 0x0000000c
1883 #define COMMAND_POST_RESULTS 0x00000014
1884 #define GET_ADAPTER_PROPERTIES 0x00000019
1885 #define GET_DRIVER_BUFFER_PROPERTIES 0x00000023
1886 #define RCV_TEMP_READINGS 0x00000025
1887 #define GET_COMM_PREFERRED_SETTINGS 0x00000026
1888 #define IOP_RESET 0x00001000
1889 #define IOP_RESET_ALWAYS 0x00001001
1890 #define RE_INIT_ADAPTER 0x000000ee
1913 #define SELF_TEST_FAILED 0x00000004
1914 #define MONITOR_PANIC 0x00000020
1915 #define KERNEL_UP_AND_RUNNING 0x00000080
1916 #define KERNEL_PANIC 0x00000100
1922 #define DoorBellSyncCmdAvailable (1<<0)
1923 #define DoorBellPrintfDone (1<<5)
1924 #define DoorBellAdapterNormCmdReady (1<<1)
1925 #define DoorBellAdapterNormRespReady (1<<2)
1926 #define DoorBellAdapterNormCmdNotFull (1<<3)
1927 #define DoorBellAdapterNormRespNotFull (1<<4)
1928 #define DoorBellPrintfReady (1<<5)
1929 #define DoorBellAifPending (1<<6)
1932 #define PmDoorBellResponseSent (1<<1)
1939 #define AifCmdEventNotify 1
1940 #define AifEnConfigChange 3
1941 #define AifEnContainerChange 4
1942 #define AifEnDeviceFailure 5
1943 #define AifEnEnclosureManagement 13
1944 #define EM_DRIVE_INSERTION 31
1945 #define EM_DRIVE_REMOVAL 32
1946 #define AifEnBatteryEvent 14
1947 #define AifEnAddContainer 15
1948 #define AifEnDeleteContainer 16
1949 #define AifEnExpEvent 23
1950 #define AifExeFirmwarePanic 3
1951 #define AifHighPriority 3
1952 #define AifEnAddJBOD 30
1953 #define AifEnDeleteJBOD 31
1955 #define AifCmdJobProgress 2
1956 #define AifJobCtrZero 101
1957 #define AifJobStsSuccess 1
1958 #define AifJobStsRunning 102
1959 #define AifCmdAPIReport 3
1960 #define AifCmdDriverNotify 4
1961 #define AifDenMorphComplete 200
1962 #define AifDenVolumeExtendComplete 201
1963 #define AifReqJobList 100
1964 #define AifReqJobsForCtr 101
1965 #define AifReqJobsForScsi 102
1966 #define AifReqJobReport 103
1967 #define AifReqTerminateJob 104
1968 #define AifReqSuspendJob 105
1969 #define AifReqResumeJob 106
1970 #define AifReqSendAPIReport 107
1971 #define AifReqAPIJobStart 108
1972 #define AifReqAPIJobUpdate 109
1973 #define AifReqAPIJobFinish 110
1976 #define AifReqEvent 200
2002 #define AAC_OWNER_MIDLEVEL 0x101
2003 #define AAC_OWNER_LOWLEVEL 0x102
2004 #define AAC_OWNER_ERROR_HANDLER 0x103
2005 #define AAC_OWNER_FIRMWARE 0x106
2018 #define fib_data(fibctx) ((void *)(fibctx)->hw_fib_va->data)
2024 #ifndef shost_to_class
2025 #define shost_to_class(shost) &shost->shost_dev
2039 int isAif,
int isFastResponse,