Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932659Ab1EYXxf (ORCPT ); Wed, 25 May 2011 19:53:35 -0400 Received: from smtp1.linux-foundation.org ([140.211.169.13]:39111 "EHLO smtp1.linux-foundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757142Ab1EYXxM (ORCPT ); Wed, 25 May 2011 19:53:12 -0400 MIME-Version: 1.0 In-Reply-To: References: <4DDB8BF6.2000304@fusionio.com> <4DDCB1C8.7040708@fusionio.com> <4DDD5240.2060308@fusionio.com> <4DDD55D6.1080909@fusionio.com> <1306356735.1641.61.camel@mulgrave.site> From: Linus Torvalds Date: Wed, 25 May 2011 16:52:20 -0700 Message-ID: Subject: Re: [PATCH] SCSI IOCTL: Check for device deletion [was Re: __elv_add_request OOPS] To: Parag Warudkar Cc: James Bottomley , Jens Axboe , "linux-kernel@vger.kernel.org" , "akpm@linux-foundation.org" , Linux SCSI List Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 817 Lines: 19 On Wed, May 25, 2011 at 4:45 PM, Parag Warudkar wrote: > > So now the issue is with scsi_device refcnt? No, I'd guess that the problem is just that __scsi_remove_device() sets queuedata to NULL. Afaik, both sdev and the queue actually stay around. That said, I don't have very high opinions of some of the SCSI code. And that's me being polite. The thing is a overcomplicated mess of indirection and pointers back-and-forth. The refcounting is crazy and/or impossible, since the pointers really do go back-and-forth. Linus -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/