On Wed, Jan 12, 2011 at 08:32:12PM -0500, Brad wrote:
> The following diff is ported from NetBSD (the workaround originated from
> OpenSolaris) to workaround the issue of data corruption with the ALI M5229
> IDE chipset when using UltraDMA. Same workaround is also used by 
> FreeBSD/Linux.
> This chipset is found in some sparc64 systems such as the Blade 100 and
> Netra X1.
> 
> I don't have any such systems but I went digging for this being curious
> why the nasty hack was added to the kernel configs to disable UltraDMA
> to workaround this bug and thus penalizing other IDE/SATA controllers
> that could be in the same system. If you have one of the mentioned
> systems please test this.

Here is the alternate workaround for the time being.

Please test.


Index: dev/pci/pciide.c
===================================================================
RCS file: /home/cvs/src/sys/dev/pci/pciide.c,v
retrieving revision 1.323
diff -u -p -r1.323 pciide.c
--- dev/pci/pciide.c    18 Nov 2010 18:12:52 -0000      1.323
+++ dev/pci/pciide.c    21 Jan 2011 00:19:49 -0000
@@ -5639,6 +5639,10 @@ acer_chip_map(struct pciide_softc *sc, s
                        sc->sc_wdcdev.cap |= WDC_CAPABILITY_UDMA;
                        if (rev >= 0xC4)
                                sc->sc_wdcdev.UDMA_cap = 5;
+#ifdef __sparc64__
+                       else if (rev == 0xC3)
+                               sc->sc_wdcdev.UDMA_cap = 2;
+#endif
                        else if (rev >= 0xC2)
                                sc->sc_wdcdev.UDMA_cap = 4;
                        else
Index: arch/sparc64/conf/GENERIC
===================================================================
RCS file: /home/cvs/src/sys/arch/sparc64/conf/GENERIC,v
retrieving revision 1.262
diff -u -p -r1.262 GENERIC
--- arch/sparc64/conf/GENERIC   8 Jan 2011 11:56:30 -0000       1.262
+++ arch/sparc64/conf/GENERIC   15 Jan 2011 18:44:11 -0000
@@ -382,7 +382,7 @@ stty*               at spif?
 sbpp*          at spif?
 
 pciide*        at pci? flags 0x0000
-wd*    at pciide? flags 0x0a00
+wd*    at pciide? flags 0x0000
 atapiscsi* at pciide?
 scsibus* at atapiscsi?
 
Index: arch/sparc64/conf/RAMDISK
===================================================================
RCS file: /home/cvs/src/sys/arch/sparc64/conf/RAMDISK,v
retrieving revision 1.98
diff -u -p -r1.98 RAMDISK
--- arch/sparc64/conf/RAMDISK   19 Apr 2010 10:44:33 -0000      1.98
+++ arch/sparc64/conf/RAMDISK   11 Jan 2011 23:41:13 -0000
@@ -151,7 +151,7 @@ ti* at sbus?
 gem*   at sbus?
 
 pciide*        at pci? flags 0x0000
-wd*    at pciide? flags 0x0a00
+wd*    at pciide? flags 0x0000
 atapiscsi* at pciide?
 scsibus* at atapiscsi?
 
Index: arch/sparc64/conf/RAMDISKU5
===================================================================
RCS file: /home/cvs/src/sys/arch/sparc64/conf/RAMDISKU5,v
retrieving revision 1.16
diff -u -p -r1.16 RAMDISKU5
--- arch/sparc64/conf/RAMDISKU5 24 Jun 2009 11:38:40 -0000      1.16
+++ arch/sparc64/conf/RAMDISKU5 11 Jan 2011 23:41:30 -0000
@@ -55,7 +55,7 @@ pcons0        at mainbus0             # PROM console
 timer* at mainbus0             # Timer chip (some systems)
 
 pciide*        at pci? flags 0x0000
-wd*    at pciide? flags 0x0a00
+wd*    at pciide? flags 0x0000
 atapiscsi* at pciide?
 scsibus* at atapiscsi?
 

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

Reply via email to