All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pat LaVarre <p.lavarre@ieee.org>
To: linux-fsdevel@vger.kernel.org
Subject: Re: favourite vfs globals
Date: 28 Nov 2003 14:22:48 -0700	[thread overview]
Message-ID: <1070054568.2340.50.camel@patrh9> (raw)
In-Reply-To: <1070053531.2340.40.camel@patrh9>

> Which vfs globals are the most fun, in lk like 2.6.0-test11?

That question I can't yet answer, but:

> gdb vmlinux /proc/kcore
> ... this approach to gdb takes a blurry snapshot of kernel memory and
> then walks us thru a stale copy of all the bits.

Also I suppose we can't see the global variables of modules this way,
except when the modules share those variables with non-module code i.e.
code linked into the kernel before boot.  I'm guessing wildly from
experiences like the following.

(gdb) info variables scsi_comm
All variables matching regular expression "scsi_comm":
 
File drivers/block/scsi_ioctl.c:
const unsigned char scsi_command_size[8];
static const char __kstrtab_scsi_command_size[18];
static const struct kernel_symbol __ksymtab_scsi_command_size;
(gdb) #
(gdb) print /x scsi_command_size
$2 = {0x6, 0xa, 0xa, 0xc, 0x10, 0xc, 0xa, 0xa}
(gdb) #
(gdb) file /lib/modules/2.6.0-11.udf/kernel/drivers/scsi/scsi_mod.ko
warning: core file may not match specified executable file.
Load new symbol table from
"/lib/modules/2.6.0-11.udf/kernel/drivers/scsi/scsi_mod.ko"? (y or n) y
 
Reading symbols from
/lib/modules/2.6.0-11.udf/kernel/drivers/scsi/scsi_mod.ko...done.
(gdb) #
(gdb) info variables xtime
...
(gdb) print xtime
Address of symbol "xtime" is unknown.
(gdb) #
(gdb) info variables scsi_command_size
...
(gdb) print scsi_command_size
Address of symbol "scsi_command_size" is unknown.
(gdb) #



  reply	other threads:[~2003-11-28 21:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-11-28 21:05 favourite vfs globals Pat LaVarre
2003-11-28 21:22 ` Pat LaVarre [this message]
2003-11-28 21:43   ` Pat LaVarre
2003-11-28 21:51     ` Pat LaVarre
2003-11-28 22:42       ` Pat LaVarre

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1070054568.2340.50.camel@patrh9 \
    --to=p.lavarre@ieee.org \
    --cc=linux-fsdevel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.