From owner-freebsd-scsi@FreeBSD.ORG Sun Aug 27 06:53:13 2006 Return-Path: X-Original-To: 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 2590316A4DD; Sun, 27 Aug 2006 06:53:13 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from cs1.cs.huji.ac.il (cs1.cs.huji.ac.il [132.65.16.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id E4F0443D70; Sun, 27 Aug 2006 06:53:07 +0000 (GMT) (envelope-from danny@cs.huji.ac.il) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by cs1.cs.huji.ac.il with esmtp id 1GHEW1-0002Xx-Kh; Sun, 27 Aug 2006 09:53:05 +0300 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: Scott Long In-reply-to: <44F0582A.9080800@samsco.org> References: <000201c6c7df$cb0e8a40$0200a8c0@mrbill5> <20060825204525.GA8060@nargothrond.kdm.org> <44EF64CF.2060304@samsco.org> <44F0582A.9080800@samsco.org> Comments: In-reply-to Scott Long message dated "Sat, 26 Aug 2006 08:18:18 -0600." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sun, 27 Aug 2006 09:53:05 +0300 From: Danny Braniss Message-ID: Cc: "Kenneth D. Merry" , scsi@freebsd.org Subject: Re: iSCSI/luns/check-condition 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: Sun, 27 Aug 2006 06:53:13 -0000 [...] > > sorry to barge in :-) > > but my initial problem was that the driver went into a loop. > > 0- cam starts lun discovery > > 1- cam sends inq > > 2- target replies 'condition check' > > 3- cam ignores, > > 4- back to 1 > > This is only going to happen if the SIM is returning CAM_REQ_CMP. > You should be returning CAM_REQ_CMP_ERROR. An ASC of 0x24 will set > SS_FATAL, which will cause probedone() to break out of the probe > sequence. I was returning CAM_SCSI_STATUS_ERROR. now im returning CAM_REQ_CMP_ERR and the loop is broken, thanks. Couldn't figure out how to deal with 'ASC of 0x24' - maybe after coffee. > > > > > and i want to stop this. > > > > also, I understand the lun discovery problematic, but what if: > > when the CAM does a XPT_PATH_INQ, > > setting cpi->max_lun to CAM_DO_LUN_DISCOVERY value > > triggers a different discovery algorithm? > > This would in effect allow the SIM to provide hints on how to scan > the devices that it owns, which is a good idea. let me know if anything is done, i can test i. > > > > > danny > > PS: getting close to a new release of iscsi_initiator > > > > > > Keep up the good work! > > Scott > you guys too!! danny