From owner-freebsd-drivers@FreeBSD.ORG Mon Sep 22 17:51:02 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9B7701065670 for ; Mon, 22 Sep 2008 17:51:02 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id 79FA08FC0A for ; Mon, 22 Sep 2008 17:51:02 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id 151AB1A90FF for ; Mon, 22 Sep 2008 10:46:47 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id SennQUE+Ivx6 for ; Mon, 22 Sep 2008 10:46:46 -0700 (PDT) Received: from [10.0.0.40] (iago.office.miralink.com [10.0.0.40]) by plato.miralink.com (Postfix) with ESMTP id BAD191A90FE for ; Mon, 22 Sep 2008 10:46:46 -0700 (PDT) Message-ID: <48D7DB05.6050907@miralink.com> Date: Mon, 22 Sep 2008 10:51:01 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.16 (X11/20080723) MIME-Version: 1.0 To: freebsd-drivers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: [RELENG_6] ATARAID oddity X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 22 Sep 2008 17:51:02 -0000 I stumbled upon some strange behavior when conducting some SCSI target testing in my lab that caused me to do a double-take. If a FreeBSD system detects a drive with Adaptec RAID controller meta data on it, the ataraid() driver will attempt to interpret that data as a real volume. It makes no difference to the ataraid() driver if there is an Adaptec controller physically present in the system or not. I.e. if you insert a drive that was part of a volume from an Adaptec RAID controller into another system, the new system will attempt to treat that disk as though it were associated with a HOST Raid controller. I don't think that this is the desired behavior. Even if the host raid meta-data is detected, the system shouldn't attempt to treat the disk as part of a HOST raid set without the appropriate controller in the system. -- Sean Bruno MiraLink Corporation 6015 NE 80th Ave, Ste 100 Portland, OR 97218 Phone 503-621-5143 Fax 503-621-5199 MSN: sbruno@miralink.com Google: seanwbruno@gmail.com Yahoo: sean_bruno@yahoo.com From owner-freebsd-drivers@FreeBSD.ORG Mon Sep 22 22:38:58 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4D6631065672 for ; Mon, 22 Sep 2008 22:38:58 +0000 (UTC) (envelope-from freebsd@sopwith.solgatos.com) Received: from parsely.rain.com (parsely.rain.com [199.26.172.196]) by mx1.freebsd.org (Postfix) with ESMTP id 902608FC21 for ; Mon, 22 Sep 2008 22:38:57 +0000 (UTC) (envelope-from freebsd@sopwith.solgatos.com) Received: from sopwith.solgatos.com (uucp@localhost) by parsely.rain.com (8.11.4/8.11.4) with UUCP id m8MMAmW55103 for freebsd-drivers@freebsd.org; Mon, 22 Sep 2008 15:10:48 -0700 (PDT) (envelope-from freebsd@sopwith.solgatos.com) Received: from localhost by sopwith.solgatos.com (8.8.8/6.24) id WAA20882; Mon, 22 Sep 2008 22:03:38 GMT Message-Id: <200809222203.WAA20882@sopwith.solgatos.com> To: freebsd-drivers@freebsd.org In-reply-to: Your message of "Mon, 22 Sep 2008 10:51:01 PDT." <48D7DB05.6050907@miralink.com> Date: Mon, 22 Sep 2008 15:03:38 +0100 From: Dieter Subject: Re: [RELENG_6] ATARAID oddity X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 22 Sep 2008 22:38:58 -0000 > I.e. if you insert a drive that was part of a volume from an Adaptec > RAID controller into another system, the new system will attempt to > treat that disk as though it were associated with a HOST Raid controller. > > I don't think that this is the desired behavior. Even if the host raid > meta-data is detected, the system shouldn't attempt to treat the disk as > part of a HOST raid set without the appropriate controller in the system. Even if there *is* an appropriate controller in the system, presumably it isn't going to work unless the disk is connected to that controller. We want the ability to migrate a disk from Adaptec to some other controller without screwy things happening. From owner-freebsd-drivers@FreeBSD.ORG Mon Sep 22 23:24:26 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 33B6E1065671 for ; Mon, 22 Sep 2008 23:24:26 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id 08D2F8FC0C for ; Mon, 22 Sep 2008 23:24:18 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id A220D1A9101; Mon, 22 Sep 2008 16:20:00 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id u9KlxhWgi3vv; Mon, 22 Sep 2008 16:20:00 -0700 (PDT) Received: from [10.0.0.40] (iago.office.miralink.com [10.0.0.40]) by plato.miralink.com (Postfix) with ESMTP id 318871A90E4; Mon, 22 Sep 2008 16:20:00 -0700 (PDT) Message-ID: <48D82921.3010904@miralink.com> Date: Mon, 22 Sep 2008 16:24:17 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.16 (X11/20080723) MIME-Version: 1.0 To: Dieter References: <200809222203.WAA20882@sopwith.solgatos.com> In-Reply-To: <200809222203.WAA20882@sopwith.solgatos.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-drivers@freebsd.org Subject: Re: [RELENG_6] ATARAID oddity X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 22 Sep 2008 23:24:26 -0000 Dieter wrote: >> I.e. if you insert a drive that was part of a volume from an Adaptec >> RAID controller into another system, the new system will attempt to >> treat that disk as though it were associated with a HOST Raid controller. >> >> I don't think that this is the desired behavior. Even if the host raid >> meta-data is detected, the system shouldn't attempt to treat the disk as >> part of a HOST raid set without the appropriate controller in the system. >> > > Even if there *is* an appropriate controller in the system, presumably it > isn't going to work unless the disk is connected to that controller. > > We want the ability to migrate a disk from Adaptec to some other > controller without screwy things happening. > _______________________________________________ Looking over the ata-raid.c code that controls the detection, it's pretty obvious that it doesn't check to see if the disk belongs to a controller. Moreover it blindly tries to use ANY drive in the system(LSI will do this as well) if it detects meta data. I'm working on a simple patch for this, but I need to figure out which cards are using the Adaptec metadata format. Any ideas where I should look? I seem to have 1 card available(3010S) that I can validate against. -- Sean Bruno MiraLink Corporation 6015 NE 80th Ave, Ste 100 Portland, OR 97218 Phone 503-621-5143 Fax 503-621-5199 MSN: sbruno@miralink.com Google: seanwbruno@gmail.com Yahoo: sean_bruno@yahoo.com From owner-freebsd-drivers@FreeBSD.ORG Tue Sep 23 02:40:45 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 54E08106567D for ; Tue, 23 Sep 2008 02:40:45 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id 20ECA8FC13 for ; Tue, 23 Sep 2008 02:40:45 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id 4D080890014; Mon, 22 Sep 2008 19:36:25 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id fdMKc5mW19-z; Mon, 22 Sep 2008 19:36:24 -0700 (PDT) Received: from [10.47.1.6] (vpn.office.miralink.com [10.0.0.5]) by plato.miralink.com (Postfix) with ESMTP id 773B4890001; Mon, 22 Sep 2008 19:36:24 -0700 (PDT) Message-ID: <48D8572B.3060204@miralink.com> Date: Mon, 22 Sep 2008 19:40:43 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.16 (X11/20080723) MIME-Version: 1.0 To: freebsd-drivers@freebsd.org References: <200809222203.WAA20882@sopwith.solgatos.com> <48D82921.3010904@miralink.com> In-Reply-To: <48D82921.3010904@miralink.com> Content-Type: multipart/mixed; boundary="------------000300030402010901040205" Cc: =?ISO-8859-1?Q?dt?= , =?ISO-8859-1?Q?S=F8ren_Schmi?= Subject: Re: [RELENG_6] ATARAID oddity X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Sep 2008 02:40:45 -0000 This is a multi-part message in MIME format. --------------000300030402010901040205 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Sean Bruno wrote: > Dieter wrote: >>> I.e. if you insert a drive that was part of a volume from an Adaptec >>> RAID controller into another system, the new system will attempt to >>> treat that disk as though it were associated with a HOST Raid >>> controller. >>> >>> I don't think that this is the desired behavior. Even if the host >>> raid meta-data is detected, the system shouldn't attempt to treat >>> the disk as part of a HOST raid set without the appropriate >>> controller in the system. >>> >> >> Even if there *is* an appropriate controller in the system, >> presumably it >> isn't going to work unless the disk is connected to that controller. >> >> We want the ability to migrate a disk from Adaptec to some other >> controller without screwy things happening. >> _______________________________________________ > Looking over the ata-raid.c code that controls the detection, it's > pretty obvious > that it doesn't check to see if the disk belongs to a controller. > Moreover it > blindly tries to use ANY drive in the system(LSI will do this as well) > if it detects > meta data. > > I'm working on a simple patch for this, but I need to figure out > which cards are > using the Adaptec metadata format. Any ideas where I should look? I > seem to have > 1 card available(3010S) that I can validate against. > > Well, I tried out this little patch for my system. This probably breaks a lot of stuff, but it's the beginning of what I think is more correct behavior for Adaptec Host-RAID. If anyone has Adaptec Host-RAID systems out there, please send me the PCI-IDs of your boards before your try this patch. I would assume that there are some Host RAID adapters out there that don't conform to the pci-ids I have put in this patch. If you have one, let me know. -- Sean Bruno MiraLink Corporation 6015 NE 80th Ave, Ste 100 Portland, OR 97218 Cell 503-358-6832 Phone 503-621-5143 Fax 503-621-5199 MSN: sbruno@miralink.com Google: seanwbruno@gmail.com --------------000300030402010901040205 Content-Type: text/x-patch; name="ata_adaptec.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="ata_adaptec.diff" Index: ata-pci.c =================================================================== --- ata-pci.c (revision 5956) +++ ata-pci.c (working copy) @@ -532,6 +532,7 @@ switch (pci_get_vendor(dev)) { case ATA_ACARD_ID: return "Acard"; case ATA_ACER_LABS_ID: return "AcerLabs"; + case ATA_ADAPTEC_ID: return "Adaptec"; case ATA_AMD_ID: return "AMD"; case ATA_ATI_ID: return "ATI"; case ATA_CYRIX_ID: return "Cyrix"; Index: ata-raid.c =================================================================== --- ata-raid.c (revision 5956) +++ ata-raid.c (working copy) @@ -1304,6 +1304,12 @@ /* prioritize vendor native metadata layout if possible */ if (devclass == pci_devclass) { switch (pci_get_vendor(GRANDPARENT(device_get_parent(subdisk)))) { + /* Adaptec HostRAID */ + case ATA_ADAPTEC_ID: + if (ata_raid_adaptec_read_meta(subdisk, ata_raid_arrays)) + return 0; + break; + case ATA_HIGHPOINT_ID: if (ata_raid_hptv3_read_meta(subdisk, ata_raid_arrays)) return 0; @@ -1358,10 +1364,6 @@ /* handle controllers that have multiple layout possibilities */ /* NOTE: the order of these are not insignificant */ - /* Adaptec HostRAID */ - if (ata_raid_adaptec_read_meta(subdisk, ata_raid_arrays)) - return 0; - /* LSILogic v3 and v2 */ if (ata_raid_lsiv3_read_meta(subdisk, ata_raid_arrays)) return 0; Index: ata-pci.h =================================================================== --- ata-pci.h (revision 5956) +++ ata-pci.h (working copy) @@ -71,6 +71,8 @@ }; /* defines for known chipset PCI id's */ +#define ATA_ADAPTEC_ID 0x1044 + #define ATA_ACARD_ID 0x1191 #define ATA_ATP850 0x00021191 #define ATA_ATP850A 0x00041191 --------------000300030402010901040205-- From owner-freebsd-drivers@FreeBSD.ORG Tue Sep 23 04:27:22 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 51D41106564A for ; Tue, 23 Sep 2008 04:27:22 +0000 (UTC) (envelope-from hsakamt@tsnr.com) Received: from sv.tsnr.com (sv.tsnr.com [203.181.83.169]) by mx1.freebsd.org (Postfix) with ESMTP id 2421B8FC1B for ; Tue, 23 Sep 2008 04:27:22 +0000 (UTC) (envelope-from hsakamt@tsnr.com) Received: from [192.168.83.14] (dhcp14.pv.tsnr.com [192.168.83.14]) by sv.tsnr.com (Postfix) with ESMTPSA id AFAB61F4462 for ; Tue, 23 Sep 2008 13:07:34 +0900 (JST) Message-ID: <48D86B85.8050304@tsnr.com> Date: Tue, 23 Sep 2008 13:07:33 +0900 From: Hideki Sakamoto User-Agent: Thunderbird 2.0.0.16 (Windows/20080708) MIME-Version: 1.0 To: freebsd-drivers@freebsd.org References: <200809222203.WAA20882@sopwith.solgatos.com> In-Reply-To: <200809222203.WAA20882@sopwith.solgatos.com> Content-Type: text/plain; charset=ISO-2022-JP Content-Transfer-Encoding: 7bit Subject: Re: [RELENG_6] ATARAID oddity X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Sep 2008 04:27:22 -0000 Hi, > Even if there *is* an appropriate controller in the system, presumably it > isn't going to work unless the disk is connected to that controller. As far as understanding, ataraid is software RAID and meta data is just used to determine whether a HDD is member of a RAID-set or not. And I think it's probably work even if there is no consistency between a meta data format and Controler Chip under the situation that the Controller is attached with and controlled by ATA(ad?) driver. This behavior may be useful in trouble shooting(e.g. Controller is dead, all HDD is OK, but I only have the motherboard with different ATA Controller Chip I used). So I think it's interesting to consider an (optional) implementation of: The ataraid driver can recognize any supported meta data format with all supportd Controller Chip. If you want to use a HDD which is used as member of ataraid in past time. You must delete or overwrite meta data on HDD by hand using atacontrol(8). Thanks, Dieter said: >> I.e. if you insert a drive that was part of a volume from an Adaptec >> RAID controller into another system, the new system will attempt to >> treat that disk as though it were associated with a HOST Raid controller. >> >> I don't think that this is the desired behavior. Even if the host raid >> meta-data is detected, the system shouldn't attempt to treat the disk as >> part of a HOST raid set without the appropriate controller in the system. > > Even if there *is* an appropriate controller in the system, presumably it > isn't going to work unless the disk is connected to that controller. > > We want the ability to migrate a disk from Adaptec to some other > controller without screwy things happening. > _______________________________________________ > freebsd-drivers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-drivers > To unsubscribe, send any mail to "freebsd-drivers-unsubscribe@freebsd.org" From owner-freebsd-drivers@FreeBSD.ORG Tue Sep 23 07:20:14 2008 Return-Path: Delivered-To: freebsd-drivers@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3E3F31065684 for ; Tue, 23 Sep 2008 07:20:14 +0000 (UTC) (envelope-from sos@FreeBSD.ORG) Received: from deepcore.dk (adsl.deepcore.dk [87.63.29.106]) by mx1.freebsd.org (Postfix) with ESMTP id CB3988FC22 for ; Tue, 23 Sep 2008 07:20:13 +0000 (UTC) (envelope-from sos@FreeBSD.ORG) Received: from [192.168.0.138] ([192.168.0.138]) by deepcore.dk (8.14.3/8.14.2) with ESMTP id m8N6vr1N077916; Tue, 23 Sep 2008 08:57:53 +0200 (CEST) (envelope-from sos@FreeBSD.ORG) Message-Id: From: =?ISO-8859-1?Q?S=F8ren_Schmidt?= To: Sean Bruno In-Reply-To: <48D8572B.3060204@miralink.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed; delsp=yes Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Apple Message framework v929.2) Date: Tue, 23 Sep 2008 08:43:23 +0200 References: <200809222203.WAA20882@sopwith.solgatos.com> <48D82921.3010904@miralink.com> <48D8572B.3060204@miralink.com> X-Mailer: Apple Mail (2.929.2) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.0 (deepcore.dk [217.20.59.72]); Tue, 23 Sep 2008 08:57:55 +0200 (CEST) Cc: freebsd-drivers@FreeBSD.ORG Subject: Re: [RELENG_6] ATARAID oddity X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Sep 2008 07:20:14 -0000 Hi Just the short version: Since this is softraids and the different vendors use different chips, =20= there is no 1 to 1 relation between raid type and controller PCI id. =20 Its a puzzle you cannot solve without loosing a good percentage of the =20= systems out there. -S=F8ren On 23Sep, 2008, at 4:40 , Sean Bruno wrote: > Sean Bruno wrote: >> Dieter wrote: >>>> I.e. if you insert a drive that was part of a volume from an =20 >>>> Adaptec RAID controller into another system, the new system will =20= >>>> attempt to treat that disk as though it were associated with a =20 >>>> HOST Raid controller. >>>> >>>> I don't think that this is the desired behavior. Even if the =20 >>>> host raid meta-data is detected, the system shouldn't attempt to =20= >>>> treat the disk as part of a HOST raid set without the appropriate =20= >>>> controller in the system. >>>> >>> >>> Even if there *is* an appropriate controller in the system, =20 >>> presumably it >>> isn't going to work unless the disk is connected to that controller. >>> >>> We want the ability to migrate a disk from Adaptec to some other >>> controller without screwy things happening. >>> _______________________________________________ >> Looking over the ata-raid.c code that controls the detection, it's =20= >> pretty obvious >> that it doesn't check to see if the disk belongs to a controller. =20= >> Moreover it >> blindly tries to use ANY drive in the system(LSI will do this as =20 >> well) if it detects >> meta data. >> >> I'm working on a simple patch for this, but I need to figure out =20 >> which cards are >> using the Adaptec metadata format. Any ideas where I should look? =20= >> I seem to have >> 1 card available(3010S) that I can validate against. >> >> > Well, I tried out this little patch for my system. This probably =20 > breaks a lot of stuff, but > it's the beginning of what I think is more correct behavior for =20 > Adaptec Host-RAID. > > If anyone has Adaptec Host-RAID systems out there, please send me =20 > the PCI-IDs of your > boards before your try this patch. I would assume that there are =20 > some Host RAID adapters > out there that don't conform to the pci-ids I have put in this =20 > patch. If you have one, let me know. > > --=20 > Sean Bruno > MiraLink Corporation > 6015 NE 80th Ave, Ste 100 > Portland, OR 97218 > Cell 503-358-6832 > Phone 503-621-5143 > Fax 503-621-5199 > MSN: sbruno@miralink.com > Google: seanwbruno@gmail.com > > Index: ata-pci.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > --- ata-pci.c (revision 5956) > +++ ata-pci.c (working copy) > @@ -532,6 +532,7 @@ > switch (pci_get_vendor(dev)) { > case ATA_ACARD_ID: return "Acard"; > case ATA_ACER_LABS_ID: return "AcerLabs"; > + case ATA_ADAPTEC_ID: return "Adaptec"; > case ATA_AMD_ID: return "AMD"; > case ATA_ATI_ID: return "ATI"; > case ATA_CYRIX_ID: return "Cyrix"; > Index: ata-raid.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > --- ata-raid.c (revision 5956) > +++ ata-raid.c (working copy) > @@ -1304,6 +1304,12 @@ > /* prioritize vendor native metadata layout if possible */ > if (devclass =3D=3D pci_devclass) { > switch (pci_get_vendor(GRANDPARENT(device_get_parent(subdisk)))) = { > + /* Adaptec HostRAID */ > + case ATA_ADAPTEC_ID: > + if (ata_raid_adaptec_read_meta(subdisk, ata_raid_arrays)) > + return 0; > + break; > + > case ATA_HIGHPOINT_ID: > if (ata_raid_hptv3_read_meta(subdisk, ata_raid_arrays)) > return 0; > @@ -1358,10 +1364,6 @@ > /* handle controllers that have multiple layout possibilities */ > /* NOTE: the order of these are not insignificant */ > > - /* Adaptec HostRAID */ > - if (ata_raid_adaptec_read_meta(subdisk, ata_raid_arrays)) > - return 0; > - > /* LSILogic v3 and v2 */ > if (ata_raid_lsiv3_read_meta(subdisk, ata_raid_arrays)) > return 0; > Index: ata-pci.h > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > --- ata-pci.h (revision 5956) > +++ ata-pci.h (working copy) > @@ -71,6 +71,8 @@ > }; > > /* defines for known chipset PCI id's */ > +#define ATA_ADAPTEC_ID 0x1044 > + > #define ATA_ACARD_ID 0x1191 > #define ATA_ATP850 0x00021191 > #define ATA_ATP850A 0x00041191 -S=F8ren From owner-freebsd-drivers@FreeBSD.ORG Tue Sep 23 16:14:38 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A1D7D106566B for ; Tue, 23 Sep 2008 16:14:38 +0000 (UTC) (envelope-from freebsd@sopwith.solgatos.com) Received: from parsely.rain.com (parsely.rain.com [199.26.172.196]) by mx1.freebsd.org (Postfix) with ESMTP id EC2CA8FC08 for ; Tue, 23 Sep 2008 16:14:37 +0000 (UTC) (envelope-from freebsd@sopwith.solgatos.com) Received: from sopwith.solgatos.com (uucp@localhost) by parsely.rain.com (8.11.4/8.11.4) with UUCP id m8NGEZe57197 for freebsd-drivers@freebsd.org; Tue, 23 Sep 2008 09:14:35 -0700 (PDT) (envelope-from freebsd@sopwith.solgatos.com) Received: from localhost by sopwith.solgatos.com (8.8.8/6.24) id QAA05934; Tue, 23 Sep 2008 16:11:28 GMT Message-Id: <200809231611.QAA05934@sopwith.solgatos.com> To: freebsd-drivers@freebsd.org In-reply-to: Your message of "Mon, 22 Sep 2008 10:51:01 PDT." <48D7DB05.6050907@miralink.com> Date: Tue, 23 Sep 2008 09:11:28 +0100 From: Dieter Subject: Re: [RELENG_6] ATARAID oddity X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Sep 2008 16:14:38 -0000 Sean Bruno writes: > If a FreeBSD system detects a drive with Adaptec RAID controller meta > data on it, the ataraid() driver will attempt to interpret that data as > a real volume. It makes no difference to the ataraid() driver if there > is an Adaptec controller physically present in the system or not. > > I.e. if you insert a drive that was part of a volume from an Adaptec > RAID controller into another system, the new system will attempt to > treat that disk as though it were associated with a HOST Raid controller. > > I don't think that this is the desired behavior. Even if the host raid > meta-data is detected, the system shouldn't attempt to treat the disk as > part of a HOST raid set without the appropriate controller in the system. The system should not even be looking at data on a drive unless a command tells it to. Just because a drive has bits on it that happen to look like Adaptec/LSI/whoever RAID metadata doesn't mean that those bits actually *are* RAID metadata, and even if they are, it doesn't mean that the sysadmin wants that disk to be part of a RAID. From owner-freebsd-drivers@FreeBSD.ORG Tue Sep 23 16:48:27 2008 Return-Path: Delivered-To: freebsd-drivers@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 95053106566C; Tue, 23 Sep 2008 16:48:27 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id 60DE18FC0A; Tue, 23 Sep 2008 16:48:27 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id 044D7890003; Tue, 23 Sep 2008 09:44:00 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id jcjha8YvDWOJ; Tue, 23 Sep 2008 09:43:59 -0700 (PDT) Received: from [10.0.0.40] (iago.office.miralink.com [10.0.0.40]) by plato.miralink.com (Postfix) with ESMTP id 85B461A87A5; Tue, 23 Sep 2008 09:43:59 -0700 (PDT) Message-ID: <48D91DDA.9060608@miralink.com> Date: Tue, 23 Sep 2008 09:48:26 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.16 (X11/20080723) MIME-Version: 1.0 To: freebsd-drivers@FreeBSD.ORG References: <200809222203.WAA20882@sopwith.solgatos.com> <48D82921.3010904@miralink.com> <48D8572B.3060204@miralink.com> In-Reply-To: Content-Type: multipart/mixed; boundary="------------070608020705050009020505" Cc: =?ISO-8859-1?Q?S=F8ren_Schmidt?= Subject: Re: [RELENG_6] ATARAID oddity X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Sep 2008 16:48:27 -0000 This is a multi-part message in MIME format. --------------070608020705050009020505 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit Søren Schmidt wrote: > Hi > > Just the short version: > > Since this is softraids and the different vendors use different chips, > there is no 1 to 1 relation between raid type and controller PCI id. > Its a puzzle you cannot solve without loosing a good percentage of the > systems out there. > > -Søren > Agreed. It is very easy to lose systems where the host raid configurations are working. In order to make it easier, I looked over at Heinz's Linux dmraid app. http://people.redhat.com/~heinzm/sw/dmraid/src/ In the Adaptec format, he is looking at PCI ID 0x9005 . The code apparently used to look at 0x9004 as well, but that is commented out at this time. 0x1044 is actually the old dpt() driver PCI ID, so that was completely wrong. I have one of these RAID controllers, and I find it interesting that they use the same RAID metadata. Sean --------------070608020705050009020505 Content-Type: text/plain; name="ata_adatpec.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="ata_adatpec.diff" Index: ata-pci.c =================================================================== --- ata-pci.c (revision 5956) +++ ata-pci.c (working copy) @@ -532,6 +532,7 @@ switch (pci_get_vendor(dev)) { case ATA_ACARD_ID: return "Acard"; case ATA_ACER_LABS_ID: return "AcerLabs"; + case ATA_ADAPTEC_ID: return "Adaptec"; case ATA_AMD_ID: return "AMD"; case ATA_ATI_ID: return "ATI"; case ATA_CYRIX_ID: return "Cyrix"; Index: ata-raid.c =================================================================== --- ata-raid.c (revision 5956) +++ ata-raid.c (working copy) @@ -1304,6 +1304,12 @@ /* prioritize vendor native metadata layout if possible */ if (devclass == pci_devclass) { switch (pci_get_vendor(GRANDPARENT(device_get_parent(subdisk)))) { + /* Adaptec HostRAID */ + case ATA_ADAPTEC_ID: + if (ata_raid_adaptec_read_meta(subdisk, ata_raid_arrays)) + return 0; + break; + case ATA_HIGHPOINT_ID: if (ata_raid_hptv3_read_meta(subdisk, ata_raid_arrays)) return 0; @@ -1358,10 +1364,6 @@ /* handle controllers that have multiple layout possibilities */ /* NOTE: the order of these are not insignificant */ - /* Adaptec HostRAID */ - if (ata_raid_adaptec_read_meta(subdisk, ata_raid_arrays)) - return 0; - /* LSILogic v3 and v2 */ if (ata_raid_lsiv3_read_meta(subdisk, ata_raid_arrays)) return 0; Index: ata-pci.h =================================================================== --- ata-pci.h (revision 5956) +++ ata-pci.h (working copy) @@ -71,6 +71,8 @@ }; /* defines for known chipset PCI id's */ +#define ATA_ADAPTEC_ID 0x9005 + #define ATA_ACARD_ID 0x1191 #define ATA_ATP850 0x00021191 #define ATA_ATP850A 0x00041191 --------------070608020705050009020505-- From owner-freebsd-drivers@FreeBSD.ORG Wed Sep 24 00:45:54 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 375ED1065741; Wed, 24 Sep 2008 00:45:54 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id 15C6D8FC14; Wed, 24 Sep 2008 00:45:53 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id 4E22089001B; Tue, 23 Sep 2008 17:41:22 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ztk6XcZ4ak2X; Tue, 23 Sep 2008 17:41:21 -0700 (PDT) Received: from [10.47.1.6] (vpn.office.miralink.com [10.0.0.5]) by plato.miralink.com (Postfix) with ESMTP id B31FA1A90DD; Tue, 23 Sep 2008 17:41:21 -0700 (PDT) Message-ID: <48D98DC0.6080201@miralink.com> Date: Tue, 23 Sep 2008 17:45:52 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.16 (X11/20080723) MIME-Version: 1.0 To: freebsd-drivers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: =?ISO-8859-1?Q?S=F8ren_Schmidt?= Subject: ATA fails to add new disks (atacontrol reinit) X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 24 Sep 2008 00:45:54 -0000 Is it expected that an "atacontrol reinit " won't find new disks but will delete removed disks? Looking over the ata_reinit() / ad_reinit() code, it should be possible to probe and find new drives when userland asks to redetect them. -- Sean Bruno MiraLink Corporation 6015 NE 80th Ave, Ste 100 Portland, OR 97218 Cell 503-358-6832 Phone 503-621-5143 Fax 503-621-5199 MSN: sbruno@miralink.com Google: seanwbruno@gmail.com From owner-freebsd-drivers@FreeBSD.ORG Wed Sep 24 09:56:47 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 10F291065677 for ; Wed, 24 Sep 2008 09:56:47 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from forwards4.yandex.ru (forwards4.yandex.ru [77.88.32.20]) by mx1.freebsd.org (Postfix) with ESMTP id 8985D8FC1A for ; Wed, 24 Sep 2008 09:56:46 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from smtp5.yandex.ru (smtp5.yandex.ru [77.88.32.24]) by forwards4.yandex.ru (Postfix) with ESMTP id 57B791A1120 for ; Wed, 24 Sep 2008 13:37:06 +0400 (MSD) Received: from mail.kirov.so-cdu.ru ([77.72.136.145]:19963 "EHLO [127.0.0.1]" smtp-auth: "bu7cher" TLS-CIPHER: "DHE-RSA-AES256-SHA keybits 256/256 version TLSv1/SSLv3" TLS-PEER-CN1: ) by mail.yandex.ru with ESMTP id S1053127AbYIXJg6 (ORCPT ); Wed, 24 Sep 2008 13:36:58 +0400 X-Yandex-Spam: 1 X-Yandex-Front: smtp5 X-Yandex-TimeMark: 1222249018 X-MsgDayCount: 1 X-Comment: RFC 2476 MSA function at smtp5.yandex.ru logged sender identity as: bu7cher Message-ID: <48DA0A35.9030603@yandex.ru> Date: Wed, 24 Sep 2008 13:36:53 +0400 From: "Andrey V. Elsukov" User-Agent: Mozilla Thunderbird 1.5 (FreeBSD/20051231) MIME-Version: 1.0 To: freebsd-drivers@freebsd.org Content-Type: text/plain; charset=KOI8-R; format=flowed Content-Transfer-Encoding: 7bit Subject: Why some devices cannot be detected? X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 24 Sep 2008 09:56:47 -0000 Hi, All. I don't have this problem, but i saw it in several users reports. System can't detect some devices. Last example (from one report): Windows/Linux detected LSI MegaRAID SAS 8408E RAID Controller on an motherboard, but freebsd didn't detect. pciconf list: hostb0@pci0:0:0:0: class=0x060000 card=0x83361033 chip=0x25d88086 rev=0xb1 hdr=0x00 pcib1@pci0:0:2:0: class=0x060400 card=0x00000000 chip=0x25f78086 rev=0xb1 hdr=0x01 pcib8@pci0:0:3:0: class=0x060400 card=0x00000000 chip=0x25e38086 rev=0xb1 hdr=0x01 pcib9@pci0:0:4:0: class=0x060400 card=0x00000000 chip=0x25f88086 rev=0xb1 hdr=0x01 pcib10@pci0:0:5:0: class=0x060400 card=0x00000000 chip=0x25e58086 rev=0xb1 hdr=0x01 pcib11@pci0:0:6:0: class=0x060400 card=0x00000000 chip=0x25e68086 rev=0xb1 hdr=0x01 pcib12@pci0:0:7:0: class=0x060400 card=0x00000000 chip=0x25e78086 rev=0xb1 hdr=0x01 hostb1@pci0:0:16:0: class=0x060000 card=0x83361033 chip=0x25f08086 rev=0xb1 hdr=0x00 hostb2@pci0:0:16:1: class=0x060000 card=0x83361033 chip=0x25f08086 rev=0xb1 hdr=0x00 hostb3@pci0:0:16:2: class=0x060000 card=0x83361033 chip=0x25f08086 rev=0xb1 hdr=0x00 hostb4@pci0:0:17:0: class=0x060000 card=0x83361033 chip=0x25f18086 rev=0xb1 hdr=0x00 hostb5@pci0:0:19:0: class=0x060000 card=0x83361033 chip=0x25f38086 rev=0xb1 hdr=0x00 hostb6@pci0:0:21:0: class=0x060000 card=0x83361033 chip=0x25f58086 rev=0xb1 hdr=0x00 hostb7@pci0:0:22:0: class=0x060000 card=0x83361033 chip=0x25f68086 rev=0xb1 hdr=0x00 pcib13@pci0:0:28:0: class=0x060400 card=0x83361033 chip=0x26908086 rev=0x09 hdr=0x01 uhci0@pci0:0:29:0: class=0x0c0300 card=0x83361033 chip=0x26888086 rev=0x09 hdr=0x00 uhci1@pci0:0:29:1: class=0x0c0300 card=0x83361033 chip=0x26898086 rev=0x09 hdr=0x00 uhci2@pci0:0:29:2: class=0x0c0300 card=0x83361033 chip=0x268a8086 rev=0x09 hdr=0x00 uhci3@pci0:0:29:3: class=0x0c0300 card=0x83361033 chip=0x268b8086 rev=0x09 hdr=0x00 ehci0@pci0:0:29:7: class=0x0c0320 card=0x83361033 chip=0x268c8086 rev=0x09 hdr=0x00 pcib14@pci0:0:30:0: class=0x060401 card=0x83361033 chip=0x244e8086 rev=0xd9 hdr=0x01 isab0@pci0:0:31:0: class=0x060100 card=0x83361033 chip=0x26708086 rev=0x09 hdr=0x00 atapci0@pci0:0:31:1: class=0x01018a card=0x83361033 chip=0x269e8086 rev=0x09 hdr=0x00 none0@pci0:0:31:3: class=0x0c0500 card=0x83361033 chip=0x269b8086 rev=0x09 hdr=0x00 pcib2@pci0:1:0:0: class=0x060400 card=0x83361033 chip=0x35008086 rev=0x01 hdr=0x01 pcib7@pci0:1:0:3: class=0x060400 card=0x83361033 chip=0x350c8086 rev=0x01 hdr=0x01 pcib3@pci0:2:0:0: class=0x060400 card=0x83361033 chip=0x35108086 rev=0x01 hdr=0x01 pcib6@pci0:2:2:0: class=0x060400 card=0x83361033 chip=0x35188086 rev=0x01 hdr=0x01 pcib4@pci0:3:0:0: class=0x060400 card=0x00000000 chip=0x03708086 rev=0x00 hdr=0x01 pcib5@pci0:3:0:2: class=0x060400 card=0x00000000 chip=0x03728086 rev=0x00 hdr=0x01 em0@pci0:12:0:0: class=0x020000 card=0x83361033 chip=0x10968086 rev=0x01 hdr=0x00 em1@pci0:12:0:1: class=0x020000 card=0x83361033 chip=0x10968086 rev=0x01 hdr=0x00 mpt0@pci0:13:5:0: class=0x010000 card=0x83361033 chip=0x00541000 rev=0x01 hdr=0x00 vgapci0@pci0:36:0:0: class=0x030000 card=0x83361033 chip=0x0522102b rev=0x02 hdr=0x00 Windows detects it as Device Description LSI MegaRAID SAS 8408E RAID Controller Bus Type PCI-X Bus / Device / Function 4 / 14 / 0 Device ID 1000-0411 Subsystem ID 1000-1001 Device Class 0104 (RAID Controller) Revision 00 Fast Back-to-Back Transactions Not Supported Device Features 66 MHz Operation Supported Bus Mastering Enabled PCI-X Device Properties 64-bit Device Yes 133 MHz Operation Supported PCI-X 266 Not Supported PCI-X 533 Not Supported --------------------------------------- So, question is why freebsd can't detect this device? -- WBR, Andrey V. Elsukov From owner-freebsd-drivers@FreeBSD.ORG Wed Sep 24 16:10:51 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 395B71065699 for ; Wed, 24 Sep 2008 16:10:51 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id 0E6A28FC18 for ; Wed, 24 Sep 2008 16:10:50 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id 2837E890022; Wed, 24 Sep 2008 09:06:11 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5SnIPQ3FRQI6; Wed, 24 Sep 2008 09:06:10 -0700 (PDT) Received: from [10.0.0.40] (iago.office.miralink.com [10.0.0.40]) by plato.miralink.com (Postfix) with ESMTP id 9BCD81A90C0; Wed, 24 Sep 2008 09:06:10 -0700 (PDT) Message-ID: <48DA668A.3070400@miralink.com> Date: Wed, 24 Sep 2008 09:10:50 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.16 (X11/20080723) MIME-Version: 1.0 To: "Andrey V. Elsukov" References: <48DA0A35.9030603@yandex.ru> In-Reply-To: <48DA0A35.9030603@yandex.ru> Content-Type: text/plain; charset=KOI8-R; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-drivers@freebsd.org Subject: Re: Why some devices cannot be detected? X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 24 Sep 2008 16:10:51 -0000 Andrey V. Elsukov wrote: > Hi, All. > > I don't have this problem, but i saw it in several users reports. > System can't detect some devices. Last example (from one report): > Windows/Linux detected LSI MegaRAID SAS 8408E RAID Controller on > an motherboard, but freebsd didn't detect. > > pciconf list: > hostb0@pci0:0:0:0: class=0x060000 card=0x83361033 chip=0x25d88086 > rev=0xb1 hdr=0x00 > pcib1@pci0:0:2:0: class=0x060400 card=0x00000000 chip=0x25f78086 > rev=0xb1 hdr=0x01 > pcib8@pci0:0:3:0: class=0x060400 card=0x00000000 chip=0x25e38086 > rev=0xb1 hdr=0x01 > pcib9@pci0:0:4:0: class=0x060400 card=0x00000000 chip=0x25f88086 > rev=0xb1 hdr=0x01 > pcib10@pci0:0:5:0: class=0x060400 card=0x00000000 chip=0x25e58086 > rev=0xb1 hdr=0x01 > pcib11@pci0:0:6:0: class=0x060400 card=0x00000000 chip=0x25e68086 > rev=0xb1 hdr=0x01 > pcib12@pci0:0:7:0: class=0x060400 card=0x00000000 chip=0x25e78086 > rev=0xb1 hdr=0x01 > hostb1@pci0:0:16:0: class=0x060000 card=0x83361033 chip=0x25f08086 > rev=0xb1 hdr=0x00 > hostb2@pci0:0:16:1: class=0x060000 card=0x83361033 chip=0x25f08086 > rev=0xb1 hdr=0x00 > hostb3@pci0:0:16:2: class=0x060000 card=0x83361033 chip=0x25f08086 > rev=0xb1 hdr=0x00 > hostb4@pci0:0:17:0: class=0x060000 card=0x83361033 chip=0x25f18086 > rev=0xb1 hdr=0x00 > hostb5@pci0:0:19:0: class=0x060000 card=0x83361033 chip=0x25f38086 > rev=0xb1 hdr=0x00 > hostb6@pci0:0:21:0: class=0x060000 card=0x83361033 chip=0x25f58086 > rev=0xb1 hdr=0x00 > hostb7@pci0:0:22:0: class=0x060000 card=0x83361033 chip=0x25f68086 > rev=0xb1 hdr=0x00 > pcib13@pci0:0:28:0: class=0x060400 card=0x83361033 chip=0x26908086 > rev=0x09 hdr=0x01 > uhci0@pci0:0:29:0: class=0x0c0300 card=0x83361033 chip=0x26888086 > rev=0x09 hdr=0x00 > uhci1@pci0:0:29:1: class=0x0c0300 card=0x83361033 chip=0x26898086 > rev=0x09 hdr=0x00 > uhci2@pci0:0:29:2: class=0x0c0300 card=0x83361033 chip=0x268a8086 > rev=0x09 hdr=0x00 > uhci3@pci0:0:29:3: class=0x0c0300 card=0x83361033 chip=0x268b8086 > rev=0x09 hdr=0x00 > ehci0@pci0:0:29:7: class=0x0c0320 card=0x83361033 chip=0x268c8086 > rev=0x09 hdr=0x00 > pcib14@pci0:0:30:0: class=0x060401 card=0x83361033 chip=0x244e8086 > rev=0xd9 hdr=0x01 > isab0@pci0:0:31:0: class=0x060100 card=0x83361033 chip=0x26708086 > rev=0x09 hdr=0x00 > atapci0@pci0:0:31:1: class=0x01018a card=0x83361033 chip=0x269e8086 > rev=0x09 hdr=0x00 > none0@pci0:0:31:3: class=0x0c0500 card=0x83361033 chip=0x269b8086 > rev=0x09 hdr=0x00 > pcib2@pci0:1:0:0: class=0x060400 card=0x83361033 chip=0x35008086 > rev=0x01 hdr=0x01 > pcib7@pci0:1:0:3: class=0x060400 card=0x83361033 chip=0x350c8086 > rev=0x01 hdr=0x01 > pcib3@pci0:2:0:0: class=0x060400 card=0x83361033 chip=0x35108086 > rev=0x01 hdr=0x01 > pcib6@pci0:2:2:0: class=0x060400 card=0x83361033 chip=0x35188086 > rev=0x01 hdr=0x01 > pcib4@pci0:3:0:0: class=0x060400 card=0x00000000 chip=0x03708086 > rev=0x00 hdr=0x01 > pcib5@pci0:3:0:2: class=0x060400 card=0x00000000 chip=0x03728086 > rev=0x00 hdr=0x01 > em0@pci0:12:0:0: class=0x020000 card=0x83361033 chip=0x10968086 > rev=0x01 hdr=0x00 > em1@pci0:12:0:1: class=0x020000 card=0x83361033 chip=0x10968086 > rev=0x01 hdr=0x00 > mpt0@pci0:13:5:0: class=0x010000 card=0x83361033 chip=0x00541000 > rev=0x01 hdr=0x00 > vgapci0@pci0:36:0:0: class=0x030000 card=0x83361033 chip=0x0522102b > rev=0x02 hdr=0x00 > > Windows detects it as > > Device Description LSI MegaRAID SAS 8408E RAID Controller > Bus Type PCI-X > Bus / Device / Function 4 / 14 / 0 > Device ID 1000-0411 > Subsystem ID 1000-1001 > Device Class 0104 (RAID Controller) > Revision 00 > Fast Back-to-Back Transactions Not Supported > > Device Features > 66 MHz Operation Supported > Bus Mastering Enabled > > PCI-X Device Properties > 64-bit Device Yes > 133 MHz Operation Supported > PCI-X 266 Not Supported > PCI-X 533 Not Supported > --------------------------------------- > > So, question is why freebsd can't detect this device? > Is this the adapter? mpt0@pci0:13:5:0: class=0x010000 card=0x83361033 chip=0x00541000 rev=0x01 hdr=0x00 Because it looks like it was detected. -- Sean Bruno MiraLink Corporation 6015 NE 80th Ave, Ste 100 Portland, OR 97218 Phone 503-621-5143 Fax 503-621-5199 MSN: sbruno@miralink.com Google: seanwbruno@gmail.com Yahoo: sean_bruno@yahoo.com From owner-freebsd-drivers@FreeBSD.ORG Wed Sep 24 16:54:50 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CBF3610656BA for ; Wed, 24 Sep 2008 16:54:50 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id 70DA18FC1F for ; Wed, 24 Sep 2008 16:54:50 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from localhost.corp.yahoo.com (john@localhost [IPv6:::1]) (authenticated bits=0) by server.baldwin.cx (8.14.2/8.14.2) with ESMTP id m8OGshJe084657; Wed, 24 Sep 2008 12:54:43 -0400 (EDT) (envelope-from jhb@freebsd.org) From: John Baldwin To: freebsd-drivers@freebsd.org Date: Wed, 24 Sep 2008 11:52:41 -0400 User-Agent: KMail/1.9.7 References: <48DA0A35.9030603@yandex.ru> In-Reply-To: <48DA0A35.9030603@yandex.ru> MIME-Version: 1.0 Content-Type: text/plain; charset="koi8-r" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200809241152.41761.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (server.baldwin.cx [IPv6:::1]); Wed, 24 Sep 2008 12:54:43 -0400 (EDT) X-Virus-Scanned: ClamAV 0.93.1/8324/Wed Sep 24 06:55:43 2008 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-2.6 required=4.2 tests=AWL,BAYES_00,NO_RELAYS autolearn=ham version=3.1.3 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on server.baldwin.cx Cc: Subject: Re: Why some devices cannot be detected? X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 24 Sep 2008 16:54:51 -0000 On Wednesday 24 September 2008 05:36:53 am Andrey V. Elsukov wrote: > Hi, All. > > I don't have this problem, but i saw it in several users reports. > System can't detect some devices. Last example (from one report): > Windows/Linux detected LSI MegaRAID SAS 8408E RAID Controller on > an motherboard, but freebsd didn't detect. > > pciconf list: > hostb0@pci0:0:0:0: class=0x060000 card=0x83361033 chip=0x25d88086 > rev=0xb1 hdr=0x00 > pcib1@pci0:0:2:0: class=0x060400 card=0x00000000 chip=0x25f78086 > rev=0xb1 hdr=0x01 > pcib8@pci0:0:3:0: class=0x060400 card=0x00000000 chip=0x25e38086 > rev=0xb1 hdr=0x01 > pcib9@pci0:0:4:0: class=0x060400 card=0x00000000 chip=0x25f88086 > rev=0xb1 hdr=0x01 > pcib10@pci0:0:5:0: class=0x060400 card=0x00000000 chip=0x25e58086 > rev=0xb1 hdr=0x01 > pcib11@pci0:0:6:0: class=0x060400 card=0x00000000 chip=0x25e68086 > rev=0xb1 hdr=0x01 > pcib12@pci0:0:7:0: class=0x060400 card=0x00000000 chip=0x25e78086 > rev=0xb1 hdr=0x01 > hostb1@pci0:0:16:0: class=0x060000 card=0x83361033 chip=0x25f08086 > rev=0xb1 hdr=0x00 > hostb2@pci0:0:16:1: class=0x060000 card=0x83361033 chip=0x25f08086 > rev=0xb1 hdr=0x00 > hostb3@pci0:0:16:2: class=0x060000 card=0x83361033 chip=0x25f08086 > rev=0xb1 hdr=0x00 > hostb4@pci0:0:17:0: class=0x060000 card=0x83361033 chip=0x25f18086 > rev=0xb1 hdr=0x00 > hostb5@pci0:0:19:0: class=0x060000 card=0x83361033 chip=0x25f38086 > rev=0xb1 hdr=0x00 > hostb6@pci0:0:21:0: class=0x060000 card=0x83361033 chip=0x25f58086 > rev=0xb1 hdr=0x00 > hostb7@pci0:0:22:0: class=0x060000 card=0x83361033 chip=0x25f68086 > rev=0xb1 hdr=0x00 > pcib13@pci0:0:28:0: class=0x060400 card=0x83361033 chip=0x26908086 > rev=0x09 hdr=0x01 > uhci0@pci0:0:29:0: class=0x0c0300 card=0x83361033 chip=0x26888086 > rev=0x09 hdr=0x00 > uhci1@pci0:0:29:1: class=0x0c0300 card=0x83361033 chip=0x26898086 > rev=0x09 hdr=0x00 > uhci2@pci0:0:29:2: class=0x0c0300 card=0x83361033 chip=0x268a8086 > rev=0x09 hdr=0x00 > uhci3@pci0:0:29:3: class=0x0c0300 card=0x83361033 chip=0x268b8086 > rev=0x09 hdr=0x00 > ehci0@pci0:0:29:7: class=0x0c0320 card=0x83361033 chip=0x268c8086 > rev=0x09 hdr=0x00 > pcib14@pci0:0:30:0: class=0x060401 card=0x83361033 chip=0x244e8086 > rev=0xd9 hdr=0x01 > isab0@pci0:0:31:0: class=0x060100 card=0x83361033 chip=0x26708086 > rev=0x09 hdr=0x00 > atapci0@pci0:0:31:1: class=0x01018a card=0x83361033 chip=0x269e8086 > rev=0x09 hdr=0x00 > none0@pci0:0:31:3: class=0x0c0500 card=0x83361033 chip=0x269b8086 > rev=0x09 hdr=0x00 > pcib2@pci0:1:0:0: class=0x060400 card=0x83361033 chip=0x35008086 > rev=0x01 hdr=0x01 > pcib7@pci0:1:0:3: class=0x060400 card=0x83361033 chip=0x350c8086 > rev=0x01 hdr=0x01 > pcib3@pci0:2:0:0: class=0x060400 card=0x83361033 chip=0x35108086 > rev=0x01 hdr=0x01 > pcib6@pci0:2:2:0: class=0x060400 card=0x83361033 chip=0x35188086 > rev=0x01 hdr=0x01 > pcib4@pci0:3:0:0: class=0x060400 card=0x00000000 chip=0x03708086 > rev=0x00 hdr=0x01 > pcib5@pci0:3:0:2: class=0x060400 card=0x00000000 chip=0x03728086 > rev=0x00 hdr=0x01 > em0@pci0:12:0:0: class=0x020000 card=0x83361033 chip=0x10968086 > rev=0x01 hdr=0x00 > em1@pci0:12:0:1: class=0x020000 card=0x83361033 chip=0x10968086 > rev=0x01 hdr=0x00 > mpt0@pci0:13:5:0: class=0x010000 card=0x83361033 chip=0x00541000 > rev=0x01 hdr=0x00 > vgapci0@pci0:36:0:0: class=0x030000 card=0x83361033 chip=0x0522102b > rev=0x02 hdr=0x00 > > Windows detects it as > > Device Description LSI MegaRAID SAS 8408E RAID Controller > Bus Type PCI-X > Bus / Device / Function 4 / 14 / 0 > Device ID 1000-0411 > Subsystem ID 1000-1001 > Device Class 0104 (RAID Controller) > Revision 00 > Fast Back-to-Back Transactions Not Supported > > Device Features > 66 MHz Operation Supported > Bus Mastering Enabled > > PCI-X Device Properties > 64-bit Device Yes > 133 MHz Operation Supported > PCI-X 266 Not Supported > PCI-X 533 Not Supported > --------------------------------------- > > So, question is why freebsd can't detect this device? FreeBSD didn't see a PCI bus 4. Can you determine from another OS if PCI bus 4 is attached to a Host-PCI bridge or a PCI-PCI bridge? -- John Baldwin From owner-freebsd-drivers@FreeBSD.ORG Thu Sep 25 07:41:49 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 81FFF106569B for ; Thu, 25 Sep 2008 07:41:49 +0000 (UTC) (envelope-from Satendra.Pratap@citrix.com) Received: from SMTP02.CITRIX.COM (smtp02.citrix.com [66.165.176.63]) by mx1.freebsd.org (Postfix) with ESMTP id 438598FC20 for ; Thu, 25 Sep 2008 07:41:48 +0000 (UTC) (envelope-from Satendra.Pratap@citrix.com) X-IronPort-AV: E=Sophos;i="4.33,306,1220241600"; d="scan'208,217";a="21272426" Received: from ftlpexchmx01.citrite.net ([10.9.154.126]) by FTLPIPO02.CITRIX.COM with ESMTP; 25 Sep 2008 03:13:15 -0400 Received: from banpexch01.citrite.net ([10.103.128.11]) by FTLPEXCHMX01.citrite.net with Microsoft SMTPSVC(6.0.3790.3959); Thu, 25 Sep 2008 03:13:14 -0400 X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Date: Thu, 25 Sep 2008 12:43:11 +0530 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: regarding 1 Gig Chelsio SFP support Thread-Index: Acke3itRWnOoNQG4QoOWFHMlDnHpBQ== From: "Satendra Pratap" To: X-OriginalArrivalTime: 25 Sep 2008 07:13:14.0865 (UTC) FILETIME=[2D515E10:01C91EDE] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: regarding 1 Gig Chelsio SFP support X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Sep 2008 07:41:49 -0000 Hello , =20 I am new to FreeBSD and recently joined this mailing list. I hope that I am sending my question on the correct mailing list. We have chelsio T304 1 Gig card which supports Fiber SFP. I have already asked from chelsio guys for its Driver support on FreeBSD and still waiting for reply. Just wondering if anybody could let me know about T304's=20 Driver support on FreeBSD. One more question, because we use third party SFPs (finsar, picolight etc) so do we need to download SFP's drivers also or NIC vendor's device driver should already have that support? =20 Thanks, Satendra From owner-freebsd-drivers@FreeBSD.ORG Thu Sep 25 12:12:57 2008 Return-Path: Delivered-To: freebsd-drivers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0F37F10656A6 for ; Thu, 25 Sep 2008 12:12:57 +0000 (UTC) (envelope-from unixmania@gmail.com) Received: from ug-out-1314.google.com (ug-out-1314.google.com [66.249.92.174]) by mx1.freebsd.org (Postfix) with ESMTP id 0163D8FC1C for ; Thu, 25 Sep 2008 12:12:55 +0000 (UTC) (envelope-from unixmania@gmail.com) Received: by ug-out-1314.google.com with SMTP id m2so144226uge.39 for ; Thu, 25 Sep 2008 05:12:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:cc:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=RaTtgNlOdEJyu08uOMsIKcrO/zDuDcETCCbF27FYvY4=; b=l39W3mO0i9gU5OkAi9tCm4n4a9SJwOaAZECf1BPIs8mfG8Z2VbUtgNJSw1V+ZA6Ydv BsNAU1ff2mH50ztAEsTEnjxgZArE4oc+ZhRStZodxlW9Y0/hN1zWWv99VC+hSitwXL4n EFy9Ocnl1sgFzo6SyKmpY6WpQRT9d222oCbhk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=lHJxulUxvwJ1ZXfVIn0wlbEqyfHSJbFhOZdxTLGzSFvwSlllTOOeFBWi65Gv4LsK6z xNJbZE3+gS7IdkYrvPf3Hj1+eRL/MRTTt3780st65gkuiB47io1UeKIv9N5mzY5Qy26m Uxe/0dKOXF7mTWykDnJSf00TvpTHl+h8jCLF8= Received: by 10.103.171.6 with SMTP id y6mr5742335muo.101.1222343426749; Thu, 25 Sep 2008 04:50:26 -0700 (PDT) Received: by 10.103.231.14 with HTTP; Thu, 25 Sep 2008 04:50:26 -0700 (PDT) Message-ID: Date: Thu, 25 Sep 2008 08:50:26 -0300 From: "Carlos A. M. dos Santos" To: "Satendra Pratap" In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: Cc: freebsd-drivers@freebsd.org, Kip Macy Subject: Re: regarding 1 Gig Chelsio SFP support X-BeenThere: freebsd-drivers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Writing device drivers for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Sep 2008 12:12:57 -0000 On Thu, Sep 25, 2008 at 4:13 AM, Satendra Pratap wrote: --8<--- > We have chelsio T304 1 Gig card which supports Fiber SFP. I have already > asked from chelsio guys for its Driver support on FreeBSD and still > waiting for reply. Just wondering if anybody could let me know about > T304's Driver support on FreeBSD. > > One more question, because we use third party SFPs (finsar, picolight > etc) so do we need to download SFP's drivers also or NIC vendor's > device driver should already have that support? Kip Macy is the maintainer of drivers for some Chelsio hardware. If you are attempting to use the hardware on FreeBSD 6.x of 7.x then ask in the freebsd-stable mailing list, otherwise ask in freebsd-current. -- cd /usr/ports/sysutils/life make clean