From: Tejun Heo <tj@kernel.org>
To: Kevin Hao <haokexin@gmail.com>
Cc: linux-ide@vger.kernel.org, Dan Williams <dan.j.williams@intel.com>
Subject: Re: [PATCH 4/5] libata: support the ata host which implements a queue depth less than 32
Date: Sat, 5 Jul 2014 16:00:55 -0400 [thread overview]
Message-ID: <20140705200055.GB3069@mtj.dyndns.org> (raw)
In-Reply-To: <20140705132134.GA15232@pek-khao-d1.corp.ad.wrs.com>
Hello, Kevin.
On Sat, Jul 05, 2014 at 09:21:34PM +0800, Kevin Hao wrote:
> @@ -1570,15 +1572,8 @@ unsigned ata_exec_internal_sg(struct ata_device *dev,
...
> + /* Tag 0 is used as some drivers choke if any other tag is given. */
> + tag = 0;
If we switch to using a qcflag for marking internal commands, it
probably would be better to guarantee that EH commands always use tag
0.
> diff --git a/include/linux/libata.h b/include/linux/libata.h
> index 5ab4e3a76721..74612875b198 100644
> --- a/include/linux/libata.h
> +++ b/include/linux/libata.h
> @@ -265,6 +265,7 @@ enum {
> ATA_QCFLAG_FAILED = (1 << 16), /* cmd failed and is owned by EH */
> ATA_QCFLAG_SENSE_VALID = (1 << 17), /* sense data valid */
> ATA_QCFLAG_EH_SCHEDULED = (1 << 18), /* EH scheduled (obsolete) */
> + ATA_QCFLAG_INTERNAL = (1 << 19), /* Internal command */
Let's make it more explicit - ATA_QCFLAG_EH.
> +static inline unsigned int ata_tag_internal(struct ata_queued_cmd *qc)
> +{
> + return (qc->flags & ATA_QCFLAG_INTERNAL);
> +}
As we're changing the interface anyway, ata_qc_eh()?
> > Anyways, sata_fsl already has workaround for ATA_TAG_INTERNAL, right?
>
> Yes, the internal command is mapped to tag 0 in sata_fsl.
>
> > Given that the situation around internal tag handling may change, I'm
> > not sure about changing the interface now. Is it a lot of cruft on
> > fsl side?
>
> Yes, I agree.
So, yeah, I like the proposed changes. This is a bit too much as a
fix for fsl tho. First fix fsl and then update so that we use the
qcflag in the devel branch?
Thanks.
--
tejun
next prev parent reply other threads:[~2014-07-05 20:00 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-03 12:09 [PATCH 0/5] libata: support the ata host which implements a queue depth less than 32 Kevin Hao
2014-07-03 12:09 ` [PATCH 1/5] libata: using ata_tag_internal() instead of open-coding Kevin Hao
2014-07-03 12:09 ` [PATCH 2/5] libata: introduce ata_get_internal_tag() Kevin Hao
2014-07-03 12:09 ` [PATCH 3/5] libata: add a 'struct ata_port *' argument for the ata tag help functions Kevin Hao
2014-07-03 12:09 ` [PATCH 4/5] libata: support the ata host which implements a queue depth less than 32 Kevin Hao
2014-07-03 13:47 ` Tejun Heo
2014-07-04 6:46 ` Kevin Hao
2014-07-04 15:30 ` Tejun Heo
2014-07-05 13:21 ` Kevin Hao
2014-07-05 20:00 ` Tejun Heo [this message]
2014-07-06 4:16 ` Kevin Hao
2014-07-03 13:50 ` Tejun Heo
2014-07-04 6:50 ` Kevin Hao
2014-07-03 12:09 ` [PATCH 5/5] sata_fsl: set the correct queue depth for the host controller Kevin Hao
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=20140705200055.GB3069@mtj.dyndns.org \
--to=tj@kernel.org \
--cc=dan.j.williams@intel.com \
--cc=haokexin@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox