From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753896AbYJCQ0t (ORCPT ); Fri, 3 Oct 2008 12:26:49 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752729AbYJCQ0l (ORCPT ); Fri, 3 Oct 2008 12:26:41 -0400 Received: from hrndva-omtalb.mail.rr.com ([71.74.56.125]:42230 "EHLO hrndva-omtalb.mail.rr.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752722AbYJCQ0k (ORCPT ); Fri, 3 Oct 2008 12:26:40 -0400 Date: Fri, 3 Oct 2008 12:26:31 -0400 (EDT) From: Steven Rostedt X-X-Sender: rostedt@gandalf.stny.rr.com To: Mathieu Desnoyers cc: Ingo Molnar , Linus Torvalds , Peter Zijlstra , Jonathan Corbet , LKML , Thomas Gleixner , Andrew Morton , prasad@linux.vnet.ibm.com, "Frank Ch. Eigler" , David Wilder , hch@lst.de, Martin Bligh , Christoph Hellwig , Masami Hiramatsu , Steven Rostedt , Arnaldo Carvalho de Melo Subject: Re: [PATCH] x86 Topology cpu_to_node parameter check In-Reply-To: <20081003155605.GC1607@Krystal> Message-ID: References: <20081002085030.GF26084@elte.hu> <20081002085145.GA3202@elte.hu> <20081002090517.GA8708@elte.hu> <20081002093835.GA17699@elte.hu> <20081003045607.GA5940@Krystal> <20081003155605.GC1607@Krystal> User-Agent: Alpine 1.10 (DEB 962 2008-03-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 3 Oct 2008, Mathieu Desnoyers wrote: > > That's how I did it first, but then I looked at asm-generic/topology.h > and have seen it uses #defines. Should we change them too ? > The old way of doing this is with defines. But all new code should be static inline functions when feasible. This way we can get typechecking on the parameters even when the configuration is disabled. Even if the rest of the file uses defines, the new code should be static inlines. Eventually, even the old defines will be converted. -- Steve