mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: fche@redhat.com (Frank Ch. Eigler)
To: samuelkorpi@myway.com
Cc: linux-kernel@vger.kernel.org
Subject: Re: Calling kernel functions from kprobes/jprobes
Date: 27 Jun 2006 11:12:34 -0400	[thread overview]
Message-ID: <y0md5cur5st.fsf@ton.toronto.redhat.com> (raw)
In-Reply-To: <20060627080021.453306776E@mprdmxin.myway.com>

"Samuel" <samuelkorpi@myway.com> writes:

> [...]  I am using kprobes/jprobes to try and understand how IP
> options are handled in the kernel. From one of these probes I want
> to call another function inside the kernel, namely
> ip_options_get_from_user. [...]

Other than symbol exporting issues, you may encounter another problem
that we have encountered in systemtap (which is also a kprobes
client).  That is that the context where the kprobe was placed may be
such that calling most ordinary kernel routines is unsafe.  In
particular, ip_options_get_from_user may sleep, which may or may not
be legal from the context of the kprobe.  (In systemtap probes, we
don't permit anything to block/sleep/schedule, so instead suffer
absent-page errors.)

- FChE

  parent reply	other threads:[~2006-06-27 15:12 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-27  8:00 Samuel
2006-06-27  9:53 ` Alan Cox
2006-06-27 15:12 ` Frank Ch. Eigler [this message]
2006-06-27 11:20 Samuel Korpi

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=y0md5cur5st.fsf@ton.toronto.redhat.com \
    --to=fche@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=samuelkorpi@myway.com \
    /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

all inboxes | Powered by JetHome®