Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753549Ab3JYXa2 (ORCPT ); Fri, 25 Oct 2013 19:30:28 -0400 Received: from ozlabs.org ([203.10.76.45]:50113 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751935Ab3JYXa1 (ORCPT ); Fri, 25 Oct 2013 19:30:27 -0400 From: Rusty Russell To: Ming Lei Cc: Russell King - ARM Linux , Andrew Morton , Linux Kernel Mailing List , Chen Gang , linux-arm-kernel Subject: Re: [RFC PATCH] kernel/kallsyms.c: only show legal kernel symbol In-Reply-To: References: <1382498320-26594-1-git-send-email-tom.leiming@gmail.com> <87eh7bfoq9.fsf@rustcorp.com.au> <20131024084559.GD16735@n2100.arm.linux.org.uk> <87mwlyclng.fsf@rustcorp.com.au> <87y55h7vcd.fsf@rustcorp.com.au> User-Agent: Notmuch/0.15.2 (http://notmuchmail.org) Emacs/23.4.1 (i686-pc-linux-gnu) Date: Fri, 25 Oct 2013 22:28:29 +1030 Message-ID: <87sivp7eai.fsf@rustcorp.com.au> 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 Content-Length: 1463 Lines: 36 Ming Lei writes: > On Fri, Oct 25, 2013 at 1:50 PM, Rusty Russell wrote: >> Ming Lei writes: >>> On Fri, Oct 25, 2013 at 7:08 AM, Rusty Russell wrote: >>>> >>>> Sorry, I was imprecise. I was referring to the kernel's kallsyms >>>> tables produced by scripts/kallsyms.c. This patch left them in the >>>> the kallsyms tables and filtered them out from /proc/kallsyms. >>> >>> Yes, but it isn't easy to do it by script/kallsyms.c , and IMO, it should >>> be correct to hide them for user space but keep them in kallsyms table. >> >> So they'll appear in backtraces? And turn up randomly for other symbol >> dereferences? >> >> I don't think you really want this! > > Basically these symbols are only used to generate code, and in > kernel mode, CPU won't run into the corresponding addresses > because the generate code is copied to other address during booting, > so I understand they won't appear in backtraces. An oops occurs when something went *wrong*. We look up all kinds of stuff. Are you so sure that *none* of the callers will ever see these strange symbols and produce a confusing result? Cheers, 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/