All of lore.kernel.org
 help / color / mirror / Atom feed
From: Albert Lee <albertcc@tw.ibm.com>
To: Jeff Garzik <jgarzik@pobox.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>,
	Linux IDE <linux-ide@vger.kernel.org>
Subject: [PATCH 1/1] libata: let ATA_FLAG_PIO_POLLING use polling pio for ATA_PROT_NODATA
Date: Thu, 07 Dec 2006 11:37:58 +0800	[thread overview]
Message-ID: <45778C96.7010101@tw.ibm.com> (raw)

Even if ATA_FLAG_PIO_POLLING is set, libata uses irq pio for the ATA_PROT_NODATA protocol.
This patch let ATA_FLAG_PIO_POLLING use polling pio for the ATA_PROT_NODATA protocol.

Signed-off-by: Albert Lee <albertcc@tw.ibm.com>
---
Currently even if ATA_FLAG_PIO_POLLING is set, irq driven pio is used for the
ATA_PROT_NODATA protocol. This won't cause problem for the current users of
ATA_FLAG_PIO_POLLING (sata_mv, pdc_adma.c, etc.) since the older drivers can
handle the PIO_NODATA interrupts just like the DMA interrupts.

However, pata_ixp4xx_cf, the new user of ATA_FLAG_PIO_POLLING, might have no
interrupt at all. Using irq driven pio for the ATA_PROT_NODATA protocol will
cause timeout for pata_ixp4xx_cf.

The patch is against libata-dev (2b25ec4b7b73f57f09c1262d2f2d4a567b18f44f).
For your review, thanks.

--- libata-dev/drivers/ata/libata-core.c	2006-12-07 11:05:23.000000000 +0800
+++ pio_polling/drivers/ata/libata-core.c	2006-12-07 11:10:21.000000000 +0800
@@ -4975,6 +4975,7 @@ unsigned int ata_qc_issue_prot(struct at
 	if (ap->flags & ATA_FLAG_PIO_POLLING) {
 		switch (qc->tf.protocol) {
 		case ATA_PROT_PIO:
+		case ATA_PROT_NODATA:
 		case ATA_PROT_ATAPI:
 		case ATA_PROT_ATAPI_NODATA:
 			qc->tf.flags |= ATA_TFLAG_POLLING;



             reply	other threads:[~2006-12-07  3:38 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-12-07  3:37 Albert Lee [this message]
2006-12-07 12:22 ` [PATCH 1/1] libata: let ATA_FLAG_PIO_POLLING use polling pio for ATA_PROT_NODATA Jeff Garzik

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=45778C96.7010101@tw.ibm.com \
    --to=albertcc@tw.ibm.com \
    --cc=a.zummo@towertech.it \
    --cc=albertl@mail.com \
    --cc=jgarzik@pobox.com \
    --cc=linux-ide@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.