Lines Matching refs:Command
318 DAC960_Command_T *Command; in DAC960_CreateAuxiliaryStructures() local
332 Command = (DAC960_Command_T *) AllocationPointer; in DAC960_CreateAuxiliaryStructures()
334 Command->CommandIdentifier = CommandIdentifier; in DAC960_CreateAuxiliaryStructures()
335 Command->Controller = Controller; in DAC960_CreateAuxiliaryStructures()
336 Command->Next = Controller->FreeCommands; in DAC960_CreateAuxiliaryStructures()
337 Controller->FreeCommands = Command; in DAC960_CreateAuxiliaryStructures()
338 Controller->Commands[CommandIdentifier-1] = Command; in DAC960_CreateAuxiliaryStructures()
355 Command->cmd_sglist = Command->V1.ScatterList; in DAC960_CreateAuxiliaryStructures()
356 Command->V1.ScatterGatherList = in DAC960_CreateAuxiliaryStructures()
358 Command->V1.ScatterGatherListDMA = ScatterGatherDMA; in DAC960_CreateAuxiliaryStructures()
359 sg_init_table(Command->cmd_sglist, DAC960_V1_ScatterGatherLimit); in DAC960_CreateAuxiliaryStructures()
361 Command->cmd_sglist = Command->V2.ScatterList; in DAC960_CreateAuxiliaryStructures()
362 Command->V2.ScatterGatherList = in DAC960_CreateAuxiliaryStructures()
364 Command->V2.ScatterGatherListDMA = ScatterGatherDMA; in DAC960_CreateAuxiliaryStructures()
365 Command->V2.RequestSense = in DAC960_CreateAuxiliaryStructures()
367 Command->V2.RequestSenseDMA = RequestSenseDMA; in DAC960_CreateAuxiliaryStructures()
368 sg_init_table(Command->cmd_sglist, DAC960_V2_ScatterGatherLimit); in DAC960_CreateAuxiliaryStructures()
398 DAC960_Command_T *Command = Controller->Commands[i]; in DAC960_DestroyAuxiliaryStructures() local
400 if (Command == NULL) in DAC960_DestroyAuxiliaryStructures()
404 ScatterGatherCPU = (void *)Command->V1.ScatterGatherList; in DAC960_DestroyAuxiliaryStructures()
405 ScatterGatherDMA = Command->V1.ScatterGatherListDMA; in DAC960_DestroyAuxiliaryStructures()
409 ScatterGatherCPU = (void *)Command->V2.ScatterGatherList; in DAC960_DestroyAuxiliaryStructures()
410 ScatterGatherDMA = Command->V2.ScatterGatherListDMA; in DAC960_DestroyAuxiliaryStructures()
411 RequestSenseCPU = (void *)Command->V2.RequestSense; in DAC960_DestroyAuxiliaryStructures()
412 RequestSenseDMA = Command->V2.RequestSenseDMA; in DAC960_DestroyAuxiliaryStructures()
419 if ((Command->CommandIdentifier in DAC960_DestroyAuxiliaryStructures()
428 CommandGroup = Command; in DAC960_DestroyAuxiliaryStructures()
467 static inline void DAC960_V1_ClearCommand(DAC960_Command_T *Command) in DAC960_V1_ClearCommand() argument
469 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_V1_ClearCommand()
471 Command->V1.CommandStatus = 0; in DAC960_V1_ClearCommand()
480 static inline void DAC960_V2_ClearCommand(DAC960_Command_T *Command) in DAC960_V2_ClearCommand() argument
482 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_ClearCommand()
484 Command->V2.CommandStatus = 0; in DAC960_V2_ClearCommand()
498 DAC960_Command_T *Command = Controller->FreeCommands; in DAC960_AllocateCommand() local
499 if (Command == NULL) return NULL; in DAC960_AllocateCommand()
500 Controller->FreeCommands = Command->Next; in DAC960_AllocateCommand()
501 Command->Next = NULL; in DAC960_AllocateCommand()
502 return Command; in DAC960_AllocateCommand()
511 static inline void DAC960_DeallocateCommand(DAC960_Command_T *Command) in DAC960_DeallocateCommand() argument
513 DAC960_Controller_T *Controller = Command->Controller; in DAC960_DeallocateCommand()
515 Command->Request = NULL; in DAC960_DeallocateCommand()
516 Command->Next = Controller->FreeCommands; in DAC960_DeallocateCommand()
517 Controller->FreeCommands = Command; in DAC960_DeallocateCommand()
536 static void DAC960_GEM_QueueCommand(DAC960_Command_T *Command) in DAC960_GEM_QueueCommand() argument
538 DAC960_Controller_T *Controller = Command->Controller; in DAC960_GEM_QueueCommand()
540 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_GEM_QueueCommand()
544 CommandMailbox->Common.CommandIdentifier = Command->CommandIdentifier; in DAC960_GEM_QueueCommand()
565 static void DAC960_BA_QueueCommand(DAC960_Command_T *Command) in DAC960_BA_QueueCommand() argument
567 DAC960_Controller_T *Controller = Command->Controller; in DAC960_BA_QueueCommand()
569 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_BA_QueueCommand()
572 CommandMailbox->Common.CommandIdentifier = Command->CommandIdentifier; in DAC960_BA_QueueCommand()
590 static void DAC960_LP_QueueCommand(DAC960_Command_T *Command) in DAC960_LP_QueueCommand() argument
592 DAC960_Controller_T *Controller = Command->Controller; in DAC960_LP_QueueCommand()
594 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_LP_QueueCommand()
597 CommandMailbox->Common.CommandIdentifier = Command->CommandIdentifier; in DAC960_LP_QueueCommand()
616 static void DAC960_LA_QueueCommandDualMode(DAC960_Command_T *Command) in DAC960_LA_QueueCommandDualMode() argument
618 DAC960_Controller_T *Controller = Command->Controller; in DAC960_LA_QueueCommandDualMode()
620 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_LA_QueueCommandDualMode()
623 CommandMailbox->Common.CommandIdentifier = Command->CommandIdentifier; in DAC960_LA_QueueCommandDualMode()
642 static void DAC960_LA_QueueCommandSingleMode(DAC960_Command_T *Command) in DAC960_LA_QueueCommandSingleMode() argument
644 DAC960_Controller_T *Controller = Command->Controller; in DAC960_LA_QueueCommandSingleMode()
646 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_LA_QueueCommandSingleMode()
649 CommandMailbox->Common.CommandIdentifier = Command->CommandIdentifier; in DAC960_LA_QueueCommandSingleMode()
668 static void DAC960_PG_QueueCommandDualMode(DAC960_Command_T *Command) in DAC960_PG_QueueCommandDualMode() argument
670 DAC960_Controller_T *Controller = Command->Controller; in DAC960_PG_QueueCommandDualMode()
672 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_PG_QueueCommandDualMode()
675 CommandMailbox->Common.CommandIdentifier = Command->CommandIdentifier; in DAC960_PG_QueueCommandDualMode()
694 static void DAC960_PG_QueueCommandSingleMode(DAC960_Command_T *Command) in DAC960_PG_QueueCommandSingleMode() argument
696 DAC960_Controller_T *Controller = Command->Controller; in DAC960_PG_QueueCommandSingleMode()
698 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_PG_QueueCommandSingleMode()
701 CommandMailbox->Common.CommandIdentifier = Command->CommandIdentifier; in DAC960_PG_QueueCommandSingleMode()
719 static void DAC960_PD_QueueCommand(DAC960_Command_T *Command) in DAC960_PD_QueueCommand() argument
721 DAC960_Controller_T *Controller = Command->Controller; in DAC960_PD_QueueCommand()
723 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_PD_QueueCommand()
724 CommandMailbox->Common.CommandIdentifier = Command->CommandIdentifier; in DAC960_PD_QueueCommand()
736 static void DAC960_P_QueueCommand(DAC960_Command_T *Command) in DAC960_P_QueueCommand() argument
738 DAC960_Controller_T *Controller = Command->Controller; in DAC960_P_QueueCommand()
740 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_P_QueueCommand()
741 CommandMailbox->Common.CommandIdentifier = Command->CommandIdentifier; in DAC960_P_QueueCommand()
782 static void DAC960_ExecuteCommand(DAC960_Command_T *Command) in DAC960_ExecuteCommand() argument
784 DAC960_Controller_T *Controller = Command->Controller; in DAC960_ExecuteCommand()
787 Command->Completion = &Completion; in DAC960_ExecuteCommand()
790 DAC960_QueueCommand(Command); in DAC960_ExecuteCommand()
809 DAC960_Command_T *Command = DAC960_AllocateCommand(Controller); in DAC960_V1_ExecuteType3() local
810 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_V1_ExecuteType3()
812 DAC960_V1_ClearCommand(Command); in DAC960_V1_ExecuteType3()
813 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V1_ExecuteType3()
816 DAC960_ExecuteCommand(Command); in DAC960_V1_ExecuteType3()
817 CommandStatus = Command->V1.CommandStatus; in DAC960_V1_ExecuteType3()
818 DAC960_DeallocateCommand(Command); in DAC960_V1_ExecuteType3()
834 DAC960_Command_T *Command = DAC960_AllocateCommand(Controller); in DAC960_V1_ExecuteType3B() local
835 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_V1_ExecuteType3B()
837 DAC960_V1_ClearCommand(Command); in DAC960_V1_ExecuteType3B()
838 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V1_ExecuteType3B()
842 DAC960_ExecuteCommand(Command); in DAC960_V1_ExecuteType3B()
843 CommandStatus = Command->V1.CommandStatus; in DAC960_V1_ExecuteType3B()
844 DAC960_DeallocateCommand(Command); in DAC960_V1_ExecuteType3B()
861 DAC960_Command_T *Command = DAC960_AllocateCommand(Controller); in DAC960_V1_ExecuteType3D() local
862 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_V1_ExecuteType3D()
864 DAC960_V1_ClearCommand(Command); in DAC960_V1_ExecuteType3D()
865 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V1_ExecuteType3D()
870 DAC960_ExecuteCommand(Command); in DAC960_V1_ExecuteType3D()
871 CommandStatus = Command->V1.CommandStatus; in DAC960_V1_ExecuteType3D()
872 DAC960_DeallocateCommand(Command); in DAC960_V1_ExecuteType3D()
887 DAC960_Command_T *Command = DAC960_AllocateCommand(Controller); in DAC960_V2_GeneralInfo() local
888 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_GeneralInfo()
890 DAC960_V2_ClearCommand(Command); in DAC960_V2_GeneralInfo()
891 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V2_GeneralInfo()
907 DAC960_ExecuteCommand(Command); in DAC960_V2_GeneralInfo()
908 CommandStatus = Command->V2.CommandStatus; in DAC960_V2_GeneralInfo()
909 DAC960_DeallocateCommand(Command); in DAC960_V2_GeneralInfo()
925 DAC960_Command_T *Command = DAC960_AllocateCommand(Controller); in DAC960_V2_NewControllerInfo() local
926 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_NewControllerInfo()
928 DAC960_V2_ClearCommand(Command); in DAC960_V2_NewControllerInfo()
929 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V2_NewControllerInfo()
946 DAC960_ExecuteCommand(Command); in DAC960_V2_NewControllerInfo()
947 CommandStatus = Command->V2.CommandStatus; in DAC960_V2_NewControllerInfo()
948 DAC960_DeallocateCommand(Command); in DAC960_V2_NewControllerInfo()
964 DAC960_Command_T *Command = DAC960_AllocateCommand(Controller); in DAC960_V2_NewLogicalDeviceInfo() local
965 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_NewLogicalDeviceInfo()
968 DAC960_V2_ClearCommand(Command); in DAC960_V2_NewLogicalDeviceInfo()
969 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V2_NewLogicalDeviceInfo()
989 DAC960_ExecuteCommand(Command); in DAC960_V2_NewLogicalDeviceInfo()
990 CommandStatus = Command->V2.CommandStatus; in DAC960_V2_NewLogicalDeviceInfo()
991 DAC960_DeallocateCommand(Command); in DAC960_V2_NewLogicalDeviceInfo()
1017 DAC960_Command_T *Command = DAC960_AllocateCommand(Controller); in DAC960_V2_NewPhysicalDeviceInfo() local
1018 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_NewPhysicalDeviceInfo()
1021 DAC960_V2_ClearCommand(Command); in DAC960_V2_NewPhysicalDeviceInfo()
1022 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V2_NewPhysicalDeviceInfo()
1043 DAC960_ExecuteCommand(Command); in DAC960_V2_NewPhysicalDeviceInfo()
1044 CommandStatus = Command->V2.CommandStatus; in DAC960_V2_NewPhysicalDeviceInfo()
1045 DAC960_DeallocateCommand(Command); in DAC960_V2_NewPhysicalDeviceInfo()
1100 DAC960_Command_T *Command; in DAC960_V2_NewInquiryUnitSerialNumber() local
1104 Command = DAC960_AllocateCommand(Controller); in DAC960_V2_NewInquiryUnitSerialNumber()
1105 CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_NewInquiryUnitSerialNumber()
1106 DAC960_V2_ClearCommand(Command); in DAC960_V2_NewInquiryUnitSerialNumber()
1107 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V2_NewInquiryUnitSerialNumber()
1112 DAC960_ExecuteCommand(Command); in DAC960_V2_NewInquiryUnitSerialNumber()
1113 CommandStatus = Command->V2.CommandStatus; in DAC960_V2_NewInquiryUnitSerialNumber()
1114 DAC960_DeallocateCommand(Command); in DAC960_V2_NewInquiryUnitSerialNumber()
1130 DAC960_Command_T *Command = DAC960_AllocateCommand(Controller); in DAC960_V2_DeviceOperation() local
1131 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_DeviceOperation()
1133 DAC960_V2_ClearCommand(Command); in DAC960_V2_DeviceOperation()
1134 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V2_DeviceOperation()
1142 DAC960_ExecuteCommand(Command); in DAC960_V2_DeviceOperation()
1143 CommandStatus = Command->V2.CommandStatus; in DAC960_V2_DeviceOperation()
1144 DAC960_DeallocateCommand(Command); in DAC960_V2_DeviceOperation()
2013 DAC960_Command_T *Command = Controller->Commands[Channel]; in DAC960_V1_ReadDeviceConfiguration() local
2017 DAC960_V1_ClearCommand(Command); in DAC960_V1_ReadDeviceConfiguration()
2018 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V1_ReadDeviceConfiguration()
2019 Command->Completion = Completion; in DAC960_V1_ReadDeviceConfiguration()
2020 Command->V1.CommandMailbox.Type3.CommandOpcode = DAC960_V1_DCDB; in DAC960_V1_ReadDeviceConfiguration()
2021 Command->V1.CommandMailbox.Type3.BusAddress = DCDB_dma; in DAC960_V1_ReadDeviceConfiguration()
2042 DAC960_QueueCommand(Command); in DAC960_V1_ReadDeviceConfiguration()
2061 DAC960_Command_T *Command = Controller->Commands[Channel]; in DAC960_V1_ReadDeviceConfiguration() local
2067 if (Command->V1.CommandStatus != DAC960_V1_NormalCompletion) { in DAC960_V1_ReadDeviceConfiguration()
2075 Command->Completion = Completion; in DAC960_V1_ReadDeviceConfiguration()
2087 DAC960_QueueCommand(Command); in DAC960_V1_ReadDeviceConfiguration()
2091 if (Command->V1.CommandStatus != DAC960_V1_NormalCompletion) { in DAC960_V1_ReadDeviceConfiguration()
3203 static void DAC960_V1_QueueReadWriteCommand(DAC960_Command_T *Command) in DAC960_V1_QueueReadWriteCommand() argument
3205 DAC960_Controller_T *Controller = Command->Controller; in DAC960_V1_QueueReadWriteCommand()
3206 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_V1_QueueReadWriteCommand()
3208 Command->V1.ScatterGatherList; in DAC960_V1_QueueReadWriteCommand()
3209 struct scatterlist *ScatterList = Command->V1.ScatterList; in DAC960_V1_QueueReadWriteCommand()
3211 DAC960_V1_ClearCommand(Command); in DAC960_V1_QueueReadWriteCommand()
3213 if (Command->SegmentCount == 1) in DAC960_V1_QueueReadWriteCommand()
3215 if (Command->DmaDirection == PCI_DMA_FROMDEVICE) in DAC960_V1_QueueReadWriteCommand()
3220 CommandMailbox->Type5.LD.TransferLength = Command->BlockCount; in DAC960_V1_QueueReadWriteCommand()
3221 CommandMailbox->Type5.LD.LogicalDriveNumber = Command->LogicalDriveNumber; in DAC960_V1_QueueReadWriteCommand()
3222 CommandMailbox->Type5.LogicalBlockAddress = Command->BlockNumber; in DAC960_V1_QueueReadWriteCommand()
3230 if (Command->DmaDirection == PCI_DMA_FROMDEVICE) in DAC960_V1_QueueReadWriteCommand()
3235 CommandMailbox->Type5.LD.TransferLength = Command->BlockCount; in DAC960_V1_QueueReadWriteCommand()
3236 CommandMailbox->Type5.LD.LogicalDriveNumber = Command->LogicalDriveNumber; in DAC960_V1_QueueReadWriteCommand()
3237 CommandMailbox->Type5.LogicalBlockAddress = Command->BlockNumber; in DAC960_V1_QueueReadWriteCommand()
3238 CommandMailbox->Type5.BusAddress = Command->V1.ScatterGatherListDMA; in DAC960_V1_QueueReadWriteCommand()
3240 CommandMailbox->Type5.ScatterGatherCount = Command->SegmentCount; in DAC960_V1_QueueReadWriteCommand()
3242 for (i = 0; i < Command->SegmentCount; i++, ScatterList++, ScatterGatherList++) { in DAC960_V1_QueueReadWriteCommand()
3249 DAC960_QueueCommand(Command); in DAC960_V1_QueueReadWriteCommand()
3258 static void DAC960_V2_QueueReadWriteCommand(DAC960_Command_T *Command) in DAC960_V2_QueueReadWriteCommand() argument
3260 DAC960_Controller_T *Controller = Command->Controller; in DAC960_V2_QueueReadWriteCommand()
3261 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_QueueReadWriteCommand()
3262 struct scatterlist *ScatterList = Command->V2.ScatterList; in DAC960_V2_QueueReadWriteCommand()
3264 DAC960_V2_ClearCommand(Command); in DAC960_V2_QueueReadWriteCommand()
3268 (Command->DmaDirection == PCI_DMA_FROMDEVICE); in DAC960_V2_QueueReadWriteCommand()
3270 Command->BlockCount << DAC960_BlockSizeBits; in DAC960_V2_QueueReadWriteCommand()
3271 CommandMailbox->SCSI_10.RequestSenseBusAddress = Command->V2.RequestSenseDMA; in DAC960_V2_QueueReadWriteCommand()
3273 Controller->V2.LogicalDriveToVirtualDevice[Command->LogicalDriveNumber]; in DAC960_V2_QueueReadWriteCommand()
3277 (Command->DmaDirection == PCI_DMA_FROMDEVICE ? 0x28 : 0x2A); in DAC960_V2_QueueReadWriteCommand()
3278 CommandMailbox->SCSI_10.SCSI_CDB[2] = Command->BlockNumber >> 24; in DAC960_V2_QueueReadWriteCommand()
3279 CommandMailbox->SCSI_10.SCSI_CDB[3] = Command->BlockNumber >> 16; in DAC960_V2_QueueReadWriteCommand()
3280 CommandMailbox->SCSI_10.SCSI_CDB[4] = Command->BlockNumber >> 8; in DAC960_V2_QueueReadWriteCommand()
3281 CommandMailbox->SCSI_10.SCSI_CDB[5] = Command->BlockNumber; in DAC960_V2_QueueReadWriteCommand()
3282 CommandMailbox->SCSI_10.SCSI_CDB[7] = Command->BlockCount >> 8; in DAC960_V2_QueueReadWriteCommand()
3283 CommandMailbox->SCSI_10.SCSI_CDB[8] = Command->BlockCount; in DAC960_V2_QueueReadWriteCommand()
3285 if (Command->SegmentCount == 1) in DAC960_V2_QueueReadWriteCommand()
3301 if (Command->SegmentCount > 2) in DAC960_V2_QueueReadWriteCommand()
3303 ScatterGatherList = Command->V2.ScatterGatherList; in DAC960_V2_QueueReadWriteCommand()
3307 .ExtendedScatterGather.ScatterGatherList0Length = Command->SegmentCount; in DAC960_V2_QueueReadWriteCommand()
3310 Command->V2.ScatterGatherListDMA; in DAC960_V2_QueueReadWriteCommand()
3316 for (i = 0; i < Command->SegmentCount; i++, ScatterList++, ScatterGatherList++) { in DAC960_V2_QueueReadWriteCommand()
3323 DAC960_QueueCommand(Command); in DAC960_V2_QueueReadWriteCommand()
3330 DAC960_Command_T *Command; in DAC960_process_queue() local
3337 Command = DAC960_AllocateCommand(Controller); in DAC960_process_queue()
3338 if (Command == NULL) in DAC960_process_queue()
3342 Command->DmaDirection = PCI_DMA_FROMDEVICE; in DAC960_process_queue()
3343 Command->CommandType = DAC960_ReadCommand; in DAC960_process_queue()
3345 Command->DmaDirection = PCI_DMA_TODEVICE; in DAC960_process_queue()
3346 Command->CommandType = DAC960_WriteCommand; in DAC960_process_queue()
3348 Command->Completion = Request->end_io_data; in DAC960_process_queue()
3349 Command->LogicalDriveNumber = (long)Request->rq_disk->private_data; in DAC960_process_queue()
3350 Command->BlockNumber = blk_rq_pos(Request); in DAC960_process_queue()
3351 Command->BlockCount = blk_rq_sectors(Request); in DAC960_process_queue()
3352 Command->Request = Request; in DAC960_process_queue()
3354 Command->SegmentCount = blk_rq_map_sg(req_q, in DAC960_process_queue()
3355 Command->Request, Command->cmd_sglist); in DAC960_process_queue()
3357 Command->SegmentCount = pci_map_sg(Controller->PCIDevice, Command->cmd_sglist, in DAC960_process_queue()
3358 Command->SegmentCount, Command->DmaDirection); in DAC960_process_queue()
3360 DAC960_QueueReadWriteCommand(Command); in DAC960_process_queue()
3416 static void DAC960_queue_partial_rw(DAC960_Command_T *Command) in DAC960_queue_partial_rw() argument
3418 DAC960_Controller_T *Controller = Command->Controller; in DAC960_queue_partial_rw()
3419 struct request *Request = Command->Request; in DAC960_queue_partial_rw()
3420 struct request_queue *req_q = Controller->RequestQueue[Command->LogicalDriveNumber]; in DAC960_queue_partial_rw()
3422 if (Command->DmaDirection == PCI_DMA_FROMDEVICE) in DAC960_queue_partial_rw()
3423 Command->CommandType = DAC960_ReadRetryCommand; in DAC960_queue_partial_rw()
3425 Command->CommandType = DAC960_WriteRetryCommand; in DAC960_queue_partial_rw()
3433 (void)blk_rq_map_sg(req_q, Command->Request, Command->cmd_sglist); in DAC960_queue_partial_rw()
3435 (void)pci_map_sg(Controller->PCIDevice, Command->cmd_sglist, 1, Command->DmaDirection); in DAC960_queue_partial_rw()
3442 Command->SegmentCount = 1; in DAC960_queue_partial_rw()
3443 Command->BlockNumber = blk_rq_pos(Request); in DAC960_queue_partial_rw()
3444 Command->BlockCount = 1; in DAC960_queue_partial_rw()
3445 DAC960_QueueReadWriteCommand(Command); in DAC960_queue_partial_rw()
3463 static inline bool DAC960_ProcessCompletedRequest(DAC960_Command_T *Command, in DAC960_ProcessCompletedRequest() argument
3466 struct request *Request = Command->Request; in DAC960_ProcessCompletedRequest()
3469 pci_unmap_sg(Command->Controller->PCIDevice, Command->cmd_sglist, in DAC960_ProcessCompletedRequest()
3470 Command->SegmentCount, Command->DmaDirection); in DAC960_ProcessCompletedRequest()
3472 if (!__blk_end_request(Request, Error, Command->BlockCount << 9)) { in DAC960_ProcessCompletedRequest()
3473 if (Command->Completion) { in DAC960_ProcessCompletedRequest()
3474 complete(Command->Completion); in DAC960_ProcessCompletedRequest()
3475 Command->Completion = NULL; in DAC960_ProcessCompletedRequest()
3487 static void DAC960_V1_ReadWriteError(DAC960_Command_T *Command) in DAC960_V1_ReadWriteError() argument
3489 DAC960_Controller_T *Controller = Command->Controller; in DAC960_V1_ReadWriteError()
3491 switch (Command->CommandType) in DAC960_V1_ReadWriteError()
3506 switch (Command->V1.CommandStatus) in DAC960_V1_ReadWriteError()
3525 Controller, Command->V1.CommandStatus, CommandName); in DAC960_V1_ReadWriteError()
3530 Command->LogicalDriveNumber, Command->BlockNumber, in DAC960_V1_ReadWriteError()
3531 Command->BlockNumber + Command->BlockCount - 1); in DAC960_V1_ReadWriteError()
3540 static void DAC960_V1_ProcessCompletedCommand(DAC960_Command_T *Command) in DAC960_V1_ProcessCompletedCommand() argument
3542 DAC960_Controller_T *Controller = Command->Controller; in DAC960_V1_ProcessCompletedCommand()
3543 DAC960_CommandType_T CommandType = Command->CommandType; in DAC960_V1_ProcessCompletedCommand()
3545 Command->V1.CommandMailbox.Common.CommandOpcode; in DAC960_V1_ProcessCompletedCommand()
3546 DAC960_V1_CommandStatus_T CommandStatus = Command->V1.CommandStatus; in DAC960_V1_ProcessCompletedCommand()
3558 if (!DAC960_ProcessCompletedRequest(Command, true)) in DAC960_V1_ProcessCompletedCommand()
3568 DAC960_queue_partial_rw(Command); in DAC960_V1_ProcessCompletedCommand()
3574 DAC960_V1_ReadWriteError(Command); in DAC960_V1_ProcessCompletedCommand()
3576 if (!DAC960_ProcessCompletedRequest(Command, false)) in DAC960_V1_ProcessCompletedCommand()
3595 DAC960_V1_ReadWriteError(Command); in DAC960_V1_ProcessCompletedCommand()
3602 DAC960_V1_ReadWriteError(Command); in DAC960_V1_ProcessCompletedCommand()
3606 if (!DAC960_ProcessCompletedRequest(Command, normal_completion)) { in DAC960_V1_ProcessCompletedCommand()
3607 DAC960_queue_partial_rw(Command); in DAC960_V1_ProcessCompletedCommand()
3964 Command->V1.CommandStatus = Controller->V1.PendingRebuildStatus; in DAC960_V1_ProcessCompletedCommand()
4126 Command->V1.CommandMailbox.Type3E.CommandOpcode = in DAC960_V1_ProcessCompletedCommand()
4128 Command->V1.CommandMailbox.Type3E.OperationType = in DAC960_V1_ProcessCompletedCommand()
4130 Command->V1.CommandMailbox.Type3E.OperationQualifier = 1; in DAC960_V1_ProcessCompletedCommand()
4131 Command->V1.CommandMailbox.Type3E.SequenceNumber = in DAC960_V1_ProcessCompletedCommand()
4133 Command->V1.CommandMailbox.Type3E.BusAddress = in DAC960_V1_ProcessCompletedCommand()
4135 DAC960_QueueCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4141 Command->V1.CommandMailbox.Type3.CommandOpcode = in DAC960_V1_ProcessCompletedCommand()
4143 Command->V1.CommandMailbox.Type3.BusAddress = in DAC960_V1_ProcessCompletedCommand()
4145 DAC960_QueueCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4152 Command->V1.CommandMailbox.Type3.CommandOpcode = in DAC960_V1_ProcessCompletedCommand()
4154 Command->V1.CommandMailbox.Type3.BusAddress = in DAC960_V1_ProcessCompletedCommand()
4156 DAC960_QueueCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4169 Command->V1.CommandMailbox.Type3.CommandOpcode = DAC960_V1_DCDB; in DAC960_V1_ProcessCompletedCommand()
4170 Command->V1.CommandMailbox.Type3.BusAddress = DCDB_DMA; in DAC960_V1_ProcessCompletedCommand()
4189 DAC960_QueueCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4199 Command->V1.CommandMailbox.Type3.CommandOpcode = DAC960_V1_DCDB; in DAC960_V1_ProcessCompletedCommand()
4200 Command->V1.CommandMailbox.Type3.BusAddress = DCDB_DMA; in DAC960_V1_ProcessCompletedCommand()
4220 DAC960_QueueCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4238 Command->V1.CommandMailbox.Type3D.CommandOpcode = in DAC960_V1_ProcessCompletedCommand()
4240 Command->V1.CommandMailbox.Type3D.Channel = in DAC960_V1_ProcessCompletedCommand()
4242 Command->V1.CommandMailbox.Type3D.TargetID = in DAC960_V1_ProcessCompletedCommand()
4244 Command->V1.CommandMailbox.Type3D.BusAddress = in DAC960_V1_ProcessCompletedCommand()
4246 DAC960_QueueCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4254 Command->V1.CommandMailbox.Type3.CommandOpcode = in DAC960_V1_ProcessCompletedCommand()
4256 Command->V1.CommandMailbox.Type3.BusAddress = in DAC960_V1_ProcessCompletedCommand()
4258 DAC960_QueueCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4264 Command->V1.CommandMailbox.Type3.CommandOpcode = in DAC960_V1_ProcessCompletedCommand()
4266 Command->V1.CommandMailbox.Type3.BusAddress = in DAC960_V1_ProcessCompletedCommand()
4268 DAC960_QueueCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4274 Command->V1.CommandMailbox.Type3.CommandOpcode = in DAC960_V1_ProcessCompletedCommand()
4276 Command->V1.CommandMailbox.Type3.BusAddress = in DAC960_V1_ProcessCompletedCommand()
4278 DAC960_QueueCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4284 Command->V1.CommandMailbox.Type3B.CommandOpcode = in DAC960_V1_ProcessCompletedCommand()
4286 Command->V1.CommandMailbox.Type3B.CommandOpcode2 = 0x20; in DAC960_V1_ProcessCompletedCommand()
4287 Command->V1.CommandMailbox.Type3B.BusAddress = in DAC960_V1_ProcessCompletedCommand()
4289 DAC960_QueueCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4299 complete(Command->Completion); in DAC960_V1_ProcessCompletedCommand()
4300 Command->Completion = NULL; in DAC960_V1_ProcessCompletedCommand()
4305 DAC960_V1_KernelCommand_T *KernelCommand = Command->V1.KernelCommand; in DAC960_V1_ProcessCompletedCommand()
4306 KernelCommand->CommandStatus = Command->V1.CommandStatus; in DAC960_V1_ProcessCompletedCommand()
4307 Command->V1.KernelCommand = NULL; in DAC960_V1_ProcessCompletedCommand()
4312 DAC960_DeallocateCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4324 DAC960_V1_QueueMonitoringCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4330 DAC960_DeallocateCommand(Command); in DAC960_V1_ProcessCompletedCommand()
4343 static void DAC960_V2_ReadWriteError(DAC960_Command_T *Command) in DAC960_V2_ReadWriteError() argument
4345 DAC960_Controller_T *Controller = Command->Controller; in DAC960_V2_ReadWriteError()
4357 switch (Command->CommandType) in DAC960_V2_ReadWriteError()
4373 SenseErrors[Command->V2.RequestSense->SenseKey], CommandName); in DAC960_V2_ReadWriteError()
4376 Command->LogicalDriveNumber, Command->BlockNumber, in DAC960_V2_ReadWriteError()
4377 Command->BlockNumber + Command->BlockCount - 1); in DAC960_V2_ReadWriteError()
4628 static void DAC960_V2_ProcessCompletedCommand(DAC960_Command_T *Command) in DAC960_V2_ProcessCompletedCommand() argument
4630 DAC960_Controller_T *Controller = Command->Controller; in DAC960_V2_ProcessCompletedCommand()
4631 DAC960_CommandType_T CommandType = Command->CommandType; in DAC960_V2_ProcessCompletedCommand()
4632 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_ProcessCompletedCommand()
4635 DAC960_V2_CommandStatus_T CommandStatus = Command->V2.CommandStatus; in DAC960_V2_ProcessCompletedCommand()
4644 Command->V2.RequestSense->SenseKey = DAC960_SenseKey_MediumError; in DAC960_V2_ProcessCompletedCommand()
4648 if (!DAC960_ProcessCompletedRequest(Command, true)) in DAC960_V2_ProcessCompletedCommand()
4651 } else if (Command->V2.RequestSense->SenseKey == DAC960_SenseKey_MediumError) in DAC960_V2_ProcessCompletedCommand()
4657 DAC960_queue_partial_rw(Command); in DAC960_V2_ProcessCompletedCommand()
4662 if (Command->V2.RequestSense->SenseKey != DAC960_SenseKey_NotReady) in DAC960_V2_ProcessCompletedCommand()
4663 DAC960_V2_ReadWriteError(Command); in DAC960_V2_ProcessCompletedCommand()
4667 (void)DAC960_ProcessCompletedRequest(Command, false); in DAC960_V2_ProcessCompletedCommand()
4685 if (Command->V2.RequestSense->SenseKey != DAC960_SenseKey_NotReady) in DAC960_V2_ProcessCompletedCommand()
4686 DAC960_V2_ReadWriteError(Command); in DAC960_V2_ProcessCompletedCommand()
4693 DAC960_V2_ReadWriteError(Command); in DAC960_V2_ProcessCompletedCommand()
4697 if (!DAC960_ProcessCompletedRequest(Command, normal_completion)) { in DAC960_V2_ProcessCompletedCommand()
4698 DAC960_queue_partial_rw(Command); in DAC960_V2_ProcessCompletedCommand()
5136 DAC960_QueueCommand(Command); in DAC960_V2_ProcessCompletedCommand()
5153 DAC960_QueueCommand(Command); in DAC960_V2_ProcessCompletedCommand()
5183 DAC960_QueueCommand(Command); in DAC960_V2_ProcessCompletedCommand()
5214 DAC960_QueueCommand(Command); in DAC960_V2_ProcessCompletedCommand()
5224 complete(Command->Completion); in DAC960_V2_ProcessCompletedCommand()
5225 Command->Completion = NULL; in DAC960_V2_ProcessCompletedCommand()
5230 DAC960_V2_KernelCommand_T *KernelCommand = Command->V2.KernelCommand; in DAC960_V2_ProcessCompletedCommand()
5232 KernelCommand->RequestSenseLength = Command->V2.RequestSenseLength; in DAC960_V2_ProcessCompletedCommand()
5233 KernelCommand->DataTransferLength = Command->V2.DataTransferResidue; in DAC960_V2_ProcessCompletedCommand()
5234 Command->V2.KernelCommand = NULL; in DAC960_V2_ProcessCompletedCommand()
5235 DAC960_DeallocateCommand(Command); in DAC960_V2_ProcessCompletedCommand()
5247 DAC960_V2_QueueMonitoringCommand(Command); in DAC960_V2_ProcessCompletedCommand()
5253 DAC960_DeallocateCommand(Command); in DAC960_V2_ProcessCompletedCommand()
5280 DAC960_Command_T *Command = Controller->Commands[CommandIdentifier-1]; in DAC960_GEM_InterruptHandler() local
5281 Command->V2.CommandStatus = NextStatusMailbox->Fields.CommandStatus; in DAC960_GEM_InterruptHandler()
5282 Command->V2.RequestSenseLength = in DAC960_GEM_InterruptHandler()
5284 Command->V2.DataTransferResidue = in DAC960_GEM_InterruptHandler()
5289 DAC960_V2_ProcessCompletedCommand(Command); in DAC960_GEM_InterruptHandler()
5321 DAC960_Command_T *Command = Controller->Commands[CommandIdentifier-1]; in DAC960_BA_InterruptHandler() local
5322 Command->V2.CommandStatus = NextStatusMailbox->Fields.CommandStatus; in DAC960_BA_InterruptHandler()
5323 Command->V2.RequestSenseLength = in DAC960_BA_InterruptHandler()
5325 Command->V2.DataTransferResidue = in DAC960_BA_InterruptHandler()
5330 DAC960_V2_ProcessCompletedCommand(Command); in DAC960_BA_InterruptHandler()
5363 DAC960_Command_T *Command = Controller->Commands[CommandIdentifier-1]; in DAC960_LP_InterruptHandler() local
5364 Command->V2.CommandStatus = NextStatusMailbox->Fields.CommandStatus; in DAC960_LP_InterruptHandler()
5365 Command->V2.RequestSenseLength = in DAC960_LP_InterruptHandler()
5367 Command->V2.DataTransferResidue = in DAC960_LP_InterruptHandler()
5372 DAC960_V2_ProcessCompletedCommand(Command); in DAC960_LP_InterruptHandler()
5405 DAC960_Command_T *Command = Controller->Commands[CommandIdentifier-1]; in DAC960_LA_InterruptHandler() local
5406 Command->V1.CommandStatus = NextStatusMailbox->Fields.CommandStatus; in DAC960_LA_InterruptHandler()
5410 DAC960_V1_ProcessCompletedCommand(Command); in DAC960_LA_InterruptHandler()
5443 DAC960_Command_T *Command = Controller->Commands[CommandIdentifier-1]; in DAC960_PG_InterruptHandler() local
5444 Command->V1.CommandStatus = NextStatusMailbox->Fields.CommandStatus; in DAC960_PG_InterruptHandler()
5448 DAC960_V1_ProcessCompletedCommand(Command); in DAC960_PG_InterruptHandler()
5478 DAC960_Command_T *Command = Controller->Commands[CommandIdentifier-1]; in DAC960_PD_InterruptHandler() local
5479 Command->V1.CommandStatus = in DAC960_PD_InterruptHandler()
5483 DAC960_V1_ProcessCompletedCommand(Command); in DAC960_PD_InterruptHandler()
5516 DAC960_Command_T *Command = Controller->Commands[CommandIdentifier-1]; in DAC960_P_InterruptHandler() local
5517 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_P_InterruptHandler()
5520 Command->V1.CommandStatus = in DAC960_P_InterruptHandler()
5527 Command->V1.CommandMailbox.Common.CommandOpcode = DAC960_V1_Enquiry; in DAC960_P_InterruptHandler()
5531 Command->V1.CommandMailbox.Common.CommandOpcode = in DAC960_P_InterruptHandler()
5536 Command->V1.CommandMailbox.Common.CommandOpcode = DAC960_V1_Read; in DAC960_P_InterruptHandler()
5540 Command->V1.CommandMailbox.Common.CommandOpcode = DAC960_V1_Write; in DAC960_P_InterruptHandler()
5544 Command->V1.CommandMailbox.Common.CommandOpcode = in DAC960_P_InterruptHandler()
5549 Command->V1.CommandMailbox.Common.CommandOpcode = in DAC960_P_InterruptHandler()
5556 DAC960_V1_ProcessCompletedCommand(Command); in DAC960_P_InterruptHandler()
5573 static void DAC960_V1_QueueMonitoringCommand(DAC960_Command_T *Command) in DAC960_V1_QueueMonitoringCommand() argument
5575 DAC960_Controller_T *Controller = Command->Controller; in DAC960_V1_QueueMonitoringCommand()
5576 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_V1_QueueMonitoringCommand()
5577 DAC960_V1_ClearCommand(Command); in DAC960_V1_QueueMonitoringCommand()
5578 Command->CommandType = DAC960_MonitoringCommand; in DAC960_V1_QueueMonitoringCommand()
5581 DAC960_QueueCommand(Command); in DAC960_V1_QueueMonitoringCommand()
5590 static void DAC960_V2_QueueMonitoringCommand(DAC960_Command_T *Command) in DAC960_V2_QueueMonitoringCommand() argument
5592 DAC960_Controller_T *Controller = Command->Controller; in DAC960_V2_QueueMonitoringCommand()
5593 DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_QueueMonitoringCommand()
5594 DAC960_V2_ClearCommand(Command); in DAC960_V2_QueueMonitoringCommand()
5595 Command->CommandType = DAC960_MonitoringCommand; in DAC960_V2_QueueMonitoringCommand()
5613 DAC960_QueueCommand(Command); in DAC960_V2_QueueMonitoringCommand()
5625 DAC960_Command_T *Command; in DAC960_MonitoringTimerFunction() local
5634 Command = DAC960_AllocateCommand(Controller); in DAC960_MonitoringTimerFunction()
5635 if (Command != NULL) in DAC960_MonitoringTimerFunction()
5636 DAC960_V1_QueueMonitoringCommand(Command); in DAC960_MonitoringTimerFunction()
5692 Command = DAC960_AllocateCommand(Controller); in DAC960_MonitoringTimerFunction()
5693 if (Command != NULL) in DAC960_MonitoringTimerFunction()
5694 DAC960_V2_QueueMonitoringCommand(Command); in DAC960_MonitoringTimerFunction()
5910 DAC960_Command_T *Command, in DAC960_V1_SetDeviceState() argument
5917 DAC960_V1_CommandMailbox_T *CommandMailbox = &Command->V1.CommandMailbox; in DAC960_V1_SetDeviceState()
5923 DAC960_ExecuteCommand(Command); in DAC960_V1_SetDeviceState()
5924 switch (Command->V1.CommandStatus) in DAC960_V1_SetDeviceState()
5954 Command->V1.CommandStatus); in DAC960_V1_SetDeviceState()
5968 DAC960_Command_T *Command; in DAC960_V1_ExecuteUserCommand() local
5974 while ((Command = DAC960_AllocateCommand(Controller)) == NULL) in DAC960_V1_ExecuteUserCommand()
5978 DAC960_V1_ClearCommand(Command); in DAC960_V1_ExecuteUserCommand()
5979 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V1_ExecuteUserCommand()
5980 CommandMailbox = &Command->V1.CommandMailbox; in DAC960_V1_ExecuteUserCommand()
5984 DAC960_ExecuteCommand(Command); in DAC960_V1_ExecuteUserCommand()
5996 DAC960_V1_SetDeviceState(Controller, Command, Channel, TargetID, in DAC960_V1_ExecuteUserCommand()
6010 DAC960_V1_SetDeviceState(Controller, Command, Channel, TargetID, in DAC960_V1_ExecuteUserCommand()
6025 DAC960_V1_SetDeviceState(Controller, Command, Channel, TargetID, in DAC960_V1_ExecuteUserCommand()
6038 DAC960_ExecuteCommand(Command); in DAC960_V1_ExecuteUserCommand()
6039 switch (Command->V1.CommandStatus) in DAC960_V1_ExecuteUserCommand()
6069 Channel, TargetID, Command->V1.CommandStatus); in DAC960_V1_ExecuteUserCommand()
6080 DAC960_ExecuteCommand(Command); in DAC960_V1_ExecuteUserCommand()
6081 switch (Command->V1.CommandStatus) in DAC960_V1_ExecuteUserCommand()
6120 LogicalDriveNumber, Command->V1.CommandStatus); in DAC960_V1_ExecuteUserCommand()
6146 DAC960_ExecuteCommand(Command); in DAC960_V1_ExecuteUserCommand()
6147 switch (Command->V1.CommandStatus) in DAC960_V1_ExecuteUserCommand()
6157 Controller, Command->V1.CommandStatus); in DAC960_V1_ExecuteUserCommand()
6168 DAC960_DeallocateCommand(Command); in DAC960_V1_ExecuteUserCommand()
6180 static bool DAC960_V2_TranslatePhysicalDevice(DAC960_Command_T *Command, in DAC960_V2_TranslatePhysicalDevice() argument
6187 DAC960_Controller_T *Controller = Command->Controller; in DAC960_V2_TranslatePhysicalDevice()
6189 CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_TranslatePhysicalDevice()
6213 DAC960_ExecuteCommand(Command); in DAC960_V2_TranslatePhysicalDevice()
6218 return (Command->V2.CommandStatus == DAC960_V2_NormalCompletion); in DAC960_V2_TranslatePhysicalDevice()
6230 DAC960_Command_T *Command; in DAC960_V2_ExecuteUserCommand() local
6237 while ((Command = DAC960_AllocateCommand(Controller)) == NULL) in DAC960_V2_ExecuteUserCommand()
6241 DAC960_V2_ClearCommand(Command); in DAC960_V2_ExecuteUserCommand()
6242 Command->CommandType = DAC960_ImmediateCommand; in DAC960_V2_ExecuteUserCommand()
6243 CommandMailbox = &Command->V2.CommandMailbox; in DAC960_V2_ExecuteUserCommand()
6252 DAC960_ExecuteCommand(Command); in DAC960_V2_ExecuteUserCommand()
6258 DAC960_V2_TranslatePhysicalDevice(Command, Channel, TargetID, in DAC960_V2_ExecuteUserCommand()
6267 DAC960_ExecuteCommand(Command); in DAC960_V2_ExecuteUserCommand()
6270 (Command->V2.CommandStatus in DAC960_V2_ExecuteUserCommand()
6277 DAC960_V2_TranslatePhysicalDevice(Command, Channel, TargetID, in DAC960_V2_ExecuteUserCommand()
6286 DAC960_ExecuteCommand(Command); in DAC960_V2_ExecuteUserCommand()
6289 (Command->V2.CommandStatus in DAC960_V2_ExecuteUserCommand()
6296 DAC960_V2_TranslatePhysicalDevice(Command, Channel, TargetID, in DAC960_V2_ExecuteUserCommand()
6305 DAC960_ExecuteCommand(Command); in DAC960_V2_ExecuteUserCommand()
6308 (Command->V2.CommandStatus in DAC960_V2_ExecuteUserCommand()
6315 DAC960_V2_TranslatePhysicalDevice(Command, Channel, TargetID, in DAC960_V2_ExecuteUserCommand()
6322 DAC960_ExecuteCommand(Command); in DAC960_V2_ExecuteUserCommand()
6325 (Command->V2.CommandStatus in DAC960_V2_ExecuteUserCommand()
6332 DAC960_V2_TranslatePhysicalDevice(Command, Channel, TargetID, in DAC960_V2_ExecuteUserCommand()
6339 DAC960_ExecuteCommand(Command); in DAC960_V2_ExecuteUserCommand()
6342 (Command->V2.CommandStatus in DAC960_V2_ExecuteUserCommand()
6356 DAC960_ExecuteCommand(Command); in DAC960_V2_ExecuteUserCommand()
6362 (Command->V2.CommandStatus in DAC960_V2_ExecuteUserCommand()
6374 DAC960_ExecuteCommand(Command); in DAC960_V2_ExecuteUserCommand()
6380 (Command->V2.CommandStatus in DAC960_V2_ExecuteUserCommand()
6387 DAC960_ExecuteCommand(Command); in DAC960_V2_ExecuteUserCommand()
6389 (Command->V2.CommandStatus in DAC960_V2_ExecuteUserCommand()
6392 if (Command->V2.CommandStatus == DAC960_V2_NormalCompletion) in DAC960_V2_ExecuteUserCommand()
6417 DAC960_ExecuteCommand(Command); in DAC960_V2_ExecuteUserCommand()
6431 DAC960_DeallocateCommand(Command); in DAC960_V2_ExecuteUserCommand()
6630 DAC960_Command_T *Command = NULL; in DAC960_gam_v1_execute_command() local
6720 while ((Command = DAC960_AllocateCommand(Controller)) == NULL) in DAC960_gam_v1_execute_command()
6734 DAC960_V1_ClearCommand(Command); in DAC960_gam_v1_execute_command()
6735 Command->CommandType = DAC960_ImmediateCommand; in DAC960_gam_v1_execute_command()
6736 memcpy(&Command->V1.CommandMailbox, &UserCommand.CommandMailbox, in DAC960_gam_v1_execute_command()
6738 Command->V1.CommandMailbox.Type3.BusAddress = DCDB_IOBUFDMA; in DAC960_gam_v1_execute_command()
6745 while ((Command = DAC960_AllocateCommand(Controller)) == NULL) in DAC960_gam_v1_execute_command()
6748 DAC960_V1_ClearCommand(Command); in DAC960_gam_v1_execute_command()
6749 Command->CommandType = DAC960_ImmediateCommand; in DAC960_gam_v1_execute_command()
6750 memcpy(&Command->V1.CommandMailbox, &UserCommand.CommandMailbox, in DAC960_gam_v1_execute_command()
6753 Command->V1.CommandMailbox.Type3.BusAddress = in DAC960_gam_v1_execute_command()
6756 DAC960_ExecuteCommand(Command); in DAC960_gam_v1_execute_command()
6757 CommandStatus = Command->V1.CommandStatus; in DAC960_gam_v1_execute_command()
6759 DAC960_DeallocateCommand(Command); in DAC960_gam_v1_execute_command()
6799 DAC960_Command_T *Command = NULL; in DAC960_gam_v2_execute_command() local
6866 while ((Command = DAC960_AllocateCommand(Controller)) == NULL) in DAC960_gam_v2_execute_command()
6869 DAC960_V2_ClearCommand(Command); in DAC960_gam_v2_execute_command()
6870 Command->CommandType = DAC960_ImmediateCommand; in DAC960_gam_v2_execute_command()
6871 CommandMailbox = &Command->V2.CommandMailbox; in DAC960_gam_v2_execute_command()
6912 DAC960_ExecuteCommand(Command); in DAC960_gam_v2_execute_command()
6913 CommandStatus = Command->V2.CommandStatus; in DAC960_gam_v2_execute_command()
6914 RequestSenseLength = Command->V2.RequestSenseLength; in DAC960_gam_v2_execute_command()
6915 DataTransferResidue = Command->V2.DataTransferResidue; in DAC960_gam_v2_execute_command()
6917 DAC960_DeallocateCommand(Command); in DAC960_gam_v2_execute_command()