From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13891 invoked by alias); 4 Sep 2010 08:39:34 -0000 Received: (qmail 13878 invoked by uid 22791); 4 Sep 2010 08:39:32 -0000 X-SWARE-Spam-Status: No, hits=-1.4 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE X-Spam-Check-By: sourceware.org Received: from mail-iw0-f169.google.com (HELO mail-iw0-f169.google.com) (209.85.214.169) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 04 Sep 2010 08:39:27 +0000 Received: by iwn33 with SMTP id 33so3246709iwn.0 for ; Sat, 04 Sep 2010 01:39:25 -0700 (PDT) Received: by 10.231.192.67 with SMTP id dp3mr2197775ibb.180.1283589564984; Sat, 04 Sep 2010 01:39:24 -0700 (PDT) Received: from [192.168.1.239] ([202.201.14.141]) by mx.google.com with ESMTPS id n20sm3047351ibe.17.2010.09.04.01.39.20 (version=SSLv3 cipher=RC4-MD5); Sat, 04 Sep 2010 01:39:24 -0700 (PDT) Subject: Re: Linux Kernel GDB tracepoint module 2010-8-30 release From: Steven To: Hui Zhu Cc: "gdb@sourceware.org" , linux-kernel@vger.kernel.org, Michael Snyder , Marc Khouzam , Thiago Jung Bauermann , "Frank Ch. Eigler" In-Reply-To: References: <1283504768.2100.43.camel@steven> Content-Type: text/plain; charset="UTF-8" Date: Sat, 04 Sep 2010 08:39:00 -0000 Message-ID: <1283589558.1685.20.camel@steven> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes 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 X-SW-Source: 2010-09/txt/msg00023.txt.bz2 On Sat, 2010-09-04 at 11:41 +0800, Hui Zhu wrote: > Hi Steven, > > On Fri, Sep 3, 2010 at 17:06, Steven wrote: > > Dear Hui, > > > > I encountered two issue when I use your GTP. > > > > 1) Following your HOWTO, I collect the two variables > jiffies_64(global), > > *file(argument), the result are as following, where you may see > > jiffies_64 = 4298520928, that's OK, but the members of *file are all > 0. > > What's the problem? Thank you very much! > > > ------------------------------------------------------------------- > > (gdb) trace vfs_readdir > > Tracepoint 3 at 0xc1175690: file fs/readdir.c, line 23. > > (gdb) actions > > Enter actions for tracepoint 3, one per line. > > End with a line saying just "end". > > > collect jiffies_64 > > > collect *file > > > end > > (gdb) tstart > > (gdb) tstop > > (gdb) tfind > > #0 0xc1175691 i (file=0x0, filler=0, buf=0x0) at > > fs/readdir.c:23 > > 23 { > > (gdb) p jiffies_64 > > $7 = 4298520928 > > (gdb) p *file > > $8 = {f_u = {fu_list = {next = 0x0, prev = 0x0}, fu_rcuhead = > > {next = 0x0, func = 0}}, f_path = {mnt = 0x0, dentry = 0x0}, > > f_op = 0x0, f_lock = {{ rlock = {raw_lock = {slock = 0}}}}, > > f_count = {counter = 0}, f_flags = 0, f_mode = 0, f_pos = 0, > > f_owner = {lock = {raw_lock = { lock = 0}}, pid = 0x0, > pid_type > > = PIDTYPE_PID, uid = 0, euid = 0, signum = 0}, f_cred = 0x0, > > f_ra = {stra_pages = 00, f_security = 0x0, private_data = > 0x0, > > f_ep_links = {next = 0x0, prev = 0x0}, f_mapping = 0x0} > > > ------------------------------------------------------------------- > > > > It looks like a old bug that I have fixed in new version. > I try it in 20100830 version cannot reproduce this issue: > (gdb) target remote /proc/gtp > Remote debugging using /proc/gtp > 0x0000000000000000 in ?? () > (gdb) trace vfs_readdir > Tracepoint 1 at 0xffffffff81147d3c: file > /home/teawater/kernel/linux-2.6/fs/readdir.c, line 24. > (gdb) actions > Enter actions for tracepoint 1, one per line. > End with a line saying just "end". > >collect jiffies_64 > >collect *file > >end > (gdb) tstart > (gdb) sh > sharedlibrary shell show > (gdb) shell ls > 2 block firmware i ipc Makefile > modules.order > scripts source t~ vmlinux > a.out crypto fs include kernel mm > Module.symvers security > System.map usr vmlinux.o > arch drivers gdb.txt init lib modules.builtin > net > sound t virt > (gdb) tstop > (gdb) tfind > Found trace frame 0, tracepoint 1 > #0 0xffffffff81147d3d in vfs_readdir (file=0xffff88007b22bcc0, > filler=0xffffffff81147ba0 , buf=0xffff88006cc31f38) > at /home/teawater/kernel/linux-2.6/fs/readdir.c:24 > 24 { > (gdb) p jiffies_64 > $1 = 4295113995 > (gdb) p *file > $2 = {f_u = {fu_list = {next = 0xffff88007b22b480, prev = > 0xffffe8ffffc86960}, fu_rcuhead = {next = 0xffff88007b22b480, > func = 0xffffe8ffffc86960}}, f_path = {mnt = 0xffff880037bd6b00, > dentry = 0xffff88007e15b6c0}, f_op = 0xffffffff81622b00, f_lock = {{ > rlock = {raw_lock = {slock = 0}}}}, f_sb_list_cpu = 1, f_count = > {counter = 2}, f_flags = 624640, f_mode = 29, f_pos = 0, f_owner = { > lock = {raw_lock = {lock = 16777216}}, pid = 0x0, pid_type = > PIDTYPE_PID, uid = 0, euid = 0, signum = 0}, f_cred = > 0xffff88007ae6f780, > f_ra = {start = 0, size = 0, async_size = 0, ra_pages = 32, > mmap_miss = 0, prev_pos = -1}, f_version = 0, f_security = 0x0, > private_data = 0x0, f_ep_links = {next = 0xffff88007b22bd68, prev = > 0xffff88007b22bd68}, f_mapping = 0xffff880036662590} > > > Could you try the new version? I think it will work OK. I use the latest GTP, the same problem, while I use the latest GDB(7.2), I get the correct value of *file(the version of my old gdb is 6.8). (Intel P3 CPU) Many thanks to ALL, Steven