All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tejun Heo <htejun@gmail.com>
To: Grzegorz Kulewski <kangur@polcom.net>
Cc: Jeff Garzik <jeff@garzik.org>,
	linux-ide@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: libata_uli puts second channel to PIO4 on 2.6.18
Date: Wed, 07 Feb 2007 14:19:48 +0900	[thread overview]
Message-ID: <45C96174.2030407@gmail.com> (raw)
In-Reply-To: <Pine.LNX.4.63.0702030231150.6097@alpha.polcom.net>

Grzegorz Kulewski wrote:
> It worked very well for half a year but with one disk (IIRC it was even 
> plugged into second channel but I wont bet on it). Now I have second 
> disk (very similar) and it is always put into PIO4 mode:
> 
> [   17.404451] libata version 2.00 loaded.
> [   17.404916] sata_uli 0000:00:04.0: version 1.0
> [   17.405009] ACPI: PCI Interrupt 0000:00:04.0[A] -> GSI 18 (level, 
> low) -> IRQ 185
> [   17.405223] ata1: SATA max UDMA/133 cmd 0xD400 ctl 0xD002 bmdma 
> 0xB000 irq 185
> [   17.405385] ata2: SATA max UDMA/133 cmd 0xB800 ctl 0xB402 bmdma 
> 0xB008 irq 185
> [   17.405519] scsi2 : sata_uli
> [   17.858803] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
> [   17.880541] ata1.00: ATA-7, max UDMA/133, 488397168 sectors: LBA48 
> NCQ (depth 0/32)
> [   17.880660] ata1.00: ata1: dev 0 multi count 16
> [   17.888858] ata1.00: configured for UDMA/133
> [   17.888941] scsi3 : sata_uli
> [   18.342469] ata2: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
> [   18.343573] ata2.00: ATA-7, max UDMA/133, 488397168 sectors: LBA48 
> NCQ (depth 0/32)
> [   18.343691] ata2.00: ata2: dev 0 multi count 16
> [   18.344972] ata2.00: configured for PIO4

Some uli controllers have simplex bit stuck high indicating that they
can't perform DMA transfers simultaneously on both channels.  In this
case, libata configures the second channel as PIO only.  This has been
worked around by the following commit.

commit b2a8bbe67d73631c71492fd60b757fc50a87f182
Author: Tejun Heo <htejun@gmail.com>
Date:   Thu Jan 25 19:40:05 2007 +0900

    libata: implement ATA_FLAG_IGN_SIMPLEX and use it in sata_uli
    
    Some uli controllers have stuck SIMPLEX bit which can't be cleared
    with ata_pci_clear_simplex(), but the controller is capable of doing
    DMAs on both channels simultaneously.  Implement ATA_FLAG_IGN_SIMPLEX
    which makes libata ignore the simplex bit and use it in sata_uli.
    
    Signed-off-by: Tejun Heo <htejun@gmail.com>
    Signed-off-by: Jeff Garzik <jeff@garzik.org>

For quick fix, just comment out lines which set ATA_HOST_SIMPLEX in
drivers/scsi/libata-bmdma.c.  e.g.

	/*if (inb(bmdma + 2) & 0x80)
		probe_ent->host_set_flags |= ATA_HOST_SIMPLEX;*/

-- 
tejun


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

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-02-03  1:49 libata_uli puts second channel to PIO4 on 2.6.18 Grzegorz Kulewski
2007-02-06  1:49 ` Grzegorz Kulewski
2007-02-07  5:19 ` Tejun Heo [this message]
2007-02-11  4:14   ` Grzegorz Kulewski
2007-11-15  9:09     ` Patric Karlsson
2007-11-15  9:09       ` Patric Karlsson
2007-11-15  9:20       ` Patric Karlsson
2007-11-15  9:20         ` Patric Karlsson

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=45C96174.2030407@gmail.com \
    --to=htejun@gmail.com \
    --cc=jeff@garzik.org \
    --cc=kangur@polcom.net \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@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.