diff options
author | Tejun Heo <htejun@gmail.com> | 2007-08-06 05:36:23 -0400 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2007-10-12 14:55:31 -0400 |
commit | 0c88758b5a6325428aaadab619886242db20ceae (patch) | |
tree | bf84abbce984fa45c4ce927b65695f30a8ea3a43 /drivers/ata/ahci.c | |
parent | 0260731f0187840e272bfa10d3ba0f3e417976f5 (diff) |
libata-link: make two port flags HRST_TO_RESUME and SKIP_D2H_BSY link flags
HRST_TO_RESUME and SKIP_D2H_BSY are link attributes. Move them to
ata_link->flags. This will allow host and PMP links to have different
attributes. ata_port_info->link_flags is added and used by LLDs to
specify these flags during initialization.
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/ata/ahci.c')
-rw-r--r-- | drivers/ata/ahci.c | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c index e38ae12d0148..483733783cf8 100644 --- a/drivers/ata/ahci.c +++ b/drivers/ata/ahci.c | |||
@@ -178,8 +178,8 @@ enum { | |||
178 | 178 | ||
179 | AHCI_FLAG_COMMON = ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY | | 179 | AHCI_FLAG_COMMON = ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY | |
180 | ATA_FLAG_MMIO | ATA_FLAG_PIO_DMA | | 180 | ATA_FLAG_MMIO | ATA_FLAG_PIO_DMA | |
181 | ATA_FLAG_SKIP_D2H_BSY | | ||
182 | ATA_FLAG_ACPI_SATA, | 181 | ATA_FLAG_ACPI_SATA, |
182 | AHCI_LFLAG_COMMON = ATA_LFLAG_SKIP_D2H_BSY, | ||
183 | }; | 183 | }; |
184 | 184 | ||
185 | struct ahci_cmd_hdr { | 185 | struct ahci_cmd_hdr { |
@@ -333,6 +333,7 @@ static const struct ata_port_info ahci_port_info[] = { | |||
333 | /* board_ahci */ | 333 | /* board_ahci */ |
334 | { | 334 | { |
335 | .flags = AHCI_FLAG_COMMON, | 335 | .flags = AHCI_FLAG_COMMON, |
336 | .link_flags = AHCI_LFLAG_COMMON, | ||
336 | .pio_mask = 0x1f, /* pio0-4 */ | 337 | .pio_mask = 0x1f, /* pio0-4 */ |
337 | .udma_mask = ATA_UDMA6, | 338 | .udma_mask = ATA_UDMA6, |
338 | .port_ops = &ahci_ops, | 339 | .port_ops = &ahci_ops, |
@@ -340,14 +341,15 @@ static const struct ata_port_info ahci_port_info[] = { | |||
340 | /* board_ahci_pi */ | 341 | /* board_ahci_pi */ |
341 | { | 342 | { |
342 | .flags = AHCI_FLAG_COMMON | AHCI_FLAG_HONOR_PI, | 343 | .flags = AHCI_FLAG_COMMON | AHCI_FLAG_HONOR_PI, |
344 | .link_flags = AHCI_LFLAG_COMMON, | ||
343 | .pio_mask = 0x1f, /* pio0-4 */ | 345 | .pio_mask = 0x1f, /* pio0-4 */ |
344 | .udma_mask = ATA_UDMA6, | 346 | .udma_mask = ATA_UDMA6, |
345 | .port_ops = &ahci_ops, | 347 | .port_ops = &ahci_ops, |
346 | }, | 348 | }, |
347 | /* board_ahci_vt8251 */ | 349 | /* board_ahci_vt8251 */ |
348 | { | 350 | { |
349 | .flags = AHCI_FLAG_COMMON | ATA_FLAG_HRST_TO_RESUME | | 351 | .flags = AHCI_FLAG_COMMON | AHCI_FLAG_NO_NCQ, |
350 | AHCI_FLAG_NO_NCQ, | 352 | .link_flags = AHCI_LFLAG_COMMON | ATA_LFLAG_HRST_TO_RESUME, |
351 | .pio_mask = 0x1f, /* pio0-4 */ | 353 | .pio_mask = 0x1f, /* pio0-4 */ |
352 | .udma_mask = ATA_UDMA6, | 354 | .udma_mask = ATA_UDMA6, |
353 | .port_ops = &ahci_vt8251_ops, | 355 | .port_ops = &ahci_vt8251_ops, |
@@ -355,6 +357,7 @@ static const struct ata_port_info ahci_port_info[] = { | |||
355 | /* board_ahci_ign_iferr */ | 357 | /* board_ahci_ign_iferr */ |
356 | { | 358 | { |
357 | .flags = AHCI_FLAG_COMMON | AHCI_FLAG_IGN_IRQ_IF_ERR, | 359 | .flags = AHCI_FLAG_COMMON | AHCI_FLAG_IGN_IRQ_IF_ERR, |
360 | .link_flags = AHCI_LFLAG_COMMON, | ||
358 | .pio_mask = 0x1f, /* pio0-4 */ | 361 | .pio_mask = 0x1f, /* pio0-4 */ |
359 | .udma_mask = ATA_UDMA6, | 362 | .udma_mask = ATA_UDMA6, |
360 | .port_ops = &ahci_ops, | 363 | .port_ops = &ahci_ops, |
@@ -364,6 +367,7 @@ static const struct ata_port_info ahci_port_info[] = { | |||
364 | .flags = AHCI_FLAG_COMMON | | 367 | .flags = AHCI_FLAG_COMMON | |
365 | AHCI_FLAG_IGN_SERR_INTERNAL | | 368 | AHCI_FLAG_IGN_SERR_INTERNAL | |
366 | AHCI_FLAG_32BIT_ONLY, | 369 | AHCI_FLAG_32BIT_ONLY, |
370 | .link_flags = AHCI_LFLAG_COMMON, | ||
367 | .pio_mask = 0x1f, /* pio0-4 */ | 371 | .pio_mask = 0x1f, /* pio0-4 */ |
368 | .udma_mask = ATA_UDMA6, | 372 | .udma_mask = ATA_UDMA6, |
369 | .port_ops = &ahci_ops, | 373 | .port_ops = &ahci_ops, |
@@ -373,9 +377,9 @@ static const struct ata_port_info ahci_port_info[] = { | |||
373 | .sht = &ahci_sht, | 377 | .sht = &ahci_sht, |
374 | .flags = ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY | | 378 | .flags = ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY | |
375 | ATA_FLAG_MMIO | ATA_FLAG_PIO_DMA | | 379 | ATA_FLAG_MMIO | ATA_FLAG_PIO_DMA | |
376 | ATA_FLAG_SKIP_D2H_BSY | AHCI_FLAG_HONOR_PI | | 380 | AHCI_FLAG_HONOR_PI | AHCI_FLAG_NO_NCQ | |
377 | AHCI_FLAG_NO_NCQ | AHCI_FLAG_NO_MSI | | 381 | AHCI_FLAG_NO_MSI | AHCI_FLAG_MV_PATA, |
378 | AHCI_FLAG_MV_PATA, | 382 | .link_flags = AHCI_LFLAG_COMMON, |
379 | .pio_mask = 0x1f, /* pio0-4 */ | 383 | .pio_mask = 0x1f, /* pio0-4 */ |
380 | .udma_mask = ATA_UDMA6, | 384 | .udma_mask = ATA_UDMA6, |
381 | .port_ops = &ahci_ops, | 385 | .port_ops = &ahci_ops, |