diff options
| author | Nathan Whitehorn <nwhitehorn@FreeBSD.org> | 2011-12-17 15:31:00 +0000 |
|---|---|---|
| committer | Nathan Whitehorn <nwhitehorn@FreeBSD.org> | 2011-12-17 15:31:00 +0000 |
| commit | 17bbcc52d1c976685721d7c831c8be0ecc644e47 (patch) | |
| tree | 8202f56df90a9d8db850649efbda57ba7f29af9f /libexec/rtld-elf/powerpc | |
| parent | f6ce353e58c1a85ab2663833fc1a1e57c5aed0da (diff) | |
Notes
Diffstat (limited to 'libexec/rtld-elf/powerpc')
| -rw-r--r-- | libexec/rtld-elf/powerpc/reloc.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/libexec/rtld-elf/powerpc/reloc.c b/libexec/rtld-elf/powerpc/reloc.c index d0128f415e84..c8967b699556 100644 --- a/libexec/rtld-elf/powerpc/reloc.c +++ b/libexec/rtld-elf/powerpc/reloc.c @@ -366,7 +366,7 @@ reloc_plt_object(Obj_Entry *obj, const Elf_Rela *rela) /* - * The icache will be sync'd in init_pltgot, which is called + * The icache will be sync'd in reloc_plt, which is called * after all the slots have been updated */ @@ -382,6 +382,7 @@ reloc_plt(Obj_Entry *obj) { const Elf_Rela *relalim; const Elf_Rela *rela; + int N = obj->pltrelasize / sizeof(Elf_Rela); if (obj->pltrelasize != 0) { @@ -396,6 +397,13 @@ reloc_plt(Obj_Entry *obj) } } + /* + * Sync the icache for the byte range represented by the + * trampoline routines and call slots. + */ + if (obj->pltgot != NULL) + __syncicache(obj->pltgot, JMPTAB_BASE(N)*4); + return (0); } @@ -595,10 +603,9 @@ init_pltgot(Obj_Entry *obj) pltresolve[4] |= _ppc_la(obj); /* - * Sync the icache for the byte range represented by the - * trampoline routines and call slots. + * The icache will be sync'd in reloc_plt, which is called + * after all the slots have been updated */ - __syncicache(obj->pltgot, JMPTAB_BASE(N)*4); } void |
