From owner-freebsd-hackers Wed Feb 20 7:53:52 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from duke.cs.duke.edu (duke.cs.duke.edu [152.3.140.1]) by hub.freebsd.org (Postfix) with ESMTP id C1C2C37B400; Wed, 20 Feb 2002 07:53:03 -0800 (PST) Received: from grasshopper.cs.duke.edu (grasshopper.cs.duke.edu [152.3.145.30]) by duke.cs.duke.edu (8.9.3/8.9.3) with ESMTP id KAA18131; Wed, 20 Feb 2002 10:53:03 -0500 (EST) Received: (from gallatin@localhost) by grasshopper.cs.duke.edu (8.11.6/8.9.1) id g1KFqXF62239; Wed, 20 Feb 2002 10:52:33 -0500 (EST) (envelope-from gallatin@cs.duke.edu) From: Andrew Gallatin MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15475.50753.252494.269972@grasshopper.cs.duke.edu> Date: Wed, 20 Feb 2002 10:52:33 -0500 (EST) To: sos@freebsd.org Cc: freebsd-hackers@freebsd.org Subject: Serverworks ATA controller & data corruption X-Mailer: VM 6.75 under 21.1 (patch 12) "Channel Islands" XEmacs Lucid Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, I have a few machines with the following ata controller: atapci0@pci0:15:1: class=0x01018a card=0x00000000 chip=0x02111166 rev=0x00 hdr=0x00 vendor = 'Reliance Computer Corp./ServerWorks' device = 'OSB4 PCI EIDE Controller' class = mass storage subclass = ATA They're dual-boot FreeeBSD/linux boxes. After loosing 2 filesystems in linux, I did a web search and I found that linux has a problem with data corruption when using these controllers & disabled IDE DMA in linux. Thinking that FreeBSD was immune (these boxes spend 90% of their time in FreeBSD doing driver development & crashing frequently, haven't lost a fs yet), I continued to run the disk at UDMA33 in FreeBSD. However, I began to notice very minor data corruption when I attempted to buildworld them from 4.4-RELEASE to 4.5-STABLE. By minor, I mean syntax errors in files caused by 4 characters moved a few lines up or down in a file, things like that. I concluded that FreeBSD might not be immune after all and switched to PIO. After checking out a new src tree, the problem seems to be gone and I'm able to buildworld. Do you think it would be wise to disable DMA by default on these chips? Cheers, Drew PS: Here's a dmesg Copyright (c) 1992-2002 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD 4.5-STABLE #2: Wed Feb 20 09:33:56 EST 2002 gallatin@ugly:/usr/src/sys/compile/SMP Timecounter "i8254" frequency 1193182 Hz CPU: Pentium III/Pentium III Xeon/Celeron (999.53-MHz 686-class CPU) Origin = "GenuineIntel" Id = 0x68a Stepping = 10 Features=0x383fbff real memory = 536805376 (524224K bytes) avail memory = 517681152 (505548K bytes) Programming 16 pins in IOAPIC #0 IOAPIC #0 intpin 2 -> irq 0 Programming 16 pins in IOAPIC #1 FreeBSD/SMP: Multiprocessor motherboard cpu0 (BSP): apic id: 0, version: 0x00040011, at 0xfee00000 cpu1 (AP): apic id: 1, version: 0x00040011, at 0xfee00000 io0 (APIC): apic id: 4, version: 0x000f0011, at 0xfec00000 io1 (APIC): apic id: 5, version: 0x000f0011, at 0xfec01000 Preloaded elf kernel "kernel" at 0xc0488000. Pentium Pro MTRR support enabled md0: Malloc disk Using $PIR table, 9 entries at 0xc00f5250 npx0: on motherboard npx0: INT 16 interface pcib0: on motherboard IOAPIC #1 intpin 15 -> irq 2 IOAPIC #0 intpin 10 -> irq 5 pci0: on pcib0 fxp0: port 0xd800-0xd83f mem 0xfc800000-0xfc8fffff,0xfc9fe000-0xfc9fefff irq 2 at device 6.0 on pci0 fxp0: Ethernet address 00:30:48:21:e4:47 inphy0: on miibus0 inphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto isab0: at device 15.0 on pci0 isa0: on isab0 atapci0: port 0xffa0-0xffaf at device 15.1 on pci0 ata0: at 0x1f0 irq 14 on atapci0 ata1: at 0x170 irq 15 on atapci0 ohci0: mem 0xfc9ff000-0xfc9fffff irq 5 at device 15.2 on pci0 usb0: OHCI version 1.0, legacy support usb0: on ohci0 usb0: USB revision 1.0 uhub0: (unknown) OHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub0: 4 ports with 4 removable, self powered pcib1: on motherboard IOAPIC #1 intpin 8 -> irq 9 IOAPIC #1 intpin 10 -> irq 10 pci1: on pcib1 pci1: at 1.0 irq 9 pci1: (vendor=0x14c1, dev=0x8043) at 2.0 irq 10 orm0: