Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752859Ab3GCAwt (ORCPT ); Tue, 2 Jul 2013 20:52:49 -0400 Received: from intranet.asianux.com ([58.214.24.6]:46211 "EHLO intranet.asianux.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751486Ab3GCAwr (ORCPT ); Tue, 2 Jul 2013 20:52:47 -0400 X-Spam-Score: -100.7 Message-ID: <51D375AA.5060300@asianux.com> Date: Wed, 03 Jul 2013 08:51:54 +0800 From: Chen Gang User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130110 Thunderbird/17.0.2 MIME-Version: 1.0 To: Geert Uytterhoeven CC: Richard Weinberger , Arnd Bergmann , Jeff Dike , David Sharp , "sfr@canb.auug.org.au" , Steven Rostedt , Ingo Molnar , uml-devel , uml-user , "linux-kernel@vger.kernel.org" , Linux-Arch , Mark Brown , David Miller , Andrew Morton , Jiri Kosina Subject: Re: [PATCH] include/asm-generic/io.h: add dummy fuctions to support 'COMPILE_TEST' in 'asm-generic'. References: <51CA8AB8.7080504@asianux.com> <51CA900E.9020407@nod.at> <51CA9E92.4000107@asianux.com> <51CAA0C6.60007@nod.at> <51CAA78C.5040900@asianux.com> <51CAA8D6.9000505@nod.at> <51CAAD1D.8050801@asianux.com> <51CAAE7C.9090003@nod.at> <51CAB556.4070700@asianux.com> <51CAB689.70008@nod.at> <51CABBDD.403@asianux.com> <51CABFAC.1040505@nod.at> <51CAC0D0.60505@asianux.com> <51D0DE09.4090702@asianux.com> <51D0FAFE.5010500@asianux.com> <51D23766.8000605@asianux.com> <51D2888E.8020503@asianux.com> In-Reply-To: Content-Type: text/plain; charset=GB2312 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2633 Lines: 63 On 07/02/2013 06:57 PM, Geert Uytterhoeven wrote: > On Tue, Jul 2, 2013 at 10:00 AM, Chen Gang wrote: >> > On 07/02/2013 03:19 PM, Geert Uytterhoeven wrote: >>> >> On Tue, Jul 2, 2013 at 4:13 AM, Chen Gang wrote: >>>>> >>> > 'asm-generic' need provide necessary configuration checking, if can't >>>>> >>> > pass checking, 'asm-generic' shouldn't implement it. >>>>> >>> > >>>>> >>> > For 'COMPILE_TEST', according to its help contents, 'asm-generic' need >>>>> >>> > let it pass configuration checking, and provide related dummy contents >>>>> >>> > for it. >>>>> >>> > >>>>> >>> > Part of 'COMPLE_TEST' help contents in "init/Kconfig": >>>>> >>> > >>>>> >>> > "...Despite they cannot be loaded there (or even when they load they cannot be used due to missing HW support)..." >>>>> >>> > >>>>> >>> > >>>>> >>> > Signed-off-by: Chen Gang >>> >> NAKed-by: Geert Uytterhoeven >>> >> >>> >> Please don't clutter the code with checks for CONFIG_COMPILE_TEST. >> > >> > Do you mean: 'asm-generic' should not support 'COMPILE_TEST' (the >> > platform should not support 'COMPILE_TEST") ? >> > >> > Or you mean: 'COMPILE_TEST' should not exist in kernel ? > I mean that COMPILE_TEST should exist in Kconfig files only. > It's only meant to have more compile coverage, not to "fix" (through #ifdef) > more code to make it compile. If so, can we allow the module to 'COMPILE_TEST' under one platform which not support the related HW ? e.g. "...Despite they cannot be loaded there (or even when they load they cannot be used due to missing HW support)...". 'asm-generic' need provide generic layer to users (both architecture guys and module guys). So for 'default', it can depend on some conditions (e.g. HW support); but for 'generic', it need try to be independent from any conditions. And it is also necessary for 'generic' to provide the configuration checking features, but this checking must be no negative effect (or consistent) with its 'generic' services. So it is necessary to check 'NOMMU', 'CONFIG_HAS_IOMEM' ..., but it also necessary to consider about 'COMPILE_TEST' to be consistent with its 'generic' services. BTW: 20% code are for 80% features, but the left 20% features, need 80% code, if we have to make it complete, we have to face this 'rule'. Thanks. -- Chen Gang -- 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/