Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 30 Aug 1997 01:08:43 -0400 (EDT)
From:      john hood <cgull@smoke.marlboro.vt.us>
To:        Greg Lehey <grog@lemis.com>
Cc:        Warner Losh <imp@rover.village.org>, freebsd-hackers@FreeBSD.ORG
Subject:   Re: New warning, should I worry?
Message-ID:  <199708300508.BAA20739@smoke.marlboro.vt.us>
In-Reply-To: <19970830120049.38856@lemis.com>
References:  <E0x4UNY-0007TH-00@rover.village.org> <199708292257.SAA20076@smoke.marlboro.vt.us> <19970830120049.38856@lemis.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Greg Lehey writes:
 > What kind of feedback would you like?  I'm getting it too, if that
 > interests you, and I *do* have one IDE drive.  I also thought it was
 > set up for DMA.  Do I need to do anything?  Here are the messages:

The longer and more complicated explanation:

On busmastering controllers, there's a R/W bit in one of the status
registers for each drive.  This bit doesn't affect or reflect any
hardware state, but is supposed to be used by BIOS or device driver
software to indicate that the drive and controller have been
configured for use with DMA (there are timing parameters that have to
be setup on drive and controller).

Early on in development, I wasn't clear on what various BIOSes did--
whether they did the programming and set this bit, or did the
programming and didn't set the bit, or didn't do anything, or
(hopefully not!) didn't do the programming and did set the bit.
There's another heuristic for deciding whether or not the programming
has been done, but I wasn't sure it was good enough.  Bad timing
configuration could lead to all sorts of nasty data corruption, so I
had the driver spew that message when the configuration-done bit
hadn't been set, to scare people into remembering they were playing
with alpha software.  And so, the controversy over a slightly bizarre
warning and the bootlogs that I've seen go by in mail have given me
some useful indications of what BIOSes do.

It seems that although most BIOSes do a reasonable job of configuring
the controller and drive, they don't set this bit;  and the heuristic
seems to work well enough that it was OK to take out the warning.

I've changed the message so it only appears when the bit is set (DMA
has been configured) and the boot -v flag is set.  I'm still modestly
curious to hear reports of motherboards and controller BIOSes that do
set it (they're unusual), but I no longer need to know in order to get
things working.

As far as I know, nobody needs to do anything about any of the
messages now, unless 1) your IDE hard drives don't work or you're
losing data, or 2) you know enough about IDE to read the register dump
and casually spot some bad configuration.  In either case, you should
let me know.

If the wd driver reports "DMA," as part of the drive inquiry, it is
using DMA to transfer data to and from the drive:

wdc0: unit 0 (wd0): <IBM-DAQA-33240>, DMA, 32-bit, multi-block-16

  --jh

-- 
John Hood				cgull@smoke.marlboro.vt.us

Predictably, they all eventually wandered away, rubbing their bruises
and brushing mud out of their hair.  Some went off to work for the
ESA, launching much smaller rockets into low orbits, while others
elected to sit on their front porches drinking Jim Beam from the
bottle and launching bottle rockets from the empties. [Jordan Hubbard]




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199708300508.BAA20739>