From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17876 invoked by alias); 3 Jul 2013 09:06:48 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 17838 invoked by uid 89); 3 Jul 2013 09:06:41 -0000 X-Spam-SWARE-Status: No, score=-2.9 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,KHOP_THREADED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE,SPF_PASS autolearn=ham version=3.3.1 Received: from mail-ve0-f180.google.com (HELO mail-ve0-f180.google.com) (209.85.128.180) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Wed, 03 Jul 2013 09:06:41 +0000 Received: by mail-ve0-f180.google.com with SMTP id pa12so5623644veb.25 for ; Wed, 03 Jul 2013 02:06:39 -0700 (PDT) MIME-Version: 1.0 X-Received: by 10.220.163.72 with SMTP id z8mr12605466vcx.89.1372842399116; Wed, 03 Jul 2013 02:06:39 -0700 (PDT) Received: by 10.52.22.73 with HTTP; Wed, 3 Jul 2013 02:06:39 -0700 (PDT) In-Reply-To: <20130703090259.GA1854@host2.jankratochvil.net> References: <20130703084207.GA598@host2.jankratochvil.net> <20130703090259.GA1854@host2.jankratochvil.net> Date: Wed, 03 Jul 2013 09:06:00 -0000 Message-ID: Subject: Re: vdso From: vijay nag To: Jan Kratochvil Cc: gdb@sourceware.org Content-Type: text/plain; charset=ISO-8859-1 X-SW-Source: 2013-07/txt/msg00012.txt.bz2 On Wed, Jul 3, 2013 at 2:32 PM, Jan Kratochvil wrote: > On Wed, 03 Jul 2013 10:48:48 +0200, vijay nag wrote: >> 5: ffffe400 20 FUNC GLOBAL DEFAULT 6 __kernel_vsyscall@@LINUX_2.5 > > So your Linux kernel is OK. You should check GDB function add_vsyscall_page > on your system why it did not do what it should do. > > > Regards, > Jan Below are the code excerpts from that function. My gdb version is 7.5 dd_vsyscall_page (struct target_ops *target, int from_tty) { CORE_ADDR sysinfo_ehdr; if (target_auxv_search (target, AT_SYSINFO_EHDR, &sysinfo_ehdr) > 0 && sysinfo_ehdr != (CORE_ADDR) 0) { struct bfd *bfd; struct symbol_file_add_from_memory_args args; if (core_bfd != NULL) bfd = core_bfd; else if (exec_bfd != NULL) bfd = exec_bfd; else /* FIXME: cagney/2004-05-06: Should not require an existing BFD when trying to create a run-time BFD of the VSYSCALL page in the inferior. Unfortunately that's the current interface so for the moment bail. Introducing a ``bfd_runtime'' (a BFD created using the loaded image) file format should fix this. */ { warning (_("Could not load vsyscall page " "because no executable was specified\n" "try using the \"file\" command first.")); return; } args.bfd = bfd; args.sysinfo_ehdr = sysinfo_ehdr; args.name = xstrprintf ("system-supplied DSO at %s", paddress (target_gdbarch, sysinfo_ehdr)); /* Pass zero for FROM_TTY, because the action of loading the vsyscall DSO was not triggered by the user, even if the user typed "run" at the TTY. */ args.from_tty = 0; catch_exceptions (current_uiout, symbol_file_add_from_memory_wrapper, &args, RETURN_MASK_ALL); } }