Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 9 May 2008 12:00:04 GMT
From:      Benjamin Close <Benjamin.Close@clearchain.com>
To:        freebsd-bugs@FreeBSD.org
Subject:   Re: kern/122847: [ata] atacontrol reports "ioctl(IOCATADEVICES): Device not configured" with ATI IXP600
Message-ID:  <200805091200.m49C04fC048532@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR kern/122847; it has been noted by GNATS.

From: Benjamin Close <Benjamin.Close@clearchain.com>
To: bug-followup@FreeBSD.org, arnaud.houdelette@tzim.net
Cc:  
Subject: Re: kern/122847: [ata] atacontrol reports "ioctl(IOCATADEVICES):
 Device not configured" with ATI IXP600
Date: Fri, 09 May 2008 21:05:49 +0930

 This bug occurs when there is missing controllers in the 0..n range. Ie, 
 if the box has controllers:
     ata2
     ata3
 
 via a atapci but no native controllers (ie ata0, ata1)
 
 atacontrol list
 
 Will fail to list any controllers.
 This is due to atacontrol requesting information about a non existent 
 channel (ata0) as it sequentially goes from 0..n (where n is obtained 
 from IOATAGMAXCHANNEL). ata(4) notices the invalid controller request 
 and returns EXIO. Hence atacontrol thinks it's an error and exits.
 
 A potential fix is at:
 
 http://lists.freebsd.org/pipermail/freebsd-stable/2008-April/041991.html
 
 However this simply avoids the real problem, that is, there needs to be 
 a way to ask the kernel what channels exist.
 One potential solution is to introduce a IOATAGCHANNELS ioctl which 
 returns a list of valid channels taking a struct like:
 
 struct ata_ioc_channels {
     int max;
     int channels[n];
 }
 
 
 and replace the MAXCHANNELS request.
 Till then the patch will ignore the error state.



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