diff options
author | Dave Brolley <brolley@redhat.com> | 2010-01-15 10:57:08 -0500 |
---|---|---|
committer | Dave Brolley <brolley@redhat.com> | 2010-01-15 10:57:08 -0500 |
commit | ceeefadd6874e3d315669a87ec0d05a0ce1f7094 (patch) | |
tree | fad469e3f31212afee4d1fb6aa6833b48e1724b7 /runtime/uprobes-common.c | |
parent | 3f78f0208e1bfe8061d1898418882b5e2756f8a2 (diff) | |
parent | 86f99ad8206574dc6400d48563db58341cb50f52 (diff) | |
download | systemtap-steved-ceeefadd6874e3d315669a87ec0d05a0ce1f7094.tar.gz systemtap-steved-ceeefadd6874e3d315669a87ec0d05a0ce1f7094.tar.xz systemtap-steved-ceeefadd6874e3d315669a87ec0d05a0ce1f7094.zip |
Merge branch 'master' of ssh://sources.redhat.com/git/systemtap
Conflicts:
stap-client
Diffstat (limited to 'runtime/uprobes-common.c')
-rw-r--r-- | runtime/uprobes-common.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/runtime/uprobes-common.c b/runtime/uprobes-common.c index b0273ba4..58e3a05f 100644 --- a/runtime/uprobes-common.c +++ b/runtime/uprobes-common.c @@ -286,4 +286,19 @@ static int stap_uprobe_munmap_found (struct stap_task_finder_target *tgt, struct return stap_uprobe_change_minus (tsk, addr, length, stf); } +/* The task_finder_callback we use for ET_DYN targets. + This just forces an unmap of everything as the process exits. + (PR11151) */ +static int stap_uprobe_process_munmap (struct stap_task_finder_target *tgt, struct task_struct *tsk, int register_p, int process_p) { + const struct stap_uprobe_tf *stf = container_of(tgt, struct stap_uprobe_tf, finder); + if (! process_p) return 0; /* ignore threads */ + #ifdef DEBUG_TASK_FINDER_VMA + _stp_dbug (__FUNCTION__,__LINE__, "%cproc pid %d stf %p %p path %s\n", register_p?'+':'-', tsk->tgid, tgt, stf, stf->pathname); + #endif + /* Covering 0->TASK_SIZE means "unmap everything" */ + if (!register_p) + return stap_uprobe_change_minus (tsk, 0, TASK_SIZE, stf); + return 0; +} + #endif /* _UPROBE_COMMON_C_ */ |