linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Derek Taubert <taubert@geeks.org>
To: Tejun Heo <htejun@gmail.com>
Cc: Derek Taubert <taubert@geeks.org>, linux-ide@vger.kernel.org
Subject: Re: Bad write performance with libata-tj-stable-2.6.17.4-20060710, pcmcia based sata_sil24, PMP, and NCQ drive
Date: Sat, 2 Sep 2006 23:26:53 -0700	[thread overview]
Message-ID: <20060903062653.GA4340@geeks.org> (raw)
In-Reply-To: <20060902053459.GA4467@geeks.org>

On Fri, Sep 01, 2006 at 10:34:59PM -0700, Derek Taubert wrote:
> I'm now suspecting that the performance problems are due to bus issues
> on the PCMCIA/PCI side.  Will poke around there and maybe try this with
> a different laptop...

Found the problem!!!!

The Cache Line Size field in the 3124 PCI Config Space needed to be
set properly.  I suspect that this caused the 3124 DMA engine to issue
non-burst reads for all data going toward the disk.  Since my old
laptop has two bridges between host memory and the 3124, it surely made
for some long read latencies (and thus very bad throughput).

Before:
root@linux-srv:~ # od -Ax -t x4 /sys/bus/pci/devices/0000:06:00.0/config
000000 31241095 02b00087 01800001 00004000
000010 16008004 00000000 16000004 00000000
000020 00001c01 00000000 00000000 31241095
000030 00000000 00000064 00000000 0000010a
000040 00525407 12c3fff8 00000000 00000000
000050 00000000 00800005 00000000 00000000
000060 00000000 06224001 19002000 00000000
000070 00000000 00000000 00000000 00000000

I copied /sys/bus/pci/devices/0000:06:00.0/config to a temp file, used
bvi to edit it, and then copied it back using dd:
dd if=/tmp/sil24_config of=/sys/bus/pci/devices/0000:06:00.0/config bs=4 skip=3 seek=3 count=1 conv=notrunc

After:
root@linux-srv:~ # od -Ax -t x4 /sys/bus/pci/devices/0000:06:00.0/config
000000 31241095 02b00087 01800001 00004008
000010 16008004 00000000 16000004 00000000
000020 00001c01 00000000 00000000 31241095
000030 00000000 00000064 00000000 0000010a
000040 00525407 12c3fff8 00000000 00000000
000050 00000000 00800005 00000000 00000000
000060 00000000 06224001 19002000 00000000
000070 00000000 00000000 00000000 00000000

root@linux-srv:~ # dd if=/dev/zero of=/dev/sda1 bs=1M count=1000
1000+0 records in
1000+0 records out
1048576000 bytes (1.0 GB) copied, 16.7798 seconds, 62.5 MB/s

Phew!  I was just about to spend a ridiculous amount of money on ebay for
a logic analyzer...

I'm not sure if this will affect PCI-X configurations, but it is
certainly worth trying.

Derek

-- 
VGER BF report: H 0.104804

  reply	other threads:[~2006-09-03  6:26 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-28 23:01 Bad write performance with libata-tj-stable-2.6.17.4-20060710, pcmcia based sata_sil24, PMP, and NCQ drive Derek Taubert
2006-08-29  2:39 ` Tejun Heo
2006-08-29  4:58   ` Derek Taubert
2006-08-29  7:54     ` Derek Taubert
2006-08-29 13:35       ` Tejun Heo
2006-08-29 13:27     ` Tejun Heo
2006-08-29 16:44       ` Derek Taubert
2006-08-29 21:24         ` Jeff Garzik
2006-09-01 13:32         ` Tejun Heo
2006-09-01 17:24           ` Derek Taubert
2006-09-02  5:34             ` Derek Taubert
2006-09-03  6:26               ` Derek Taubert [this message]
2006-09-03 19:03                 ` Tejun Heo
2006-09-03 20:04                   ` Derek Taubert
2006-09-28 22:07                     ` Derek Taubert
2006-08-29 14:07   ` Greg Freemyer

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=20060903062653.GA4340@geeks.org \
    --to=taubert@geeks.org \
    --cc=htejun@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;
as well as URLs for NNTP newsgroup(s).