All of lore.kernel.org
 help / color / mirror / Atom feed
From: Milan Kupcevic <milan@physics.harvard.edu>
To: Jeff Garzik <jgarzik@pobox.com>
Cc: linux-ide@vger.kernel.org, linux-scsi@vger.kernel.org,
	linux-kernel@vger.kernel.org, trivial@rustcorp.com.au,
	torvalds@osdl.org
Subject: [PATCH] sata_promise: Port enumeration order - SATA 150 TX4, SATA 300 TX4
Date: Fri, 24 Feb 2006 20:09:17 -0500	[thread overview]
Message-ID: <43FFAE3D.7010002@physics.harvard.edu> (raw)

From: Milan Kupcevic <milan@physics.harvard.edu>

Fix Promise SATAII 150 TX4 (PDC40518) and Promise SATA 300 TX4 
(PDC40718-GP) wrong port enumeration order that makes it (nearly) 
impossible to deal with boot problems using two or more drives.

Signed-off-by: Milan Kupcevic <milan@physics.harvard.edu>
---

The current kernel driver assumes:

port 1 - scsi3
port 2 - scsi1
port 3 - scsi0
port 4 - scsi2

Having 4 hard drives connected to the controller grub recognizes the 
port 1 connected drive as "(hd0)" but kernel recognizes the port 3 
connected drive as scsi0:0:0:0 (/dev/sda). There is no clean way to make 
it boot correctly.

 sata_promise.c |   16 ++++++++++------
 1 files changed, 10 insertions(+), 6 deletions(-)

diff -uprN ./drivers/scsi/sata_promise.c 
../linux/drivers/scsi/sata_promise.c
--- ./drivers/scsi/sata_promise.c       2006-02-17 17:23:45.000000000 -0500
+++ ../linux/drivers/scsi/sata_promise.c        2006-02-24 
19:35:16.000000000 -0500
@@ -707,14 +707,18 @@ static int pdc_ata_init_one (struct pci_
 
        /* notice 4-port boards */
        switch (board_idx) {
-       case board_20319:
+       case board_20319: /* tx4  */
                        probe_ent->n_ports = 4;
 
-               pdc_ata_setup_port(&probe_ent->port[2], base + 0x300);
-               pdc_ata_setup_port(&probe_ent->port[3], base + 0x380);
-
-               probe_ent->port[2].scr_addr = base + 0x600;
-               probe_ent->port[3].scr_addr = base + 0x700;
+               pdc_ata_setup_port(&probe_ent->port[0], base + 0x380);
+               pdc_ata_setup_port(&probe_ent->port[1], base + 0x280);
+               pdc_ata_setup_port(&probe_ent->port[2], base + 0x200);
+               pdc_ata_setup_port(&probe_ent->port[3], base + 0x300);
+
+               probe_ent->port[0].scr_addr = base + 0x700;
+               probe_ent->port[1].scr_addr = base + 0x500;
+               probe_ent->port[2].scr_addr = base + 0x400;
+               probe_ent->port[3].scr_addr = base + 0x600;
                break;
        case board_2037x:
                probe_ent->n_ports = 2;

-- 
Milan Kupcevic
System Administrator
Harvard University
Department of Physics


             reply	other threads:[~2006-02-25  1:09 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-02-25  1:09 Milan Kupcevic [this message]
2006-02-25  1:16 ` [PATCH] sata_promise: Port enumeration order - SATA 150 TX4, SATA 300 TX4 Jeff Garzik
2006-02-25  1:42   ` Milan Kupcevic
2006-02-25  6:59 ` Eyal Lebedinsky
2006-02-25 10:52   ` Christiaan den Besten
2006-02-25 10:52     ` Christiaan den Besten
2006-03-31 22:52     ` Fabian Knittel
2006-05-30 21:31       ` Milan Kupcevic
2006-06-06 17:27         ` Fabian Knittel
2006-10-02 22:08         ` Evan Harris
2006-12-16 17:09           ` Jeff Garzik
2006-02-26 19:55 ` Oliver Joa
2006-02-26 19:56 ` Oliver Joa
  -- strict thread matches above, loose matches on Subject: below --
2009-10-03 22:12 Walter Hutchins
2009-10-05 10:49 ` Mikael Pettersson

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=43FFAE3D.7010002@physics.harvard.edu \
    --to=milan@physics.harvard.edu \
    --cc=jgarzik@pobox.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=torvalds@osdl.org \
    --cc=trivial@rustcorp.com.au \
    /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.