summaryrefslogtreecommitdiff
path: root/usr/src/cmd/sgs/rtld
diff options
context:
space:
mode:
Diffstat (limited to 'usr/src/cmd/sgs/rtld')
-rw-r--r--usr/src/cmd/sgs/rtld/common/_elf.h2
-rw-r--r--usr/src/cmd/sgs/rtld/common/elf.c28
-rw-r--r--usr/src/cmd/sgs/rtld/common/move.c29
-rw-r--r--usr/src/cmd/sgs/rtld/mdbmod/common/rtld.c3
-rw-r--r--usr/src/cmd/sgs/rtld/mdbmod/common/rtld.msg3
5 files changed, 3 insertions, 62 deletions
diff --git a/usr/src/cmd/sgs/rtld/common/_elf.h b/usr/src/cmd/sgs/rtld/common/_elf.h
index 58e33f47c1..062bb89e37 100644
--- a/usr/src/cmd/sgs/rtld/common/_elf.h
+++ b/usr/src/cmd/sgs/rtld/common/_elf.h
@@ -105,7 +105,6 @@ typedef struct _rt_elf_private {
ulong_t e_moveent; /* size of base movetab entry */
ulong_t e_tlsstatoff; /* TLS offset into static block */
void *e_movetab; /* movetable address */
- Phdr *e_sunwbss; /* program header for SUNWBSS */
Phdr *e_pttls; /* PT_TLS */
Phdr *e_ptunwind; /* PT_SUNW_UNWIND (amd64 specific) */
ulong_t e_syment; /* size of symtab entry */
@@ -149,7 +148,6 @@ typedef struct _rt_elf_private {
#define VERDEF(X) (((Rt_elfp *)(X)->rt_priv)->e_verdef)
#define VERDEFNUM(X) (((Rt_elfp *)(X)->rt_priv)->e_verdefnum)
#define VERSYM(X) (((Rt_elfp *)(X)->rt_priv)->e_versym)
-#define SUNWBSS(X) (((Rt_elfp *)(X)->rt_priv)->e_sunwbss)
#define SYMINENT(X) (((Rt_elfp *)(X)->rt_priv)->e_syminent)
#define PLTPAD(X) (((Rt_elfp *)(X)->rt_priv)->e_pltpad)
#define PLTPADEND(X) (((Rt_elfp *)(X)->rt_priv)->e_pltpadend)
diff --git a/usr/src/cmd/sgs/rtld/common/elf.c b/usr/src/cmd/sgs/rtld/common/elf.c
index 717ad4dd2f..ccd118b056 100644
--- a/usr/src/cmd/sgs/rtld/common/elf.c
+++ b/usr/src/cmd/sgs/rtld/common/elf.c
@@ -1123,8 +1123,7 @@ elf_map_it(
* Skip non-loadable segments or segments that don't occupy
* any memory.
*/
- if (((phdr->p_type != PT_LOAD) &&
- (phdr->p_type != PT_SUNWBSS)) || (phdr->p_memsz == 0))
+ if ((phdr->p_type != PT_LOAD) || (phdr->p_memsz == 0))
continue;
/*
@@ -1154,20 +1153,7 @@ elf_map_it(
/*
* Determine the type of mapping required.
*/
- if (phdr->p_type == PT_SUNWBSS) {
- /*
- * Potentially, we can defer the loading of any SUNWBSS
- * segment, depending on whether the symbols it provides
- * have been bound to. In this manner, large segments
- * that are interposed upon between shared libraries
- * may not require mapping. Note, that the mapping
- * information is recorded in our mapping descriptor at
- * this time.
- */
- mlen = phdr->p_memsz;
- flen = 0;
-
- } else if ((phdr->p_filesz == 0) && (phdr->p_flags == 0)) {
+ if ((phdr->p_filesz == 0) && (phdr->p_flags == 0)) {
/*
* If this segment has no backing file and no flags
* specified, then it defines a reservation. At this
@@ -2678,7 +2664,6 @@ elf_map_so(Lm_list *lml, Aliste lmco, const char *pname, const char *oname,
Phdr *lph; /* last loadable Phdr */
Phdr *lfph = 0; /* last loadable (filesz != 0) Phdr */
Phdr *lmph = 0; /* last loadable (memsz != 0) Phdr */
- Phdr *swph = 0; /* program header for SUNWBSS */
Phdr *tlph = 0; /* program header for PT_TLS */
Phdr *unwindph = 0; /* program header for PT_SUNW_UNWIND */
Cap *cap = 0; /* program header for SUNWCAP */
@@ -2755,8 +2740,7 @@ elf_map_so(Lm_list *lml, Aliste lmco, const char *pname, const char *oname,
*/
for (i = 0, pptr = phdr; i < (int)ehdr->e_phnum; i++,
pptr = (Phdr *)((Off)pptr + ehdr->e_phentsize)) {
- if ((pptr->p_type == PT_LOAD) ||
- (pptr->p_type == PT_SUNWBSS)) {
+ if (pptr->p_type == PT_LOAD) {
if (fph == 0) {
fph = pptr;
@@ -2773,8 +2757,6 @@ elf_map_so(Lm_list *lml, Aliste lmco, const char *pname, const char *oname,
lmph = pptr;
if (pptr->p_filesz)
lfph = pptr;
- if (pptr->p_type == PT_SUNWBSS)
- swph = pptr;
if (pptr->p_align > align)
align = pptr->p_align;
@@ -2950,10 +2932,6 @@ elf_map_so(Lm_list *lml, Aliste lmco, const char *pname, const char *oname,
/*
* If this shared object contains any special segments, record them.
*/
- if (swph) {
- FLAGS(lmp) |= FLG_RT_SUNWBSS;
- SUNWBSS(lmp) = phdr + (swph - phdr0);
- }
if (tlph && (tls_assign(lml, lmp, (phdr + (tlph - phdr0))) == 0)) {
remove_so(lml, lmp);
return (0);
diff --git a/usr/src/cmd/sgs/rtld/common/move.c b/usr/src/cmd/sgs/rtld/common/move.c
index 766b69c5ac..eb085b349c 100644
--- a/usr/src/cmd/sgs/rtld/common/move.c
+++ b/usr/src/cmd/sgs/rtld/common/move.c
@@ -24,8 +24,6 @@
* Use is subject to license terms.
*/
-#pragma ident "%Z%%M% %I% %E% SMI"
-
/*
* Object file dependent support for ELF objects.
*/
@@ -56,7 +54,6 @@ move_data(Rt_map *lmp)
{
Lm_list *lml = LIST(lmp);
Move *mv = MOVETAB(lmp);
- Phdr *pptr = SUNWBSS(lmp);
ulong_t num, mvnum = MOVESZ(lmp) / MOVEENT(lmp);
int moves;
@@ -74,32 +71,6 @@ move_data(Rt_map *lmp)
Half rep, repno, stride;
Sym *sym;
- /*
- * If the target address needs to be mapped in,
- * map it first.
- * (You have to protect the code, thread safe)
- */
- if (FLAGS(lmp) & FLG_RT_SUNWBSS) {
- long zlen;
- Off foff;
- caddr_t zaddr, eaddr;
-
- foff = (Off) (pptr->p_vaddr + ADDR(lmp));
- zaddr = (caddr_t)M_PROUND(foff);
- eaddr = pptr->p_vaddr + ADDR(lmp) +
- (caddr_t)pptr->p_memsz;
- zero((caddr_t)foff, (long)(zaddr - foff));
- zlen = eaddr - zaddr;
- if (zlen > 0) {
- if (dz_map(lml, zaddr, zlen,
- (PROT_READ | PROT_WRITE),
- (MAP_FIXED | MAP_PRIVATE)) == MAP_FAILED)
- return (0);
- }
-
- FLAGS(lmp) &= ~FLG_RT_SUNWBSS;
- }
-
if ((sym = (Sym *)SYMTAB(lmp) + ELF_M_SYM(mv->m_info)) == 0)
continue;
diff --git a/usr/src/cmd/sgs/rtld/mdbmod/common/rtld.c b/usr/src/cmd/sgs/rtld/mdbmod/common/rtld.c
index 35091d452c..8252887337 100644
--- a/usr/src/cmd/sgs/rtld/mdbmod/common/rtld.c
+++ b/usr/src/cmd/sgs/rtld/mdbmod/common/rtld.c
@@ -24,8 +24,6 @@
* Use is subject to license terms.
*/
-#pragma ident "%Z%%M% %I% %E% SMI"
-
#include <msg.h>
#include <_rtld.h>
#include <conv.h>
@@ -70,7 +68,6 @@ static const mdb_bitmask_t rtflags_bits[] = {
{ MSG_ORIG(MSG_FLG_NOOPEN), FLG_RT_NOOPEN, FLG_RT_NOOPEN},
{ MSG_ORIG(MSG_FLG_FINICLCT), FLG_RT_FINICLCT, FLG_RT_FINICLCT},
{ MSG_ORIG(MSG_FLG_INITCALL), FLG_RT_INITCALL, FLG_RT_INITCALL},
- { MSG_ORIG(MSG_FLG_SUNWBSS), FLG_RT_SUNWBSS, FLG_RT_SUNWBSS},
{ MSG_ORIG(MSG_FLG_OBJINTPO), FLG_RT_OBJINTPO, FLG_RT_OBJINTPO},
{ MSG_ORIG(MSG_FLG_SYMINTPO), FLG_RT_SYMINTPO, FLG_RT_SYMINTPO},
{ MSG_ORIG(MSG_FLG_MOVE), FLG_RT_MOVE, FLG_RT_MOVE},
diff --git a/usr/src/cmd/sgs/rtld/mdbmod/common/rtld.msg b/usr/src/cmd/sgs/rtld/mdbmod/common/rtld.msg
index 1fe46e0a0f..7ca2cb36a8 100644
--- a/usr/src/cmd/sgs/rtld/mdbmod/common/rtld.msg
+++ b/usr/src/cmd/sgs/rtld/mdbmod/common/rtld.msg
@@ -23,8 +23,6 @@
# Copyright 2008 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
-# pragma ident "%Z%%M% %I% %E% SMI"
-#
@ _START_
@@ -86,7 +84,6 @@
@ MSG_FLG_NOOPEN "NO-OPEN"
@ MSG_FLG_FINICLCT "FINI-COLLECTED"
@ MSG_FLG_INITCALL "INIT-CALLED"
-@ MSG_FLG_SUNWBSS "SUNWBSS"
@ MSG_FLG_OBJINTPO "OBJECT-INTERPOSE"
@ MSG_FLG_SYMINTPO "SYMBOL-INTERPOSE"
@ MSG_FLG_MOVE "MOVE"