Re: ATA driver races with interrupts

From: Ville-Pertti Keinonen <will+freebsd-current_at_will.iki.fi>
Date: Tue, 03 Aug 2004 16:41:47 +0300
Daniel Eriksson wrote:

>Just tested this, and everything seems to work perfectly fine with only one
>disc attached. Stresstest works, SMART works, ...
>
>I've only tested it on one of the channels so far though, but I'm confident
>it will work on the other channel as well since I've used that channel in
>single-drive-configuration in the past without problems.
>  
>
The attached patch should enable serialization for the controller, which 
is the only completely reliable fix (without chipset documentation) 
according to Søren.  Obviously it reduces performance since it doesn't 
allow both channels to operate simultaneously.


Index: ata-chipset.c
===================================================================
RCS file: /cvs/freebsd/src/sys/dev/ata/ata-chipset.c,v
retrieving revision 1.77
diff -u -r1.77 ata-chipset.c
--- ata-chipset.c	30 Jul 2004 13:33:09 -0000	1.77
+++ ata-chipset.c	3 Aug 2004 13:32:04 -0000
_at__at_ -2602,6 +2602,7 _at__at_
     if (ctlr->chip->max_dma >= ATA_SA150) {
 	pci_write_config(dev, PCIR_COMMAND,
 			 pci_read_config(dev, PCIR_COMMAND, 2) & ~0x0400, 2);
+	ctlr->locking = ata_serialize;
 	ctlr->setmode = ata_sata_setmode;
 	return 0;
     }
Received on Tue Aug 03 2004 - 11:41:56 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:04 UTC