From mboxrd@z Thu Jan 1 00:00:00 1970 From: Sagi Grimberg Subject: Re: [PATCH] IB/srp: Fail I/O requests if the transport is offline Date: Sun, 24 Feb 2013 10:59:17 +0200 Message-ID: <5129D665.3070206@mellanox.com> References: <510BDCAA.204@acm.org> <5111327F.6050402@acm.org> <5112049B.8030406@acm.org> <5112CE60.2030607@mellanox.com> <51136E74.9090209@acm.org> <5113F056.4020501@mellanox.com> <511E024E.70002@acm.org> <1361160385.7415.2.camel@obelisk.thedillows.org> <5121E217.3080003@mellanox.com> <5129CAB6.5030506@acm.org> Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1"; format=flowed Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <5129CAB6.5030506-HInyCGIudOg@public.gmane.org> Sender: linux-rdma-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Bart Van Assche Cc: David Dillow , Vu Pham , Or Gerlitz , Roland Dreier , "linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" , Or Gerlitz List-Id: linux-rdma@vger.kernel.org On 2/24/2013 10:09 AM, Bart Van Assche wrote: > On 02/18/13 09:11, Sagi Grimberg wrote: >> On 2/18/2013 6:06 AM, David Dillow wrote: >>> On Fri, 2013-02-15 at 10:39 +0100, Bart Van Assche wrote: >>>> diff --git a/drivers/infiniband/ulp/srp/ib_srp.c >>>> b/drivers/infiniband/ulp/srp/ib_srp.c >>>> index 8a7eb9f..b34752d 100644 >>>> --- a/drivers/infiniband/ulp/srp/ib_srp.c >>>> +++ b/drivers/infiniband/ulp/srp/ib_srp.c >>>> @@ -734,6 +734,7 @@ static int srp_reconnect_target(struct >>>> srp_target_port *target) >>>> scsi_target_unblock(&shost->shost_gendev, ret == 0 ? >>>> SDEV_RUNNING : >>>> SDEV_TRANSPORT_OFFLINE); >>>> + target->transport_offline = ret != 0; >>> Minor nit, that line is hard to read; I keep thinking it needs parens >>> around the conditional... >>> >>> Perhaps >>> target->transport_offline = !!ret; >>> or >>> target->transport_offline = ret; >>> >>> gcc should do the right conversion since we're assigning to a bool. >>> >>> >>> Or, Vu, does this solve the issue you've seen? I may have time to test >>> later this week, but not before. >> >> This indeed solve scsi_host removal issues. >> Vu is on vacation, I'll perform some more failover tests... > > Hello Sagi, > > Since no further feedback was posted on the list I assume that means > that all tests passed ? > > Bart. > Hey Bart, Sorry for the delay I was just about to reply... From my end, the related patchset seems solve the scsi_host removal issue and prevents the SCSI error handling loop. Generally our tests passed, I still have some issue with long-term failover test but I'm not sure its SRP (perhaps might origin in IB layer). So ack from me... -Sagi -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html