public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
From: "Frank Ch. Eigler" <fche@redhat.com>
To: James Bottomley <James.Bottomley@HansenPartnership.com>
Cc: Masami Hiramatsu <mhiramat@redhat.com>,
	        linux-kernel <linux-kernel@vger.kernel.org>,
	systemtap@sourceware.org
Subject: Re: [RFC] systemtap: begin the process of using proper kernel APIs (part1: use kprobe symbol_name/offset instead of address)
Date: Thu, 17 Jul 2008 21:35:00 -0000	[thread overview]
Message-ID: <20080717213355.GJ18295@redhat.com> (raw)
In-Reply-To: <1216328769.5515.78.camel@localhost.localdomain>

Hi -


On Thu, Jul 17, 2008 at 04:06:09PM -0500, James Bottomley wrote:

> [...]
> > My point is that the proposed effort to identify a nearby function
> > symbol to use as a base for each probe's symbol+offset calculation is
> > wasted.
> 
> It's not exactly wasted ... the calculations have to be done anyway for
> modules.

Not really - we just anchor off a different (per-module) reference
symbol or address.  At the moment, we use the .text* section bases.


> > > you've lost access to the symbols in the sections that start before _stext.  
> > 
> > What's between _text and _stext appears to consist of kernel boot-time
> > functions that are unmapped the time anything like systemtap could
> > run.
> 
> Well, no, they're the head code.  It's actually used in CPU boot and
> tear down, one of the things it's useful to probe, I think.

Fair enough - conceivably probing that stuff is useful, as is module
initialization.  We don't try to do it yet (and indeed kprobes blocks
it all).

In any case, the method of probe address calculation doesn't affect
that issue.  We can calculate .init* addresses relative to any
convenient reference in exactly the same way as non-.init addresses.


> > > Assuming you meant _text (which is dangerous because it's a define
> > > in the kernel linker script and could change).
> > 
> > By "dangerous" do you only mean that it may require a one-liner
> > catch-up patch in systemtap if the kernel linker scripts change?
> 
> Dangerous as in it's not necessarily part of the kernel linker scripts.
> [...]
> The point, really, is to remove some of the fragile dependencies between
> systemtap and the kernel.

Yes, that is generally desirable - each case is usually a question of
cost/benefit.  One significant requirement for us is to keep working
with older kernels.


- FChE

  reply	other threads:[~2008-07-17 21:35 UTC|newest]

Thread overview: 49+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-15 18:33 James Bottomley
2008-07-16 22:42 ` Masami Hiramatsu
2008-07-16 23:03   ` James Bottomley
2008-07-17  0:07     ` Masami Hiramatsu
2008-07-17  1:50       ` James Bottomley
2008-07-17 14:18         ` James Bottomley
2008-07-17 16:59           ` James Bottomley
2008-07-17 21:38             ` Masami Hiramatsu
2008-07-17 22:03               ` James Bottomley
2008-07-21 14:21               ` James Bottomley
     [not found]           ` <1216313914.5515.25.camel__21144.9282979176$1216314027$gmane$org@localhost.localdomain>
2008-07-17 18:32             ` Frank Ch. Eigler
2008-07-17 20:13               ` James Bottomley
2008-07-17 20:28                 ` Frank Ch. Eigler
2008-07-17 21:06                   ` James Bottomley
2008-07-17 21:35                     ` Frank Ch. Eigler [this message]
2008-07-17 22:05                       ` Masami Hiramatsu
2008-07-22 18:00                       ` Rik van Riel
2008-07-22 18:12                         ` Frank Ch. Eigler
2008-07-22 18:31                           ` Peter Zijlstra
     [not found]                           ` <1216751477.7257.115.camel__19834.5970632092$1216751567$gmane$org@twins>
2008-07-22 18:50                             ` Frank Ch. Eigler
2008-07-23 15:06                         ` systemtap & backward compatibility, was Re: [RFC] systemtap: begin the process of using proper kernel APIs Frank Ch. Eigler
2008-07-23 15:29                           ` Arjan van de Ven
2008-07-23 15:33                           ` Peter Zijlstra
2008-07-23 20:26                             ` Masami Hiramatsu
     [not found]                           ` <20080723082856.334f9c17__2909.60763018138$1216827051$gmane$org@infradead.org>
2008-07-23 16:43                             ` Frank Ch. Eigler
2008-07-23 16:54                               ` Adrian Bunk
2008-07-23 17:43                                 ` Frank Ch. Eigler
2008-07-23 18:41                                   ` Adrian Bunk
2008-07-23 22:14                               ` Masami Hiramatsu
2008-07-18  9:11 ` [RFC] systemtap: begin the process of using proper kernel APIs (part1: use kprobe symbol_name/offset instead of address) Andi Kleen
2008-07-18  9:23   ` Peter Zijlstra
2008-07-18 10:31     ` Andi Kleen
2008-07-18 10:44       ` Peter Zijlstra
2008-07-18 10:52         ` Andi Kleen
2008-07-18 13:04     ` Frank Ch. Eigler
2008-07-18 13:09       ` Andi Kleen
2008-07-18 13:10       ` Peter Zijlstra
2008-07-18 13:31         ` Frank Ch. Eigler
2008-07-18 13:36         ` Andi Kleen
2008-07-18 13:21       ` James Bottomley
2008-07-18 13:40         ` Frank Ch. Eigler
     [not found] <1216146802.3312.95.camel__45052.4692344063$1216146917$gmane$org@localhost.localdomain>
2008-07-15 19:42 ` Frank Ch. Eigler
2008-07-15 19:52   ` James Bottomley
2008-07-15 20:08     ` Frank Ch. Eigler
2008-07-15 20:24       ` James Bottomley
2008-07-15 22:19         ` Frank Ch. Eigler
2008-07-16  2:06           ` James Bottomley
2008-07-16 10:58             ` Frank Ch. Eigler
2008-07-16 14:56               ` James Bottomley

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=20080717213355.GJ18295@redhat.com \
    --to=fche@redhat.com \
    --cc=James.Bottomley@HansenPartnership.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mhiramat@redhat.com \
    --cc=systemtap@sourceware.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).