diff options
author | Tejun Heo <htejun@gmail.com> | 2006-06-16 02:00:18 -0400 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2006-06-20 05:12:15 -0400 |
commit | d7a80dad2fe19a2b8c119c8e9cba605474a75a2b (patch) | |
tree | b32a32f95bc40f7fa4dbc1f127213aaa75e96ca9 /drivers | |
parent | 40ef1d8d48e364dce689342adfdc475aa53f4808 (diff) |
[PATCH] libata: convert several bmdma-style controllers to new EH, take #3
Convert sata_sis, svw, uli and vsc drivers to new EH. All the drivers
used to specify ATA_FLAG_SATA_RESET to tell libata to use SATA
hardreset instead of SRST. This patch makes all the converted drivers
use the standard bmdma error handler which uses both SRST and SATA
hardreset.
All the controllers should be able to perform SRST but still needs
verification. If some of the controllers can't do SRST, it will be
very easy to spot as it will show up during boot probing.
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/scsi/sata_sis.c | 9 | ||||
-rw-r--r-- | drivers/scsi/sata_svw.c | 10 | ||||
-rw-r--r-- | drivers/scsi/sata_uli.c | 10 | ||||
-rw-r--r-- | drivers/scsi/sata_vsc.c | 8 |
4 files changed, 21 insertions, 16 deletions
diff --git a/drivers/scsi/sata_sis.c b/drivers/scsi/sata_sis.c index a07e6e525173..809d337ed641 100644 --- a/drivers/scsi/sata_sis.c +++ b/drivers/scsi/sata_sis.c | |||
@@ -107,7 +107,6 @@ static const struct ata_port_operations sis_ops = { | |||
107 | .check_status = ata_check_status, | 107 | .check_status = ata_check_status, |
108 | .exec_command = ata_exec_command, | 108 | .exec_command = ata_exec_command, |
109 | .dev_select = ata_std_dev_select, | 109 | .dev_select = ata_std_dev_select, |
110 | .phy_reset = sata_phy_reset, | ||
111 | .bmdma_setup = ata_bmdma_setup, | 110 | .bmdma_setup = ata_bmdma_setup, |
112 | .bmdma_start = ata_bmdma_start, | 111 | .bmdma_start = ata_bmdma_start, |
113 | .bmdma_stop = ata_bmdma_stop, | 112 | .bmdma_stop = ata_bmdma_stop, |
@@ -115,7 +114,10 @@ static const struct ata_port_operations sis_ops = { | |||
115 | .qc_prep = ata_qc_prep, | 114 | .qc_prep = ata_qc_prep, |
116 | .qc_issue = ata_qc_issue_prot, | 115 | .qc_issue = ata_qc_issue_prot, |
117 | .data_xfer = ata_pio_data_xfer, | 116 | .data_xfer = ata_pio_data_xfer, |
118 | .eng_timeout = ata_eng_timeout, | 117 | .freeze = ata_bmdma_freeze, |
118 | .thaw = ata_bmdma_thaw, | ||
119 | .error_handler = ata_bmdma_error_handler, | ||
120 | .post_internal_cmd = ata_bmdma_post_internal_cmd, | ||
119 | .irq_handler = ata_interrupt, | 121 | .irq_handler = ata_interrupt, |
120 | .irq_clear = ata_bmdma_irq_clear, | 122 | .irq_clear = ata_bmdma_irq_clear, |
121 | .scr_read = sis_scr_read, | 123 | .scr_read = sis_scr_read, |
@@ -127,8 +129,7 @@ static const struct ata_port_operations sis_ops = { | |||
127 | 129 | ||
128 | static struct ata_port_info sis_port_info = { | 130 | static struct ata_port_info sis_port_info = { |
129 | .sht = &sis_sht, | 131 | .sht = &sis_sht, |
130 | .host_flags = ATA_FLAG_SATA | ATA_FLAG_SATA_RESET | | 132 | .host_flags = ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY, |
131 | ATA_FLAG_NO_LEGACY, | ||
132 | .pio_mask = 0x1f, | 133 | .pio_mask = 0x1f, |
133 | .mwdma_mask = 0x7, | 134 | .mwdma_mask = 0x7, |
134 | .udma_mask = 0x7f, | 135 | .udma_mask = 0x7f, |
diff --git a/drivers/scsi/sata_svw.c b/drivers/scsi/sata_svw.c index d9b516836486..c94b870cf378 100644 --- a/drivers/scsi/sata_svw.c +++ b/drivers/scsi/sata_svw.c | |||
@@ -314,7 +314,6 @@ static const struct ata_port_operations k2_sata_ops = { | |||
314 | .check_status = k2_stat_check_status, | 314 | .check_status = k2_stat_check_status, |
315 | .exec_command = ata_exec_command, | 315 | .exec_command = ata_exec_command, |
316 | .dev_select = ata_std_dev_select, | 316 | .dev_select = ata_std_dev_select, |
317 | .phy_reset = sata_phy_reset, | ||
318 | .bmdma_setup = k2_bmdma_setup_mmio, | 317 | .bmdma_setup = k2_bmdma_setup_mmio, |
319 | .bmdma_start = k2_bmdma_start_mmio, | 318 | .bmdma_start = k2_bmdma_start_mmio, |
320 | .bmdma_stop = ata_bmdma_stop, | 319 | .bmdma_stop = ata_bmdma_stop, |
@@ -322,7 +321,10 @@ static const struct ata_port_operations k2_sata_ops = { | |||
322 | .qc_prep = ata_qc_prep, | 321 | .qc_prep = ata_qc_prep, |
323 | .qc_issue = ata_qc_issue_prot, | 322 | .qc_issue = ata_qc_issue_prot, |
324 | .data_xfer = ata_mmio_data_xfer, | 323 | .data_xfer = ata_mmio_data_xfer, |
325 | .eng_timeout = ata_eng_timeout, | 324 | .freeze = ata_bmdma_freeze, |
325 | .thaw = ata_bmdma_thaw, | ||
326 | .error_handler = ata_bmdma_error_handler, | ||
327 | .post_internal_cmd = ata_bmdma_post_internal_cmd, | ||
326 | .irq_handler = ata_interrupt, | 328 | .irq_handler = ata_interrupt, |
327 | .irq_clear = ata_bmdma_irq_clear, | 329 | .irq_clear = ata_bmdma_irq_clear, |
328 | .scr_read = k2_sata_scr_read, | 330 | .scr_read = k2_sata_scr_read, |
@@ -422,8 +424,8 @@ static int k2_sata_init_one (struct pci_dev *pdev, const struct pci_device_id *e | |||
422 | writel(0x0, mmio_base + K2_SATA_SIM_OFFSET); | 424 | writel(0x0, mmio_base + K2_SATA_SIM_OFFSET); |
423 | 425 | ||
424 | probe_ent->sht = &k2_sata_sht; | 426 | probe_ent->sht = &k2_sata_sht; |
425 | probe_ent->host_flags = ATA_FLAG_SATA | ATA_FLAG_SATA_RESET | | 427 | probe_ent->host_flags = ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY | |
426 | ATA_FLAG_NO_LEGACY | ATA_FLAG_MMIO; | 428 | ATA_FLAG_MMIO; |
427 | probe_ent->port_ops = &k2_sata_ops; | 429 | probe_ent->port_ops = &k2_sata_ops; |
428 | probe_ent->n_ports = 4; | 430 | probe_ent->n_ports = 4; |
429 | probe_ent->irq = pdev->irq; | 431 | probe_ent->irq = pdev->irq; |
diff --git a/drivers/scsi/sata_uli.c b/drivers/scsi/sata_uli.c index e69ba229adca..f668c997e9af 100644 --- a/drivers/scsi/sata_uli.c +++ b/drivers/scsi/sata_uli.c | |||
@@ -103,8 +103,6 @@ static const struct ata_port_operations uli_ops = { | |||
103 | .exec_command = ata_exec_command, | 103 | .exec_command = ata_exec_command, |
104 | .dev_select = ata_std_dev_select, | 104 | .dev_select = ata_std_dev_select, |
105 | 105 | ||
106 | .phy_reset = sata_phy_reset, | ||
107 | |||
108 | .bmdma_setup = ata_bmdma_setup, | 106 | .bmdma_setup = ata_bmdma_setup, |
109 | .bmdma_start = ata_bmdma_start, | 107 | .bmdma_start = ata_bmdma_start, |
110 | .bmdma_stop = ata_bmdma_stop, | 108 | .bmdma_stop = ata_bmdma_stop, |
@@ -113,7 +111,10 @@ static const struct ata_port_operations uli_ops = { | |||
113 | .qc_issue = ata_qc_issue_prot, | 111 | .qc_issue = ata_qc_issue_prot, |
114 | .data_xfer = ata_pio_data_xfer, | 112 | .data_xfer = ata_pio_data_xfer, |
115 | 113 | ||
116 | .eng_timeout = ata_eng_timeout, | 114 | .freeze = ata_bmdma_freeze, |
115 | .thaw = ata_bmdma_thaw, | ||
116 | .error_handler = ata_bmdma_error_handler, | ||
117 | .post_internal_cmd = ata_bmdma_post_internal_cmd, | ||
117 | 118 | ||
118 | .irq_handler = ata_interrupt, | 119 | .irq_handler = ata_interrupt, |
119 | .irq_clear = ata_bmdma_irq_clear, | 120 | .irq_clear = ata_bmdma_irq_clear, |
@@ -128,8 +129,7 @@ static const struct ata_port_operations uli_ops = { | |||
128 | 129 | ||
129 | static struct ata_port_info uli_port_info = { | 130 | static struct ata_port_info uli_port_info = { |
130 | .sht = &uli_sht, | 131 | .sht = &uli_sht, |
131 | .host_flags = ATA_FLAG_SATA | ATA_FLAG_SATA_RESET | | 132 | .host_flags = ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY, |
132 | ATA_FLAG_NO_LEGACY, | ||
133 | .pio_mask = 0x1f, /* pio0-4 */ | 133 | .pio_mask = 0x1f, /* pio0-4 */ |
134 | .udma_mask = 0x7f, /* udma0-6 */ | 134 | .udma_mask = 0x7f, /* udma0-6 */ |
135 | .port_ops = &uli_ops, | 135 | .port_ops = &uli_ops, |
diff --git a/drivers/scsi/sata_vsc.c b/drivers/scsi/sata_vsc.c index 22ca7b848cf6..d92e3dd37042 100644 --- a/drivers/scsi/sata_vsc.c +++ b/drivers/scsi/sata_vsc.c | |||
@@ -291,7 +291,6 @@ static const struct ata_port_operations vsc_sata_ops = { | |||
291 | .exec_command = ata_exec_command, | 291 | .exec_command = ata_exec_command, |
292 | .check_status = ata_check_status, | 292 | .check_status = ata_check_status, |
293 | .dev_select = ata_std_dev_select, | 293 | .dev_select = ata_std_dev_select, |
294 | .phy_reset = sata_phy_reset, | ||
295 | .bmdma_setup = ata_bmdma_setup, | 294 | .bmdma_setup = ata_bmdma_setup, |
296 | .bmdma_start = ata_bmdma_start, | 295 | .bmdma_start = ata_bmdma_start, |
297 | .bmdma_stop = ata_bmdma_stop, | 296 | .bmdma_stop = ata_bmdma_stop, |
@@ -299,7 +298,10 @@ static const struct ata_port_operations vsc_sata_ops = { | |||
299 | .qc_prep = ata_qc_prep, | 298 | .qc_prep = ata_qc_prep, |
300 | .qc_issue = ata_qc_issue_prot, | 299 | .qc_issue = ata_qc_issue_prot, |
301 | .data_xfer = ata_pio_data_xfer, | 300 | .data_xfer = ata_pio_data_xfer, |
302 | .eng_timeout = ata_eng_timeout, | 301 | .freeze = ata_bmdma_freeze, |
302 | .thaw = ata_bmdma_thaw, | ||
303 | .error_handler = ata_bmdma_error_handler, | ||
304 | .post_internal_cmd = ata_bmdma_post_internal_cmd, | ||
303 | .irq_handler = vsc_sata_interrupt, | 305 | .irq_handler = vsc_sata_interrupt, |
304 | .irq_clear = ata_bmdma_irq_clear, | 306 | .irq_clear = ata_bmdma_irq_clear, |
305 | .scr_read = vsc_sata_scr_read, | 307 | .scr_read = vsc_sata_scr_read, |
@@ -394,7 +396,7 @@ static int __devinit vsc_sata_init_one (struct pci_dev *pdev, const struct pci_d | |||
394 | 396 | ||
395 | probe_ent->sht = &vsc_sata_sht; | 397 | probe_ent->sht = &vsc_sata_sht; |
396 | probe_ent->host_flags = ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY | | 398 | probe_ent->host_flags = ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY | |
397 | ATA_FLAG_MMIO | ATA_FLAG_SATA_RESET; | 399 | ATA_FLAG_MMIO; |
398 | probe_ent->port_ops = &vsc_sata_ops; | 400 | probe_ent->port_ops = &vsc_sata_ops; |
399 | probe_ent->n_ports = 4; | 401 | probe_ent->n_ports = 4; |
400 | probe_ent->irq = pdev->irq; | 402 | probe_ent->irq = pdev->irq; |