Announce FreeBSD -stable Promise SATA and Intel ICH SATA patches

Doug Ambrisko ambrisko at
Thu Mar 25 15:28:05 PST 2004

I've added support for the Promise SATA TX2/TX4 cards and Intel ICH5/6300ESB
SATA chips.  The big challenges that SATA errors tend to lock-up the
system unless you read the SATA registers or deal with the controller
errors via their error registers.  If you ignore them and just
continue with normal ATA controller commands the system will lock up.

Some functions need to be renamed.  The patch set it at:
and applies src.  A make world is a good idea.

Here is the README at the top of the patch set:
The basic Promise support came from -current.  Everything else was 
developed in -stable and trying not to change the core -stable code to 
reduce maintainance burdens.  The goal was to make the most minimal 
changes to -stable as possible and at the same time create a robust system 
to deal with disk failures.

Thanks to Promise for programing information. ICH SATA support came
from the Intel doc's.

Features added/bug fixes:
      -	Support for Promise SATA TX2/TX4 controllers mostly from -current
      -	Support for reading hot-swap evens and tearing down the device
	when removed.  A few kernel panics fixes when things disappear.
      -	Changing the ata system so it mostly runs out from under splbio
	so that we can get interrupts to tell us a drive is gone.  If that
	is ignored then the controller can lock up the system.  This
	required a work thread to run through channel requests.  A shim
	to ata_start was used to implement this.  This gets the
	code-excution path away from splbio.
      -	Clamping the size of the disk when making a RAID.
      -	The ATA_IN/ATA_OUT macros were re-done so that the existing
	code would not need to be modified.  It was was more space
	in the softc to hold the arrays for the memory regions.  This is
	better to reduce maintainance burden.  Minor code changes in
	allocation clean-up had to be changed.
      -	MFC of addspare.
      - add support for SATA error handling of ICH5 & 6300ESB (we need
	to read the SATA registers.  Note we could detect hot swap
	if we polled on the sstatus register.  Map SATA drives into
	which parts of the controller they are on.
      -	the Promise channel needs to be reset on error (such as a 
	media error) or it will hang on further I/O (ie. in ata_intr)
      -	Fixed a PIO bug in which there is an under-flow & buffer over-flow
      -	On media error don't fall back to PIO on some the Intel SATA or
	Promise SATA devices.  This doesn't help much and kill performance.
	Fail out I/O straight from DMA mode gracefully.
      -	Add some more ICH device ID's.  Update to new ICH UDMA flags.

Potential Issues/brokeness
      -	kernel core dumps should work not tested
      -	Tagged Queuing should work not tested

Known issues:
      -	The RAID doesn't automatically rebuild need to run "atacontrol 
	rebuild ar0" sort-of works.

Let me know of any success or failures using this patches.  I will be working
on bringing these features into -current.  My target deployment for this
was -stable.


Doug A.

More information about the freebsd-stable mailing list