This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
[Bug kprobes/9965] New: Kretprobe triggers BUG triggered on -tip
- From: "ananth at in dot ibm dot com" <sourceware-bugzilla at sourceware dot org>
- To: systemtap at sources dot redhat dot com
- Date: 19 Mar 2009 09:33:47 -0000
- Subject: [Bug kprobes/9965] New: Kretprobe triggers BUG triggered on -tip
- Reply-to: sourceware-bugzilla at sourceware dot org
On a -tip kernel on x86_32, kretprobe_example (from samples) triggers the
following backtrace when its retprobing a class of functions that cause a
copy_from/to_user().
BUG: sleeping function called from invalid context at mm/memory.c:3196
in_atomic(): 0, irqs_disabled(): 1, pid: 2286, name: cat
1 lock held by cat/2286:
#0: (&p->lock){+.+.+.}, at: [<c04b4eb1>] seq_read+0x35/0x31d
irq event stamp: 1613
hardirqs last enabled at (1613): [<c06b5914>] _spin_unlock_irqrestore+0x3c/0x48
hardirqs last disabled at (1612): [<c06b5a7f>] _spin_lock_irqsave+0x1a/0x3f
softirqs last enabled at (1610): [<c04348c5>] __do_softirq+0x164/0x183
softirqs last disabled at (1603): [<c0404d2c>] do_softirq+0x68/0xc8
Pid: 2286, comm: cat Not tainted 2.6.29-rc8-tip-acde #1
Call Trace:
[<c0429017>] __might_sleep+0xde/0xe3
[<c048c6e1>] might_fault+0x1f/0x80
[<c0535b87>] copy_to_user+0x2f/0x106
[<c04b5120>] seq_read+0x2a4/0x31d
[<c04d4882>] proc_reg_read+0x6a/0x84
[<c04b4e7c>] ? seq_read+0x0/0x31d
[<c04d4882>] ? proc_reg_read+0x6a/0x84
[<c04d4818>] ? proc_reg_read+0x0/0x84
[<c04a1f73>] vfs_read+0x90/0xef
[<c04a208b>] sys_read+0x4e/0x75
[<c044d338>] ? trace_hardirqs_on_caller+0x11d/0x141
[<c0402fc4>] sysenter_do_call+0x12/0x38
[<c0402fc4>] ? sysenter_do_call+0x12/0x38
Steps to recreate:
a. Build and boot a -tip kernel on a 32bit box with kprobe samples built
b. modprobe kretprobe-example func="meminfo_proc_show"
c. cat /proc/meminfo
d. Your dmesg should have the above trace.
Problem doesn't happen with 2.6.29-rc8.
This is being triggered only from a select set of routines and not others. It
could very well be something outside of the kprobes infrastructure. Haven't seen
this happen on x86_64 too, yet.
--
Summary: Kretprobe triggers BUG triggered on -tip
Product: systemtap
Version: unspecified
Status: NEW
Severity: normal
Priority: P2
Component: kprobes
AssignedTo: systemtap at sources dot redhat dot com
ReportedBy: ananth at in dot ibm dot com
CC: bharata at linux dot vnet dot ibm dot com,mhiramat at
redhat dot com
http://sourceware.org/bugzilla/show_bug.cgi?id=9965
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.