All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tejun Heo <htejun@gmail.com>
To: "Darrick J. Wong" <djwong@us.ibm.com>
Cc: linux-scsi@vger.kernel.org, alexisb@us.ibm.com
Subject: Re: [PATCH 04/12] sas_ata: ata_post_internal should abort the sas_task
Date: Tue, 06 Feb 2007 23:47:45 -0800	[thread overview]
Message-ID: <45C98421.7020907@gmail.com> (raw)
In-Reply-To: <20070130091841.31530.81645.stgit@elm3a70.beaverton.ibm.com>

Darrick J. Wong wrote:
> This patch adds a new field, lldd_task, to ata_queued_cmd so that libata
> users such as libsas can associate some data with a qc.  The particular
> ambition with this patch is to associate a sas_task with a qc; that way,
> if libata decides to timeout a command, we can come back (in
> sas_ata_post_internal) and abort the sas task.

Can you rename ->lldd_task to something more generic, say, 
->low/driver_private_data and add a comment to explain who owns it?

> One question remains: Is it necessary to reset the phy on error, or will
> the libata error handler take care of it?  (Assuming that one is written,
> of course.)  This patch, as it is today, works well enough to clean
> things up when an ATA device probe attempt fails halfway through the probe,
> though I'm not sure this is always the right thing to do.

->post_internal_cmd is only responsible for putting the controller into 
a sane state and perform minimal diagnosis of the error if command has 
failed (setting AC_ERR_*).  Sane states are...

1. the controller is ready for further commands, if possible.

2. the controller is not processing the failed command, if #1 is not 
possible.  IOW, DMA engine is stopped (or any other activity which pokes 
memory) and the port is frozen (IRQ muted).

libata EH will take care of resetting, revalidating / reconfiguring 
attached ATA device using the provided reset methods, so no need for 
phy_reset in post_internal_cmd.

-- 
tejun


  reply	other threads:[~2007-02-07 17:55 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20070130091814.31530.23152.stgit@elm3a70.beaverton.ibm.com>
2007-01-30  9:18 ` [PATCH 01/12] sas_ata: Require CONFIG_ATA in Kconfig Darrick J. Wong
2007-01-30  9:18 ` [PATCH 02/12] sas_ata: Satisfy libata qc function locking requirements Darrick J. Wong
2007-01-30  9:18 ` [PATCH 03/12] sas_ata: sas_ata_qc_issue should return AC_ERR_* Darrick J. Wong
2007-01-30  9:18 ` [PATCH 04/12] sas_ata: ata_post_internal should abort the sas_task Darrick J. Wong
2007-02-07  7:47   ` Tejun Heo [this message]
2007-02-22 21:39     ` [PATCH 1/2] sas_ata: Rename ata_queued_cmd->lldd_task to driver_data Darrick J. Wong
2007-02-22 21:43       ` Jeff Garzik
2007-02-22 21:39     ` [PATCH 2/2]: sas_ata: Don't reset the phy in post_internal_command Darrick J. Wong
2007-01-30  9:18 ` [PATCH 05/12] sas_ata: Don't copy aic94xx's sactive to ata_port Darrick J. Wong
2007-01-30  9:18 ` [PATCH 06/12] sas_ata: Implement SATA PHY control Darrick J. Wong
2007-02-07  7:54   ` Tejun Heo
2007-01-30  9:18 ` [PATCH 07/12] libsas: Accept SAM_GOOD for ATAPI devices in sas_ata_task_done Darrick J. Wong
2007-01-30  9:18 ` [PATCH 08/12] libsas: Unknown STP devices should be reported to libata as unknown Darrick J. Wong
2007-02-07  8:20   ` Tejun Heo
2007-01-30  9:18 ` [PATCH 09/12] sas_ata: Assign sas_task to scsi_cmnd to enable EH for ATA devices Darrick J. Wong
2007-01-30  9:18 ` [PATCH 10/12] sas_ata: Implement sas_task_abort " Darrick J. Wong
2007-01-30  9:19 ` [PATCH 11/12] libsas: Provide a generic SATL registration function Darrick J. Wong
2007-01-30  9:19 ` [PATCH 12/12] sas_ata: Make this a module separate from libsas Darrick J. Wong
2007-02-03 16:03   ` James Bottomley
2007-02-04  9:06     ` Darrick J. Wong

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=45C98421.7020907@gmail.com \
    --to=htejun@gmail.com \
    --cc=alexisb@us.ibm.com \
    --cc=djwong@us.ibm.com \
    --cc=linux-scsi@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.