Problem with Promise SATA-II 150 TX4 Controller (rev 2) [105a:3d18]
Hi Jeff / all,
I got myself a PDC20518 SATAII 150 IDE Controller by Promise, which has PCI ID 105a:3d18 (listed in PCIID database on sf.net) and claims Linux kernel support in its handbook. It is listed as a dubious candidate at http://www.linuxmafia.com/faq/Hardware/sata.html, it seems, which is why I am CCing Rick.
Running lspci -vvv shows it as
0000:02:0c.0 Unknown mass storage controller: Promise Technology, Inc. PDC20518 SATAII 150 IDE Controller (rev 02)
Subsystem: Promise Technology, Inc. PDC20518 SATAII 150 IDE Controller
Control: I/O+ Mem+ BusMaster- SpecCycle- MemWINV+ VGASnoop- ParErr- Stepping- SERR+ FastB2B-
Status: Cap+ 66MHz+ UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
Interrupt: pin A routed to IRQ 20
Region 0: I/O ports at d080 [size=128]
Region 2: I/O ports at de00 [size=256]
Region 3: Memory at feafd000 (32-bit, non-prefetchable) [size=4K]
Region 4: Memory at feac0000 (32-bit, non-prefetchable) [size=128K]
Expansion ROM at feab0000 [disabled] [size=32K]
Capabilities: [60] Power Management version 2
Flags: PMEClk- DSI+ D1+ D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
Status: D0 PME-Enable- DSel=0 DScale=0 PME-
On first attempt, neither the sata_promise nor sata_tx4 drivers of kernel 2.6.10 recognize the controller.
The second shot was another driver offered by Promise for download at
http://www.promise.com/support/download/download2_eng.asp?productId=129&category=All&os=100
which seems to consist of a wrapper/kernel module under the GNU GPL called pdc-ulsata2, which itself incorporates a "Common Access Module with Linux Serial ATA Driver" (CAM); this CAM appears to be proprietary and is marked Copyright (c) 2002 Promise Technology.
But even if one felt like ignoring the messy license situation, which I really don't, the driver does not build out of the box with kernel 2.6.10. Spending much time on that driver seems wasted as long as it is proprietary, anyway.
So as a third shot, I brutally added the PCI ID to sata_promise.c, recompiled and gave it a try. Here is the syslog output:
sata_promise version 1.01
ACPI: PCI interrupt 0000:02:0c.0[A] -> GSI 20 (level, low) -> IRQ 20
ata3: SATA max UDMA/133 cmd 0xF8BD8200 ctl 0xF8BD8238 bmdma 0x0 irq 20
ata4: SATA max UDMA/133 cmd 0xF8BD8280 ctl 0xF8BD82B8 bmdma 0x0 irq 20
ata5: SATA max UDMA/133 cmd 0xF8BD8300 ctl 0xF8BD8338 bmdma 0x0 irq 20
ata6: SATA max UDMA/133 cmd 0xF8BD8380 ctl 0xF8BD83B8 bmdma 0x0 irq 20
ata3: no device found (phy stat 00000000)
scsi4 : sata_promise
ata4: dev 0 cfg 49:2f00 82:346b 83:7d01 84:4003 85:3469 86:3c01 87:4003 88:407f
ata4: dev 0 ATA, max UDMA/133, 390721968 sectors: lba48
ata4: dev 0 configured for UDMA/133
scsi5 : sata_promise
ata5: no device found (phy stat 00000000)
scsi6 : sata_promise
irq 20: nobody cared!
[__report_bad_irq+34/128] __report_bad_irq+0x22/0x80 [note_interrupt+80/128] note_interrupt+0x50/0x80 [__do_IRQ+281/288] __do_IRQ+0x119/0x120
[do_IRQ+26/48] do_IRQ+0x1a/0x30
[common_interrupt+26/32] common_interrupt+0x1a/0x20 [default_idle+42/64] default_idle+0x2a/0x40
[cpu_idle+70/112] cpu_idle+0x46/0x70
[start_kernel+329/368] start_kernel+0x149/0x170
handlers:
[pg0+944219616/1068004352] (ohci_irq_handler+0x0/0x6b0 [ohci1394]) [pg0+946226192/1068004352] (pdc_interrupt+0x0/0x1a0 [sata_promise]) Disabling IRQ #20
ata6: dev 0 cfg 49:2f00 82:346b 83:7d01 84:4003 85:3469 86:3c01 87:4003 88:407f
ata6: dev 0 ATA, max UDMA/133, 390721968 sectors: lba48
Well, this looks like it *almost* worked and might be made to work without too much hassle by someone who knows what he/she is doing. (Jeff?)
All help very much appreciated.
If you need more info, please let me know.
Regards,
Georg
Signature · 4 lines
Georg C. F. Greve <[email protected]> Free Software Foundation Europe (http://fsfeurope.org) GNU Business Network (http://mailman.gnubiz.org) Brave GNU World (http://brave-gnu-world.org)
[update]
After some more investigation, I stumbled upon the thread that dealt with the Promise 579 in October 2004, which contained a similar situation and error message with the proposed fix at
http://marc.theaimsgroup.com/?l=linux-ide&m=109814647928388&w=2
so I made the changes
drivers/scsi/sata_promise.c +4 -1
@@ -160,10 +160,11 @@ static struct pci_device_id pdc_ata_pci_ board_20319 }, {PCI_VENDOR_ID_PROMISE ,0x3319 ,PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 , board_20319 }, + { PCI_VENDOR_ID_PROMISE, 0x3d18, PCI_ANY_ID, PCI_ANY_ID, 0, 0, + board_20319 }, { } /* terminate list */ }; -static struct pci_driver pdc_ata_pci_driver = { .name =DRV_NAME , .id_table = pdc_ata_pci_tbl,
@@ -408,6 +409,8 @@ static irqreturn_t pdc_interrupt (int irspin_lock (&host_set->lock); +writel (mask, mmio_base +PDC_INT_SEQMASK ); +for (i =0 ; i < host_set->n_ports; i++) {VPRINTK ("port %u\n" , i); ap = host_set->ports[i];
and recompiled.
When rebooting, this was the dmesg output
sata_promise version 1.01
ACPI: PCI interrupt 0000:02:0c.0[A] -> GSI 20 (level, low) -> IRQ 20
ata3: SATA max UDMA/133 cmd 0xF881A200 ctl 0xF881A238 bmdma 0x0 irq 20
ata4: SATA max UDMA/133 cmd 0xF881A280 ctl 0xF881A2B8 bmdma 0x0 irq 20
ata5: SATA max UDMA/133 cmd 0xF881A300 ctl 0xF881A338 bmdma 0x0 irq 20
ata6: SATA max UDMA/133 cmd 0xF881A380 ctl 0xF881A3B8 bmdma 0x0 irq 20
ata3: no device found (phy stat 00000000)
scsi4 : sata_promise
ata4: dev 0 cfg 49:2f00 82:346b 83:7d01 84:4003 85:3469 86:3c01 87:4003 88:407f
ata4: dev 0 ATA, max UDMA/133, 390721968 sectors: lba48
ata4: dev 0 configured for UDMA/133
scsi5 : sata_promise
ata5: no device found (phy stat 00000000)
scsi6 : sata_promise
ata6: dev 0 cfg 49:2f00 82:346b 83:7d01 84:4003 85:3469 86:3c01 87:4003 88:407f
ata6: dev 0 ATA, max UDMA/133, 390721968 sectors: lba48
ata6: dev 0 configured for UDMA/133
scsi7 : sata_promise
Vendor: ATA Model: ST3200822AS Rev: 3.01 Type: Direct-Access ANSI SCSI revision: 05 Vendor: ATA Model: ST3200822AS Rev: 3.01 Type: Direct-Access ANSI SCSI revision: 05
which does not yet look perfect, but it seems to work.
The disks are present in the system and can be partitioned. Will let you know in case I run into problems.
Any chance to have the adapter supported in the next release? :)
Regards,
Georg
Signature · 3 lines
Georg C. F. Greve <[email protected]> Free Software Foundation Europe (http://fsfeurope.org) Brave GNU World (http://brave-gnu-world.org)
sata_promise support for pci id 0x3d18 {Re: Problem with Promise SATA-II 150 TX4 Controller (rev 2) [105a:3d18]}
Hi Georg, Jeff, Rick, linux-ide,
Quoted 7 lines · Georg C. F. Greve
After some more investigation, I stumbled upon the thread that dealt with the Promise 579 in October 2004, which contained a similar situation and error message with the proposed fix at
http://marc.theaimsgroup.com/?l=linux-ide&m=109814647928388&w=2
so I made the changes
I also made this changes right now and it seems to work quite fine, we already copied several GB without any error, both the filesystem (no kernel messages) and the data (compared md5sums) seem to be fine.
This is a Promise SATA-II 150 TX4 on a Intel motherboard with four Maxtor 6B200M0 disks connected to it.
Chris
Quoted 24 lines
drivers/scsi/sata_promise.c +4
-1@@ -160,10 +160,11 @@ static struct pci_device_id pdc_ata_pci_ board_20319 }, {PCI_VENDOR_ID_PROMISE ,0x3319 ,PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 , board_20319 }, + { PCI_VENDOR_ID_PROMISE, 0x3d18, PCI_ANY_ID, PCI_ANY_ID, 0, 0, + board_20319 }, { } /* terminate list */ }; -static struct pci_driver pdc_ata_pci_driver = { .name =DRV_NAME , .id_table = pdc_ata_pci_tbl,@@ -408,6 +409,8 @@ static irqreturn_t pdc_interrupt (int irspin_lock (&host_set->lock); +writel (mask, mmio_base +PDC_INT_SEQMASK ); +for (i =0 ; i < host_set->n_ports; i++) {VPRINTK ("port %u\n" , i); ap = host_set->ports[i];
Signature · 4 lines
Everything is gone; Your life's work has been destroyed. Squeeze trigger (yes/no)? -- David Carlson
Quoted 7 lines · Georg C. F. Greve
[update]
After some more investigation, I stumbled upon the thread that dealt with the Promise 579 in October 2004, which contained a similar situation and error message with the proposed fix at
http://marc.theaimsgroup.com/?l=linux-ide&m=109814647928388&w=2
a version of this patch will be appearing in the upstream kernel soon.
Jeff