Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755799Ab0LTKtl (ORCPT ); Mon, 20 Dec 2010 05:49:41 -0500 Received: from verein.lst.de ([213.95.11.210]:48295 "EHLO verein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755629Ab0LTKtj (ORCPT ); Mon, 20 Dec 2010 05:49:39 -0500 Date: Mon, 20 Dec 2010 11:48:20 +0100 From: Christoph Hellwig To: "Nicholas A. Bellinger" Cc: linux-scsi , linux-kernel , James Bottomley , Jeff Garzik , Christoph Hellwig , FUJITA Tomonori , Hannes Reinecke , Mike Christie , Mike Anderson , Tejun Heo , Vasu Dev , Tim Chen , Andi Kleen , Ravi Anand , Andrew Vasquez , Joe Eykholt , James Smart , Douglas Gilbert , adam radford , Kashyap Desai , MPTFusionLinux Subject: Re: [PATCH 02/12] scsi: Add IRQ_DISABLE_SCSI_QCMD wrapper Message-ID: <20101220104820.GA2752@lst.de> References: <1292793727-31957-1-git-send-email-nab@linux-iscsi.org> <1292793727-31957-3-git-send-email-nab@linux-iscsi.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1292793727-31957-3-git-send-email-nab@linux-iscsi.org> User-Agent: Mutt/1.3.28i X-Spam-Score: 0 () Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1152 Lines: 22 On Sun, Dec 19, 2010 at 01:21:57PM -0800, Nicholas A. Bellinger wrote: > From: Nicholas Bellinger > > This patch adds a IRQ_DISABLE_SCSI_QCMD() wrapper macro used by LLDs > that can now run in host_lock less mode, but still need interrupts disabled > using local_irq_save() before calling their lld_queuecommand() dispatcher. > > jgarzik says this method is in fact slower than doing a spin_lock_irqsave() on > internal lib_lld_queuecommand() callers (as is done in libiscsi and libata) > but is still needed by the majority of lock_less LLDs. As mentioned before, please don't add more macro obsfucation - The initial one Jeff added was ok for the quick transition and avoiding to have two methods, but any additional one is not helpful. In addition there's really no reason to every use this one. There is not reason to disable local irqs in a driver without taking a spinlock. -- 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/