From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933381AbdCaOMu (ORCPT ); Fri, 31 Mar 2017 10:12:50 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:44944 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933231AbdCaOMq (ORCPT ); Fri, 31 Mar 2017 10:12:46 -0400 Date: Fri, 31 Mar 2017 16:12:29 +0200 From: Greg Kroah-Hartman To: Joe Korty Cc: James Bottomley , Andrey Grodzovsky , Suganath Prabu S , Sreekanth Reddy , Sathya Prakash , Chaitra P B , Christoph Hellwig , Hannes Reinecke , Ingo Molnar , Linux SCSI Mailing List , Linux Kernel Mailing List , Linux Stable Mailing List , Bart Van Assche , "Martin K. Petersen" Subject: Re: [PATCH] scsi: mpt3sas: fix hang on ata passthrough commands Message-ID: <20170331141229.GB8141@kroah.com> References: <20170331135030.GA24063@zipoli.ccur.kvm> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170331135030.GA24063@zipoli.ccur.kvm> User-Agent: Mutt/1.8.0 (2017-02-23) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 31, 2017 at 09:50:30AM -0400, Joe Korty wrote: > [PATCH] scsi: mpt3sas: fix hang on ata passthrough commands > > commit 16236802bfecb1082144a48b7d6fa60997824662 upstream > commit ffb58456589443ca572221fabbdef3db8483a779 upstream > > Lockdep complains that the base level-only hctx->lock > is being grabbed from interrupt level, at the time the > mpt3sas driver initializes. This is a result of two > of three tightly interconnected mpt3sas bugfix patches > having been backported into 4.4. The previously two ported > patches are: > > > From: Andrey Grodzovsky > > Date: Thu, 10 Nov 2016 09:35:27 -0500 > > Subject: [PATCH] scsi: mpt3sas: Fix secure erase premature termination > > Git-Commit: ffffc1ed47e76d13cafbc645792ca184331b3123 > > > From: Suganath Prabu S > > Date: Thu, 17 Nov 2016 16:15:58 +0530 > > Subject: [PATCH] scsi: mpt3sas: Unblock device after controller reset > > Git-Commit: 6eddf5c993dd9bf4efcf2509e4ca633b9441a66a > > The missing third patch is attached below. > > Signed-off-by: Joe Korty > > > > From: James Bottomley > > Date: Sun, 1 Jan 2017 09:39:24 -0800 > > Subject: [PATCH] scsi: mpt3sas: fix hang on ata passthrough commands > > Git-Commit: 16236802bfecb1082144a48b7d6fa60997824662 > > commit ffb58456589443ca572221fabbdef3db8483a779 upstream. > > mpt3sas has a firmware failure where it can only handle one pass through > ATA command at a time. If another comes in, contrary to the SAT > standard, it will hang until the first one completes (causing long > commands like secure erase to timeout). The original fix was to block > the device when an ATA command came in, but this caused a regression > with > > commit 669f044170d8933c3d66d231b69ea97cb8447338 > Author: Bart Van Assche > Date: Tue Nov 22 16:17:13 2016 -0800 > > scsi: srp_transport: Move queuecommand() wait code to SCSI core > > So fix the original fix of the secure erase timeout by properly > returning SAM_STAT_BUSY like the SAT recommends. The original patch > also had a concurrency problem since scsih_qcmd is lockless at that > point (this is fixed by using atomic bitops to set and test the flag). > > [mkp: addressed feedback wrt. test_bit and fixed whitespace] > > Fixes: 18f6084a989ba1b (mpt3sas: Fix secure erase premature termination) > Signed-off-by: James Bottomley > Acked-by: Sreekanth Reddy > Reviewed-by: Christoph Hellwig > Reported-by: Ingo Molnar > Tested-by: Ingo Molnar > Signed-off-by: Martin K. Petersen > Signed-off-by: Greg Kroah-Hartman I signed off on this patch? When? Where? totall confused here, greg k-h