From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Howells Subject: Re: [PATCH 17/17] BLOCK: Make it possible to disable the block layer [try #2] Date: Fri, 25 Aug 2006 17:23:05 +0100 Message-ID: <10117.1156522985@warthog.cambridge.redhat.com> References: <20060825142753.GK10659@infradead.org> <20060824213252.21323.18226.stgit@warthog.cambridge.redhat.com> <20060824213334.21323.76323.stgit@warthog.cambridge.redhat.com> Cc: David Howells , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Return-path: Received: from mx1.redhat.com ([66.187.233.31]:28890 "EHLO mx1.redhat.com") by vger.kernel.org with ESMTP id S1030183AbWHYQXK (ORCPT ); Fri, 25 Aug 2006 12:23:10 -0400 In-Reply-To: <20060825142753.GK10659@infradead.org> To: Christoph Hellwig Sender: linux-fsdevel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org Christoph Hellwig wrote: > Can you put this two into a single ifdef block? I suppose it could make sense to move the two disk random source functions together. > > config USB_STORAGE > > tristate "USB Mass Storage support" > > - depends on USB > > + depends on USB && BLOCK > > ditto. ditto? > again, try to reorder things here to only require a single ifdef block > (or rather two, a second one for the array entries) if possible. The problem with reordering things is that it makes the patch bigger, and that makes people complain about not minimalising the changes. > Can we put this into some other file under #ifndef CONFIG_BLOCK to > avoid the separate file and makefile ugliness? *blink* What've you done with the real Christoph Hellwig? You're actually *advocating* the use of a cpp-conditional in a .c file! It doesn't really belong in any of the files that are left. > No one should include this file unless block device support is enabled, > so I don't see the point for the ifdefs. Ditto for many other header > files you touch that don't contain any stubs for generic code. Someone did. Might've been USB storage now that I think about it. > And btw, shouldn't the option be CONFIG_BLK_DEV instead of CONFIG_BLOCK > to fit the variour CONFIG_BLK_DEV_FOO options we have? No. I'm not enabling a specific block device driver. I'm taking out the entire block layer, block drivers, block scheduler and everything that depends on it (such as SCSI). David