From owner-freebsd-questions Wed Aug 12 02:04:01 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id CAA24069 for freebsd-questions-outgoing; Wed, 12 Aug 1998 02:04:01 -0700 (PDT) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from allegro.lemis.com (allegro.lemis.com [192.109.197.134]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id CAA24049 for ; Wed, 12 Aug 1998 02:03:42 -0700 (PDT) (envelope-from grog@freebie.lemis.com) Received: from freebie.lemis.com (freebie.lemis.com [192.109.197.137]) by allegro.lemis.com (8.9.1/8.9.0) with ESMTP id SAA16916; Wed, 12 Aug 1998 18:33:16 +0930 (CST) Received: (from grog@localhost) by freebie.lemis.com (8.9.1/8.9.0) id SAA28808; Wed, 12 Aug 1998 18:33:14 +0930 (CST) Message-ID: <19980812183314.J28142@lemis.com> Date: Wed, 12 Aug 1998 18:33:14 +0930 From: Greg Lehey To: Thomas Runge , "freebsd-questions@FreeBSD.ORG" Subject: Re: Aladdin V boards trouble References: <35D14E33.98645E0A@rostock.zgdv.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.93.2i In-Reply-To: <35D14E33.98645E0A@rostock.zgdv.de>; from Thomas Runge on Wed, Aug 12, 1998 at 10:11:31AM +0200 WWW-Home-Page: http://www.lemis.com/~grog Organization: LEMIS, PO Box 460, Echunga SA 5153, Australia Phone: +61-8-8388-8286 Fax: +61-8-8388-8725 Mobile: +61-41-739-7062 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Wednesday, 12 August 1998 at 10:11:31 +0200, Thomas Runge wrote: > Hi there. > > I've got a new Aladdin V based board. It has onboard > PCI IDE supporting PIO modes up to mode 5, Ultra DMA/33 and > 100 MHz CPU bus frequency (you may find a complete > description at http://www.ali.com.tw/av.htm). > > I built a kernel supporting multi sector and 32 bit transfers > including LBA support. This one works, but not fine. It > freezes my box on heavy disk usage very often. You don't say what version of FreeBSD. Since 2.x doesn't support UDMA, this must be -CURRENT, in which case you probably shouldn't be asking here. Since this is a question that will be asked more often, though, I'm not following up to -current. > I switched on some kernel options for debug messages and > getting this on failure: interrupt timeout: > status 50 error 1 wdtimeout() > DMA status 4. > > I find this message while booting: "ide_pci: generic_dma_init > 01f0:1: warning, IDE controller timing not set" and traced > it down to ide_pci.c. There I found, that my board isnt > explicitly supported, just some intel based ones. And the > generic DMA routines used by the kernel seem to have problems... I've checked this message, and it seems to me that it's telling me that your primary slave has not been set to run DMA. I get it on my machine too, for both slave drives: wdc0 at 0x1f0-0x1f7 irq 14 flags 0xa0ffa0ff on isa ide_pci: generic_dmainit 01f0:1: warning, IDE controller timing not set wdc0: unit 0 (wd0): , DMA, 32-bit, multi-block-32 wd0: 1223MB (2504880 sectors), 2485 cyls, 16 heads, 63 S/T, 512 B/S wdc1 at 0x170-0x177 irq 15 flags 0xa0ffa0ff on isa ide_pci: generic_dmainit 0170:1: warning, IDE controller timing not set wdc1: unit 0 (wd2): , DMA, 32-bit, multi-block-16 wd2: 6197MB (12692736 sectors), 12592 cyls, 16 heads, 63 S/T, 512 B/S It doesn't worry me overly, because these drives don't exist. Does your primary slave exist? It doesn't seem to be worried about the primary master. I don't think the fact that your chip isn't mentioned specifically means anything at all. I'm running an SiS chipset, and it's not mentioned either. > So, my question is, is there is a patch or work in progress > to support this board? Or is it possible to disable DMA > easily as long as there is no special driver for it? > Maybe this should be a kernel option? You can disable DMA with UserConfig. Boot with the -c option and select the visual configuration editor. The flags are described in wd(4). Here's a description extracted from "The Complete FreeBSD", second edition (http://www.cdrom.com/titles/os/bsdbook2.htm). A number of flags and options apply to wdc0: o The flags fields are used to enable the multi-sector I/O and the 32 bit I/O modes. You can use them either in the controller definition or in the individual disk definitions. If you want to use them during boot configuration, specify them in the controller definition. 16 flag bits are provided for each drive. The first 16 flag bits refer to drive 1, and the second 16 bits refer to drive 0. In each set of flags, o Bit 15 (0x8000) specifies to probe for 32 bit transfers. o Bit 14 (0x4000) enables waking powered-down laptop drives. o Bit 13 (0x2000) allows probing for PCI IDE DMA controllers, such as Intel's PIIX south bridges. o Bit 12 (0x1000) enables LBA (logical block addressing mode). If this bit is not set, the driver accesses the disk in CHS (cylinder/head/sector) mode. o In CHS mode, if bits 11 to 8 are not equal to 0, they specify the number of heads to assume (between 1 and 15). The driver recalculates the number of cylinders to make up the total size of the disk. o The low 8 bits specify the maximum number of sectors per transfer. The special case 0xff represents the maximum transfer size which the drive can handle. See the man page for wd(4) (on your system, but not in this book) for more details. Thus, we can break down the example value 0xff8004 (the full 32 bits are 0x00ff8004) into 0x00ff for drive 1 (use the maximum transfer size) and 0x8004 for drive 0 (allow probing for 32 bit support, and use a transfer size of 4 sectors). We use CHS addressing for this drive. Be warned: I've seen a 500% increase in CPU usage and a corresponding 80% decrease in throughput after disabling UDMA. > (And no, I wont disable these features in BIOS, as there is another > OS an my disk that I need and which supports it ;-> ) I don't think disabling them in the BIOS would make any difference. Having said all that, though, I think you're probably barking up the wrong tree. I'm guessing that, as in my case, the warning refers to a non-existent disk, and that your real problem lies elsewhere. I'd suspect the bus frequency. Have you tried turning your bus back down to 66 MHz? I'd guess that you're running into a sporadic hardware problem which is hitting you harder than your other operating system. The fact that the chipset isn't listed as being supported is probably not that significant. Greg -- See complete headers for address and phone numbers finger grog@lemis.com for PGP public key To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message