linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "zhao, forrest" <forrest.zhao@intel.com>
To: Jens Axboe <axboe@suse.de>
Cc: jeff@garzik.org, hare@suse.de, htejun@gmail.com, jeremy@goop.org,
	lkml@rtr.ca, linux-ide@vger.kernel.org
Subject: Re: [PATCH 2/6] The definition of ahci_start_fis_rx() and ahci_stop_fis_rx()
Date: Fri, 02 Jun 2006 17:09:27 +0800	[thread overview]
Message-ID: <1149239367.29552.9.camel@forrest26.sh.intel.com> (raw)
In-Reply-To: <20060602091544.GA4400@suse.de>

On Fri, 2006-06-02 at 11:15 +0200, Jens Axboe wrote:
> On Fri, Jun 02 2006, zhao, forrest wrote:
> > +	/*
> > +	 * Disable FIS reception
> > +	 *
> > +	 * AHCI Rev 1.1 Section 10.1.2:
> > +	 * If PxCMD.FRE is set to '1', software should clear it
> > +	 * to '0' and wait at least 500 milliseconds for PxCMD.FR
> > +	 * to return '0' when read. If PxCMD.FR does not clear
> > +	 * '0' correctly, then software may attempt a port reset
> > +	 * of a full HBA reset to recover.
> > +	 */
> > +	tmp &= ~(PORT_CMD_FIS_RX);
> > +	writel(tmp, port_mmio + PORT_CMD);
> > +
> > +	mdelay(500);
> > +	work = 1000;
> 
> The spec states that you should wait up to 500msec for this condition to
> happen, not wait 500msec before looking at it! So please rework this
> bit, a half second potentially wasted busy loop is quite nasty.

The spec says If PxCMD.FRE is set to '1', software should clear it to
'0' and wait *at least* 500 milliseconds for PxCMD.FR to return '0' when
read.

It's "at least", not "up to".

Thanks,
Forrest

  reply	other threads:[~2006-06-02  9:21 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-02  7:44 [PATCH 2/6] The definition of ahci_start_fis_rx() and ahci_stop_fis_rx() zhao, forrest
2006-06-02  8:08 ` Hannes Reinecke
2006-06-02  9:15 ` Jens Axboe
2006-06-02  9:09   ` zhao, forrest [this message]
2006-06-02  9:26     ` Jens Axboe
2006-06-02  9:21       ` zhao, forrest
2006-06-03 12:51 ` Tejun Heo
2006-06-03 19:10   ` Jeff Garzik
  -- strict thread matches above, loose matches on Subject: below --
2006-06-06 10:16 zhao, forrest
2006-06-29  8:18 zhao, forrest
2006-07-10  3:35 zhao, forrest
2006-07-10 17:08 ` Jens Axboe
2006-07-11  6:37 zhao, forrest
2006-07-13  5:38 zhao, forrest

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=1149239367.29552.9.camel@forrest26.sh.intel.com \
    --to=forrest.zhao@intel.com \
    --cc=axboe@suse.de \
    --cc=hare@suse.de \
    --cc=htejun@gmail.com \
    --cc=jeff@garzik.org \
    --cc=jeremy@goop.org \
    --cc=linux-ide@vger.kernel.org \
    --cc=lkml@rtr.ca \
    /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;
as well as URLs for NNTP newsgroup(s).