Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755367AbYHNX11 (ORCPT ); Thu, 14 Aug 2008 19:27:27 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752113AbYHNX1R (ORCPT ); Thu, 14 Aug 2008 19:27:17 -0400 Received: from ozlabs.org ([203.10.76.45]:45432 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751900AbYHNX1Q (ORCPT ); Thu, 14 Aug 2008 19:27:16 -0400 From: Rusty Russell To: Steven Rostedt Subject: Re: [PATCH v2 3/6] ftrace: enable mcount recording for modules Date: Fri, 15 Aug 2008 09:26:07 +1000 User-Agent: KMail/1.9.9 Cc: linux-kernel@vger.kernel.org, Ingo Molnar , Thomas Gleixner , Peter Zijlstra , Andrew Morton , Linus Torvalds , David Miller , Mathieu Desnoyers , Roland McGrath , Ulrich Drepper , Jeremy Fitzhardinge , Gregory Haskins , Arnaldo Carvalho de Melo , "Luis Claudio R. Goncalves" , Clark Williams , Bruce Duncan , Marcin Slusarz , Steven Rostedt References: <20080814194506.233473381@goodmis.org> <20080814194859.811269740@goodmis.org> In-Reply-To: <20080814194859.811269740@goodmis.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200808150926.08200.rusty@rustcorp.com.au> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 642 Lines: 16 On Friday 15 August 2008 05:45:09 Steven Rostedt wrote: > This patch enables the loading of the __mcount_section of modules and > changing all the callers of mcount into nops. ... > + if (mcountindex) { > + void *mseg = (void *)sechdrs[mcountindex].sh_addr; > + ftrace_init_module(mseg, mseg + sechdrs[mcountindex].sh_size); You don't actually need the if. The size of section 0 is 0. Rusty. -- 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/