Skip to content

Commit

Permalink
Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/ker…
Browse files Browse the repository at this point in the history
…nel/git/jgarzik/libata-dev

* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev:
  [PATCH] libata: add pio flush for via atapi (was: Re: TR: ASUS A8V Deluxe, x86_64)
  • Loading branch information
Linus Torvalds committed May 24, 2006
2 parents b8bba26 + bb31a8f commit 2786545
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions drivers/scsi/libata-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -3643,6 +3643,8 @@ static void ata_pio_block(struct ata_port *ap)

ata_pio_sector(qc);
}

ata_altstatus(ap); /* flush */
}

static void ata_pio_error(struct ata_port *ap)
Expand Down Expand Up @@ -3759,11 +3761,14 @@ static void atapi_packet_task(void *_data)
spin_lock_irqsave(&ap->host_set->lock, flags);
ap->flags &= ~ATA_FLAG_NOINTR;
ata_data_xfer(ap, qc->cdb, qc->dev->cdb_len, 1);
ata_altstatus(ap); /* flush */

if (qc->tf.protocol == ATA_PROT_ATAPI_DMA)
ap->ops->bmdma_start(qc); /* initiate bmdma */
spin_unlock_irqrestore(&ap->host_set->lock, flags);
} else {
ata_data_xfer(ap, qc->cdb, qc->dev->cdb_len, 1);
ata_altstatus(ap); /* flush */

/* PIO commands are handled by polling */
ap->hsm_task_state = HSM_ST;
Expand Down

0 comments on commit 2786545

Please sign in to comment.