Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S263454AbVCMIyP (ORCPT ); Sun, 13 Mar 2005 03:54:15 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S263452AbVCMIyP (ORCPT ); Sun, 13 Mar 2005 03:54:15 -0500 Received: from pfepc.post.tele.dk ([195.41.46.237]:31831 "EHLO pfepc.post.tele.dk") by vger.kernel.org with ESMTP id S263457AbVCMIxc (ORCPT ); Sun, 13 Mar 2005 03:53:32 -0500 Date: Sun, 13 Mar 2005 09:54:41 +0100 From: Sam Ravnborg To: Paulo Marques Cc: Dominik Brodowski , Andrew Morton , linux-kernel@vger.kernel.org Subject: Re: inconsistent kallsyms data [2.6.11-mm2] Message-ID: <20050313085441.GA24006@mars.ravnborg.org> Mail-Followup-To: Paulo Marques , Dominik Brodowski , Andrew Morton , linux-kernel@vger.kernel.org References: <20050308033846.0c4f8245.akpm@osdl.org> <20050308192900.GA16882@isilmar.linta.de> <20050308123554.669dd725.akpm@osdl.org> <20050308204521.GA17969@isilmar.linta.de> <422EF2B0.7070304@grupopie.com> <422F59A3.9010209@grupopie.com> <423039A6.5010301@grupopie.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <423039A6.5010301@grupopie.com> User-Agent: Mutt/1.5.6i Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2144 Lines: 63 On Thu, Mar 10, 2005 at 12:12:22PM +0000, Paulo Marques wrote: > Paulo Marques wrote: > >[...] > >A simple and robust way is to do the sampling on a list of symbols > >sorted by symbol name. This way, even if the symbol positions that are > >given to scripts/kallsyms change, the symbols sampled will be the same. > > > >I'll do the patch to do this and send it ASAP. > > Ok, here it is. > > Dominik can you try the attached patch and see if it solves the problem? Hi Paulo. Alexander Stohr had similar problems with down and __sched_text_start. I figured out that what was causing the troubles was the fact that the linker generated symbol __sched_text_start changed value from pass 1 to pass 2. The reason for this was the alingment used within that section. My stamp on this is attached. I never came around submitting this since I do not know what the correct number for function alignment is on different paltforms. Sam ===== include/asm-generic/vmlinux.lds.h 1.16 vs edited ===== --- 1.16/include/asm-generic/vmlinux.lds.h 2004-10-06 18:45:06 +02:00 +++ edited/include/asm-generic/vmlinux.lds.h 2004-11-06 21:56:11 +01:00 @@ -6,6 +6,11 @@ #define VMLINUX_SYMBOL(_sym_) _sym_ #endif +/* Aling functions to a 8 byte boundary. + * This prevents lables defined to mark start/end of section to differ + * during pass 1 and pass 2 when generating System.map */ +#define ALIGN_FUNCTION() . = ALIGN(8) + #define RODATA \ .rodata : AT(ADDR(.rodata) - LOAD_OFFSET) { \ *(.rodata) *(.rodata.*) \ @@ -77,11 +82,13 @@ } #define SCHED_TEXT \ + ALIGN_FUNCTION(); \ VMLINUX_SYMBOL(__sched_text_start) = .; \ *(.sched.text) \ VMLINUX_SYMBOL(__sched_text_end) = .; #define LOCK_TEXT \ + ALIGN_FUNCTION(); \ VMLINUX_SYMBOL(__lock_text_start) = .; \ *(.spinlock.text) \ VMLINUX_SYMBOL(__lock_text_end) = .; - 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/