esp_scsi.c (63ce2499947683dcc026373e24a4cb5a9d086e7d) | esp_scsi.c (70f23fd66bc821a0e99647f70a809e277cc93c4c) |
---|---|
1/* esp_scsi.c: ESP SCSI driver. 2 * 3 * Copyright (C) 2007 David S. Miller (davem@davemloft.net) 4 */ 5 6#include <linux/kernel.h> 7#include <linux/types.h> 8#include <linux/slab.h> --- 694 unchanged lines hidden (view full) --- 703 704 cmd = ent->cmd; 705 dev = cmd->device; 706 tgt = dev->id; 707 lun = dev->lun; 708 tp = &esp->target[tgt]; 709 lp = dev->hostdata; 710 | 1/* esp_scsi.c: ESP SCSI driver. 2 * 3 * Copyright (C) 2007 David S. Miller (davem@davemloft.net) 4 */ 5 6#include <linux/kernel.h> 7#include <linux/types.h> 8#include <linux/slab.h> --- 694 unchanged lines hidden (view full) --- 703 704 cmd = ent->cmd; 705 dev = cmd->device; 706 tgt = dev->id; 707 lun = dev->lun; 708 tp = &esp->target[tgt]; 709 lp = dev->hostdata; 710 |
711 list_move(&ent->list, &esp->active_cmds); | 711 list_del(&ent->list); 712 list_add(&ent->list, &esp->active_cmds); |
712 713 esp->active_cmd = ent; 714 715 esp_map_dma(esp, cmd); 716 esp_save_pointers(esp, ent); 717 718 esp_check_command_len(esp, cmd); 719 --- 333 unchanged lines hidden (view full) --- 1053 } 1054 1055 /* DMA in the tag bytes... */ 1056 esp->command_block[0] = 0xff; 1057 esp->command_block[1] = 0xff; 1058 esp->ops->send_dma_cmd(esp, esp->command_block_dma, 1059 2, 2, 1, ESP_CMD_DMA | ESP_CMD_TI); 1060 | 713 714 esp->active_cmd = ent; 715 716 esp_map_dma(esp, cmd); 717 esp_save_pointers(esp, ent); 718 719 esp_check_command_len(esp, cmd); 720 --- 333 unchanged lines hidden (view full) --- 1054 } 1055 1056 /* DMA in the tag bytes... */ 1057 esp->command_block[0] = 0xff; 1058 esp->command_block[1] = 0xff; 1059 esp->ops->send_dma_cmd(esp, esp->command_block_dma, 1060 2, 2, 1, ESP_CMD_DMA | ESP_CMD_TI); 1061 |
1061 /* ACK the msssage. */ | 1062 /* ACK the message. */ |
1062 scsi_esp_cmd(esp, ESP_CMD_MOK); 1063 1064 for (i = 0; i < ESP_RESELECT_TAG_LIMIT; i++) { 1065 if (esp->ops->irq_pending(esp)) { 1066 esp->sreg = esp_read8(ESP_STATUS); 1067 esp->ireg = esp_read8(ESP_INTRPT); 1068 if (esp->ireg & ESP_INTR_FDONE) 1069 break; --- 168 unchanged lines hidden (view full) --- 1238 SCSI_SENSE_BUFFERSIZE, 1239 DMA_FROM_DEVICE); 1240 ent->sense_ptr = NULL; 1241 } 1242 1243 /* Now that the state is unwound properly, put back onto 1244 * the issue queue. This command is no longer active. 1245 */ | 1063 scsi_esp_cmd(esp, ESP_CMD_MOK); 1064 1065 for (i = 0; i < ESP_RESELECT_TAG_LIMIT; i++) { 1066 if (esp->ops->irq_pending(esp)) { 1067 esp->sreg = esp_read8(ESP_STATUS); 1068 esp->ireg = esp_read8(ESP_INTRPT); 1069 if (esp->ireg & ESP_INTR_FDONE) 1070 break; --- 168 unchanged lines hidden (view full) --- 1239 SCSI_SENSE_BUFFERSIZE, 1240 DMA_FROM_DEVICE); 1241 ent->sense_ptr = NULL; 1242 } 1243 1244 /* Now that the state is unwound properly, put back onto 1245 * the issue queue. This command is no longer active. 1246 */ |
1246 list_move(&ent->list, &esp->queued_cmds); | 1247 list_del(&ent->list); 1248 list_add(&ent->list, &esp->queued_cmds); |
1247 esp->active_cmd = NULL; 1248 1249 /* Return value ignored by caller, it directly invokes 1250 * esp_reconnect(). 1251 */ 1252 return 0; 1253 } 1254 --- 1480 unchanged lines hidden --- | 1249 esp->active_cmd = NULL; 1250 1251 /* Return value ignored by caller, it directly invokes 1252 * esp_reconnect(). 1253 */ 1254 return 0; 1255 } 1256 --- 1480 unchanged lines hidden --- |