All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tejun Heo <htejun@gmail.com>
To: jgarzik@pobox.com, alan@lxorguk.ukuu.org.uk, albertcc@tw.ibm.com,
	axboe@suse.de, linux-ide@vger.kernel.org
Cc: Tejun Heo <htejun@gmail.com>
Subject: [PATCH 13/14] ahci: kill pp->cmd_tbl_sg
Date: Mon, 3 Apr 2006 17:32:40 +0900	[thread overview]
Message-ID: <11440531601852-git-send-email-htejun@gmail.com> (raw)
In-Reply-To: <1144053158183-git-send-email-htejun@gmail.com>

With NCQ, there are multiple sg tables, so pp->cmd_tbl_sg doesn't cut
it.  Directly calculate sg table address from pp->cmd_tbl.

Signed-off-by: Tejun Heo <htejun@gmail.com>

---

 drivers/scsi/ahci.c |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)

53bd8cc0f4d783cfeb2ba226e61ba58d4534d330
diff --git a/drivers/scsi/ahci.c b/drivers/scsi/ahci.c
index bd4faa1..8201a06 100644
--- a/drivers/scsi/ahci.c
+++ b/drivers/scsi/ahci.c
@@ -187,7 +187,6 @@ struct ahci_port_priv {
 	dma_addr_t		cmd_slot_dma;
 	void			*cmd_tbl;
 	dma_addr_t		cmd_tbl_dma;
-	struct ahci_sg		*cmd_tbl_sg;
 	void			*rx_fis;
 	dma_addr_t		rx_fis_dma;
 	/* register values stored by interrupt handler for EH */
@@ -385,8 +384,6 @@ static int ahci_port_start(struct ata_po
 	pp->cmd_tbl = mem;
 	pp->cmd_tbl_dma = mem_dma;
 
-	pp->cmd_tbl_sg = mem + AHCI_CMD_TBL_HDR_SZ;
-
 	ap->private_data = pp;
 
 	if (hpriv->cap & HOST_CAP_64)
@@ -737,7 +734,7 @@ static unsigned int ahci_fill_sg(struct 
 	/*
 	 * Next, the S/G list.
 	 */
-	ahci_sg = pp->cmd_tbl_sg;
+	ahci_sg = pp->cmd_tbl + AHCI_CMD_TBL_HDR_SZ;
 	ata_for_each_sg(sg, qc) {
 		dma_addr_t addr = sg_dma_address(sg);
 		u32 sg_len = sg_dma_len(sg);
-- 
1.2.4



      parent reply	other threads:[~2006-04-03  8:32 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-04-03  8:32 [PATCHSET] libata: add NCQ support Tejun Heo
2006-04-03  8:32 ` [PATCH 09/14] libata: implement NCQ device configuration Tejun Heo
2006-04-03  8:32 ` [PATCH 02/14] libata: add NCQ related libata flags Tejun Heo
2006-04-03  8:32 ` [PATCH 03/14] libata: pass ata_scsi_translate() return value to SCSI midlayer Tejun Heo
2006-04-03  8:32 ` [PATCH 08/14] libata: update EH to handle NCQ Tejun Heo
2006-04-03  8:32 ` [PATCH 05/14] libata: implement command exclusion Tejun Heo
2006-04-03  8:32 ` [PATCH 10/14] libata: implement ata_ncq_complete() Tejun Heo
2006-04-03  8:32 ` [PATCH 06/14] libata: implement NCQ command translation Tejun Heo
2006-04-03  8:32 ` [PATCH 04/14] libata: implement ap->sactive Tejun Heo
2006-04-03  8:32 ` [PATCH 07/14] libata: implement ata_eh_read_log_10h() Tejun Heo
2006-04-03  8:32 ` [PATCH 01/14] libata: add NCQ related ATA constants and id macros Tejun Heo
2006-04-03  8:32 ` [PATCH 12/14] ahci: add HOST_CAP_NCQ constant Tejun Heo
2006-04-03  8:32 ` [PATCH 14/14] ahci: implement NCQ suppport Tejun Heo
2006-04-03  8:32 ` [PATCH 11/14] libata: clean up AHCI constants in preparation for NCQ Tejun Heo
2006-04-03  8:32 ` Tejun Heo [this message]

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=11440531601852-git-send-email-htejun@gmail.com \
    --to=htejun@gmail.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=albertcc@tw.ibm.com \
    --cc=axboe@suse.de \
    --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.