Skip to content

Commit

Permalink
rtld, i386: Fix cfi directive in audit trampoline code
Browse files Browse the repository at this point in the history
_dl_runtime_profile function has wrong cfi directive when
rewinding stack back for the pltexit path.

Only 8 bytes - 2 'pop edx' instructions from the pltentry-only
code should be rewinded back.

With attached patch, I'm able to rewind stack correctly
throught the rtld code from audit library callback.
  • Loading branch information
Jiri Olsa authored and Ulrich Drepper committed Aug 29, 2011
1 parent ad69cc2 commit fbeb5f4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
2011-08-29 Jiri Olsa <jolsa@redhat.com>

* sysdeps/i386/dl-trampoline.S (_dl_runtime_profile): Fix cfi
directive.

2011-08-24 David S. Miller <davem@davemloft.net>

* sysdeps/sparc/sparc64/strcmp.S: Rewrite.
Expand Down
4 changes: 2 additions & 2 deletions sysdeps/i386/dl-trampoline.S
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* PLT trampolines. i386 version.
Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc.
Copyright (C) 2004, 2005, 2007, 2011 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
Expand Down Expand Up @@ -99,7 +99,7 @@ _dl_runtime_profile:
+4 %edx
%esp free
*/
cfi_adjust_cfa_offset (12)
cfi_adjust_cfa_offset (8)
1: movl %ebx, (%esp)
cfi_rel_offset (ebx, 0)
movl %edx, %ebx # This is the frame buffer size
Expand Down

0 comments on commit fbeb5f4

Please sign in to comment.