Bug 16071

Summary: ata driver has a race in ata_command
Product: Base System Reporter: Sam Leffler <sam>
Component: i386Assignee: Søren Schmidt <sos>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: 4.0-CURRENT   
Hardware: Any   
OS: Any   

Description Sam Leffler 2000-01-12 00:30:00 UTC
ata_command (1.39) sends a command before doing a tsleep to wait for the result.
If the device interrupts before tsleep is able to place the process on the sleep
queue then the interrupt will be missed.

Fix: 

I'll let Soren (sic?) do his own.
How-To-Repeat: Boot 4.0-CURRENT under vmware w/ the ata driver configured instead of the
wd driver.  Notice that no IDE devices are recognized; each gets a complaint:

ata_command: timeout waiting for interrupt

A little investigation shows the obvious race that's exasperated by operating
in a pseudo-synchronous environment.
Comment 1 Sheldon Hearn freebsd_committer freebsd_triage 2000-01-12 15:39:39 UTC
Responsible Changed
From-To: freebsd-bugs->sos

Over to Mr. ATA. 
Comment 2 Søren Schmidt freebsd_committer freebsd_triage 2000-02-28 19:17:49 UTC
State Changed
From-To: open->closed

Fixed in 4.0.