Skip to contentSkip to conversation

Patch for Promise PDC20276

PATCH Michel Bouissou 2 participants 5 messages Oct 27, 2003

lore
Share & tools
lore
#0 lore raw

Hi there,

The patch that Arne Brutschy posted here (see
http://www.cs.helsinki.fi/linux/linux-kernel/2003-22/0386.html) almost saved my life as it allowed me to understand why my 2.4.22 kernel didn't activate my Promise PDC20276 IDE controller properly.

(For the record, my kernel was displaying the following message at boot:
PDC20276: neither IDE port enabled (BIOS)
)

But this patch was only halfway satisfactory, as it enabled only one of my 2 controller channels.

So I did a quick-and-dirty hack that gives the following patch, that allows activation of both channels of my PDC20276.

This might help others encountering the same problem...

========== CUT HERE ==========

ide/setup-pci.c renamed from ide/setup-pci.c.orig +4 -4
@@ -577,7 +577,7 @@
 	ata_index_t index;
 	u8 tmp = 0;
 	ide_hwif_t *hwif, *mate = NULL;
-	static int secondpdc = 0;
+/* MiB	static int secondpdc = 0; */
 
 	index.all = 0xf0f0;
 
@@ -637,10 +637,10 @@
 		 * by the bios for raid purposes. 
 		 * Skip the normal "is it enabled" test for those.
 		 */
-		if (((d->vendor == PCI_VENDOR_ID_PROMISE) &&
+		if ((d->vendor == PCI_VENDOR_ID_PROMISE) &&
 		     ((d->device == PCI_DEVICE_ID_PROMISE_20262) ||
-		      (d->device == PCI_DEVICE_ID_PROMISE_20265))) &&
-		    (secondpdc++==1) && (port==1))
+		      (d->device == PCI_DEVICE_ID_PROMISE_20265) ||
+		      (d->device == PCI_DEVICE_ID_PROMISE_20276)))
 			goto controller_ok;
 			
 		if (e->reg && (pci_read_config_byte(dev, e->reg, &tmp) ||

========== CUT HERE ==========

Regards

Signature · 1 line
Michel Bouissou <[email protected]> OpenPGP ID 0xDDE8AC6E
#1 lore raw

This was discussed few times before.
Just enable "Special FastTrak feature" (overriding BIOS) config option.

Quoted 48 lines · Michel Bouissou

Hi there,

The patch that Arne Brutschy posted here (see
http://www.cs.helsinki.fi/linux/linux-kernel/2003-22/0386.html) almost saved my life as it allowed me to understand why my 2.4.22 kernel didn't activate my Promise PDC20276 IDE controller properly.

(For the record, my kernel was displaying the following message at boot:
PDC20276: neither IDE port enabled (BIOS)
)

But this patch was only halfway satisfactory, as it enabled only one of my 2 controller channels.

So I did a quick-and-dirty hack that gives the following patch, that allows activation of both channels of my PDC20276.

This might help others encountering the same problem...

========== CUT HERE ==========

ide/setup-pci.c renamed from ide/setup-pci.c.orig +4 -4
@@ -577,7 +577,7 @@
 	ata_index_t index;
 	u8 tmp = 0;
 	ide_hwif_t *hwif, *mate = NULL;
-	static int secondpdc = 0;
+/* MiB	static int secondpdc = 0; */
 
 	index.all = 0xf0f0;
 
@@ -637,10 +637,10 @@
 		 * by the bios for raid purposes.
 		 * Skip the normal "is it enabled" test for those.
 		 */
-		if (((d->vendor == PCI_VENDOR_ID_PROMISE) &&
+		if ((d->vendor == PCI_VENDOR_ID_PROMISE) &&
 		     ((d->device == PCI_DEVICE_ID_PROMISE_20262) ||
-		      (d->device == PCI_DEVICE_ID_PROMISE_20265))) &&
-		    (secondpdc++==1) && (port==1))
+		      (d->device == PCI_DEVICE_ID_PROMISE_20265) ||
+		      (d->device == PCI_DEVICE_ID_PROMISE_20276)))
 			goto controller_ok;
 
 		if (e->reg && (pci_read_config_byte(dev, e->reg, &tmp) ||

========== CUT HERE ==========

Regards

#2 lore raw
Quoted 3 lines · Bartlomiej Zolnierkiewicz

This was discussed few times before.
Just enable "Special FastTrak feature" (overriding BIOS) config option.

Uh. I may have misunderstood, but I understood that using this option would activate the controller's hardware RAID feature, which I don't want.

I need to use the controller as a normal, non-RAID, IDE controller (and if ever if was setup as hardware RAID, I'm afraid it would destroy my data..)

Cheers.

Signature · 1 line
Michel Bouissou <[email protected]> OpenPGP ID 0xDDE8AC6E
#3 lore raw
Quoted 6 lines · Michel Bouissou
Quoted 2 lines · Bartlomiej Zolnierkiewicz

This was discussed few times before.
Just enable "Special FastTrak feature" (overriding BIOS) config option.

Uh. I may have misunderstood, but I understood that using this option would activate the controller's hardware RAID feature, which I don't want.

Quite opposite, it makes Linux use controller even if it was marked by BIOS as disabled (for RAID purposes).

Quoted 2 lines

I need to use the controller as a normal, non-RAID, IDE controller (and if ever if was setup as hardware RAID, I'm afraid it would destroy my data..)

It is software RAID (in BIOS/drivers) with propertiary format.

cheers,
--bartlomiej

#4 lore raw
Quoted 7 lines · Bartlomiej Zolnierkiewicz
Quoted 4 lines

Uh. I may have misunderstood, but I understood that using this option would activate the controller's hardware RAID feature, which I don't want.

Quite opposite, it makes Linux use controller even if it was marked by BIOS as disabled (for RAID purposes).

So the Configure.help help text associated with this option is definitely unclear (I would say: misleading) because it barely says (in kernel 2.4.22):

<<<<<
Special FastTrak Feature
CONFIG_PDC202XX_FORCE
For FastTrak enable overriding BIOS.

Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

And I understood this as meaning <<enable the "FastTrak" RAID feature regardless of what BIOS says>>

Hmmmm...

Signature · 1 line
Michel Bouissou <[email protected]> OpenPGP ID 0xDDE8AC6E