From owner-freebsd-scsi@FreeBSD.ORG Fri Oct 27 22:31:25 2006 Return-Path: X-Original-To: freebsd-scsi@freebsd.org Delivered-To: freebsd-scsi@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3D15C16A403; Fri, 27 Oct 2006 22:31:25 +0000 (UTC) (envelope-from Johannes.Kruger@nokia.com) Received: from mgw-ext13.nokia.com (mgw-ext13.nokia.com [131.228.20.172]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4C3D143D45; Fri, 27 Oct 2006 22:31:24 +0000 (GMT) (envelope-from Johannes.Kruger@nokia.com) Received: from esebh105.NOE.Nokia.com (esebh105.ntc.nokia.com [172.21.138.211]) by mgw-ext13.nokia.com (Switch-3.1.10/Switch-3.1.10) with ESMTP id k9RMVIPn031373; Sat, 28 Oct 2006 01:31:22 +0300 Received: from daebh101.NOE.Nokia.com ([10.241.35.111]) by esebh105.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.1830); Sat, 28 Oct 2006 01:30:55 +0300 Received: from daebe102.NOE.Nokia.com ([10.241.35.115]) by daebh101.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.1830); Fri, 27 Oct 2006 17:30:52 -0500 x-mimeole: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Date: Fri, 27 Oct 2006 17:30:52 -0500 Message-ID: In-Reply-To: <20061027111434.E61368@ns1.feral.com> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: CAM_NEW_TRAN Thread-Index: Acb5/hoYxESEZOImQZqhF+h26wUNXgAEbNCg From: To: , X-OriginalArrivalTime: 27 Oct 2006 22:30:52.0318 (UTC) FILETIME=[8F5EBBE0:01C6FA17] X-Nokia-AV: Clean Cc: Johannes.Kruger@nokia.com Subject: RE: CAM_NEW_TRAN X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Oct 2006 22:31:25 -0000 Hi Matthew. Seeing you guys talking about the CAM_NEW_TRAN, I just want to mention that I got the LSI1064 and LSI1064E to work with the mpt driver .. and yes, I used the NEW CAM code. So the background is that I took the mpt driver and ported it to a OS that is the equivalent of FreeBSD-2.X.X with some alterations. To make a long story short our OS needed more recent CAM code to work with mpt. So this is what I needed to do to make it (mpt) work (remember RAID-1 was slow in FreeBSD and the OS I was working on). These are just hacks to give you some data: 1) In order for the RAID-1 volume to be probed in IOC Page 2, I had to force the port to on first, otherwise the RAID personality would not successfully probe the RAID-1 volume. In the file mpt.c I changed: if (portenable) { to if (1) { 2) Some changes in the Firmware: - Port numbers in the PHY's was all 0 for Wide configs, so I made PHY0 a 0 and changed PHY1 from 0 to 1, Port setting in SAS IO Unit Page 1 - RAID Volume Page 0, IM VolumeSettings set to 0x5, IS VolumeSettings = =3D 0x1 - ResyncRate set low =3D 0x2 - IOC Page 1 (Think these are needed for speed increase) from 15 MB/s to 32 MB/s - Doubled Coalescing Depth from 0x4 to 0x8 - Halfed the CoalecingTimeout from 0x10 to 0x8 - Enabled NCQ (made a bit difference) - Also, in one of the registers there is a setting to specify if it's via expander or directly attached. Changed this to "directly attached" via the SATA/SAS cables. 3) Works fine for SATA, then I tested SAS. I got 50-52 MB/s for SAS drives running 7200rpm versus 30 MB/s for SATA at 4500rpm It's small laptop size drives. But ... when I remove the drives, and I re-insert it, I would get "Invalidating pack" messages from the CAM code. Turns out that the SAS drives takes a while to spin up. It actually sounds like it's changing gears or something :-), distinctive sound difference in a multistep spinup ... interesting. Have to go read what the powerup sequence for SAS drives are. So, for now I added a delay of 10 seconds if the volume flags indicates failure and now the re-insert is fine. I Might change this to a poll ... but I see there is some settings regarding spinup delay and IOC report time before indicating the drive presence, thant might work. In function mpt_refresh_raid_data ----------------------- snippet ----------------------- . . CONFIG_PAGE_RAID_VOL_0 *vol_pg; size_t len; int rv; int i; int settle =3D 10; <############# ADDED THIS #######> u_int nonopt_volumes; . . . . if (vol_pg->VolumeStatus.State !=3D MPI_RAIDVOL0_STATUS_STATE_OPTIMAL) nonopt_volumes++; if ((mpt_vol->flags & MPT_RVF_UP2DATE) !=3D 0) continue; ################> ADDED PARTS BETWEEN IFDEF and defined it <####################### #ifdef SAS_SLOW_START if (mpt_vol->config_page->VolumeStatus.State =3D=3D MPI_RAIDVOL0_STATUS_STATE_FAILED) { printf("Waiting %d seconds for device to settle ", =20 settle); while (settle) { settle--; DELAY(1000000); printf("."); } printf("\n"); mpt->raid_nonopt_volumes =3D nonopt_volumes; return (0); } #endif mpt_vol->flags |=3D MPT_RVF_UP2DATE; ----------------------- snippet ----------------------- Anyway, this is just some more data that can help, because I want this to work well on FreeBSD. Johan -----Original Message----- From: owner-freebsd-scsi@freebsd.org [mailto:owner-freebsd-scsi@freebsd.org]=20 Sent: Friday, October 27, 2006 2:15 PM To: freebsd-scsi@freebsd.org Subject: Re: CAM_NEW_TRAN I can take on most of the work. > mjacob@freebsd.org wrote: >>=20 >> Is there any reason to *not* proceed with CAM_NEW_TRAN and just bite the=20 >> bullet now and move ahead? >>=20 > > I have no objection against it. > > Scott > _______________________________________________ freebsd-scsi@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-scsi To unsubscribe, send any mail to "freebsd-scsi-unsubscribe@freebsd.org"