Home
last modified time | relevance | path

Searched refs:data_scn (Results 1 – 21 of 21) sorted by relevance

/third_party/elfutils/libelf/
Dgelf_getdyn.c44 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_getdyn() local
48 if (data_scn == NULL) in gelf_getdyn()
51 if (unlikely (data_scn->d.d_type != ELF_T_DYN)) in gelf_getdyn()
57 elf = data_scn->s->elf; in gelf_getdyn()
72 if (INVALID_NDX (ndx, Elf32_Dyn, &data_scn->d)) in gelf_getdyn()
78 src = &((Elf32_Dyn *) data_scn->d.d_buf)[ndx]; in gelf_getdyn()
93 if (INVALID_NDX (ndx, GElf_Dyn, &data_scn->d)) in gelf_getdyn()
99 *dst = ((GElf_Dyn *) data_scn->d.d_buf)[ndx]; in gelf_getdyn()
Dgelf_getauxv.c43 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_getauxv() local
47 if (data_scn == NULL) in gelf_getauxv()
50 if (unlikely (data_scn->d.d_type != ELF_T_AUXV)) in gelf_getauxv()
56 elf = data_scn->s->elf; in gelf_getauxv()
71 if (unlikely ((ndx + 1) * sizeof (Elf32_auxv_t) > data_scn->d.d_size)) in gelf_getauxv()
77 src = &((Elf32_auxv_t *) data_scn->d.d_buf)[ndx]; in gelf_getauxv()
91 if (unlikely ((ndx + 1) * sizeof (GElf_auxv_t) > data_scn->d.d_size)) in gelf_getauxv()
97 memcpy (dst, data_scn->d.d_buf + ndx * sizeof (GElf_auxv_t), in gelf_getauxv()
Dgelf_getrel.c43 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_getrel() local
47 if (data_scn == NULL) in gelf_getrel()
50 if (unlikely (data_scn->d.d_type != ELF_T_REL)) in gelf_getrel()
59 scn = data_scn->s; in gelf_getrel()
66 if (INVALID_NDX (ndx, Elf32_Rel, &data_scn->d)) in gelf_getrel()
73 Elf32_Rel *src = &((Elf32_Rel *) data_scn->d.d_buf)[ndx]; in gelf_getrel()
86 if (INVALID_NDX (ndx, Elf64_Rel, &data_scn->d)) in gelf_getrel()
92 result = memcpy (dst, &((Elf64_Rel *) data_scn->d.d_buf)[ndx], in gelf_getrel()
Dgelf_getrela.c43 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_getrela() local
47 if (data_scn == NULL) in gelf_getrela()
50 if (unlikely (data_scn->d.d_type != ELF_T_RELA)) in gelf_getrela()
59 scn = data_scn->s; in gelf_getrela()
66 if (INVALID_NDX (ndx, Elf32_Rela, &data_scn->d)) in gelf_getrela()
73 Elf32_Rela *src = &((Elf32_Rela *) data_scn->d.d_buf)[ndx]; in gelf_getrela()
87 if (INVALID_NDX (ndx, Elf64_Rela, &data_scn->d)) in gelf_getrela()
93 result = memcpy (dst, &((Elf64_Rela *) data_scn->d.d_buf)[ndx], in gelf_getrela()
Dgelf_update_move.c44 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_update_move() local
54 if (INVALID_NDX (ndx, GElf_Move, &data_scn->d)) in gelf_update_move()
60 if (unlikely (data_scn->d.d_type != ELF_T_MOVE)) in gelf_update_move()
67 rwlock_wrlock (data_scn->s->elf->lock); in gelf_update_move()
69 ((GElf_Move *) data_scn->d.d_buf)[ndx] = *src; in gelf_update_move()
72 data_scn->s->flags |= ELF_F_DIRTY; in gelf_update_move()
74 rwlock_unlock (data_scn->s->elf->lock); in gelf_update_move()
Dgelf_update_versym.c44 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_update_versym() local
54 if (INVALID_NDX (ndx, GElf_Versym, &data_scn->d)) in gelf_update_versym()
60 if (unlikely (data_scn->d.d_type != ELF_T_HALF)) in gelf_update_versym()
67 rwlock_wrlock (data_scn->s->elf->lock); in gelf_update_versym()
69 ((GElf_Versym *) data_scn->d.d_buf)[ndx] = *src; in gelf_update_versym()
72 data_scn->s->flags |= ELF_F_DIRTY; in gelf_update_versym()
74 rwlock_unlock (data_scn->s->elf->lock); in gelf_update_versym()
Dgelf_update_verdef.c44 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_update_verdef() local
55 || unlikely ((offset + sizeof (GElf_Verdef)) > data_scn->d.d_size)) in gelf_update_verdef()
61 if (unlikely (data_scn->d.d_type != ELF_T_VDEF)) in gelf_update_verdef()
68 rwlock_wrlock (data_scn->s->elf->lock); in gelf_update_verdef()
70 memcpy ((char *) data_scn->d.d_buf + offset, src, sizeof (GElf_Verdef)); in gelf_update_verdef()
73 data_scn->s->flags |= ELF_F_DIRTY; in gelf_update_verdef()
75 rwlock_unlock (data_scn->s->elf->lock); in gelf_update_verdef()
Dgelf_update_vernaux.c44 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_update_vernaux() local
55 || unlikely ((offset + sizeof (GElf_Vernaux)) > data_scn->d.d_size)) in gelf_update_vernaux()
61 if (unlikely (data_scn->d.d_type != ELF_T_VNEED)) in gelf_update_vernaux()
68 rwlock_wrlock (data_scn->s->elf->lock); in gelf_update_vernaux()
70 memcpy ((char *) data_scn->d.d_buf + offset, src, sizeof (GElf_Vernaux)); in gelf_update_vernaux()
73 data_scn->s->flags |= ELF_F_DIRTY; in gelf_update_vernaux()
75 rwlock_unlock (data_scn->s->elf->lock); in gelf_update_vernaux()
Dgelf_update_verdaux.c44 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_update_verdaux() local
55 || unlikely ((offset + sizeof (GElf_Verdaux)) > data_scn->d.d_size)) in gelf_update_verdaux()
61 if (unlikely (data_scn->d.d_type != ELF_T_VDEF)) in gelf_update_verdaux()
68 rwlock_wrlock (data_scn->s->elf->lock); in gelf_update_verdaux()
70 memcpy ((char *) data_scn->d.d_buf + offset, src, sizeof (GElf_Verdaux)); in gelf_update_verdaux()
73 data_scn->s->flags |= ELF_F_DIRTY; in gelf_update_verdaux()
75 rwlock_unlock (data_scn->s->elf->lock); in gelf_update_verdaux()
Dgelf_update_verneed.c44 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_update_verneed() local
55 || unlikely ((offset + sizeof (GElf_Verneed)) > data_scn->d.d_size)) in gelf_update_verneed()
61 if (unlikely (data_scn->d.d_type != ELF_T_VNEED)) in gelf_update_verneed()
68 rwlock_wrlock (data_scn->s->elf->lock); in gelf_update_verneed()
70 memcpy ((char *) data_scn->d.d_buf + offset, src, sizeof (GElf_Verneed)); in gelf_update_verneed()
73 data_scn->s->flags |= ELF_F_DIRTY; in gelf_update_verneed()
75 rwlock_unlock (data_scn->s->elf->lock); in gelf_update_verneed()
Dgelf_update_dyn.c43 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_update_dyn() local
50 if (unlikely (data_scn->d.d_type != ELF_T_DYN)) in gelf_update_dyn()
57 scn = data_scn->s; in gelf_update_dyn()
75 if (INVALID_NDX (ndx, Elf32_Dyn, &data_scn->d)) in gelf_update_dyn()
81 dyn = &((Elf32_Dyn *) data_scn->d.d_buf)[ndx]; in gelf_update_dyn()
89 if (INVALID_NDX (ndx, Elf64_Dyn, &data_scn->d)) in gelf_update_dyn()
95 ((Elf64_Dyn *) data_scn->d.d_buf)[ndx] = *src; in gelf_update_dyn()
Dgelf_update_sym.c44 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_update_sym() local
51 if (unlikely (data_scn->d.d_type != ELF_T_SYM)) in gelf_update_sym()
58 scn = data_scn->s; in gelf_update_sym()
75 if (INVALID_NDX (ndx, Elf32_Sym, &data_scn->d)) in gelf_update_sym()
81 sym = &((Elf32_Sym *) data_scn->d.d_buf)[ndx]; in gelf_update_sym()
98 if (INVALID_NDX (ndx, Elf64_Sym, &data_scn->d)) in gelf_update_sym()
104 ((Elf64_Sym *) data_scn->d.d_buf)[ndx] = *src; in gelf_update_sym()
Dgelf_update_auxv.c42 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_update_auxv() local
55 if (unlikely (data_scn->d.d_type != ELF_T_AUXV)) in gelf_update_auxv()
62 scn = data_scn->s; in gelf_update_auxv()
79 if (unlikely ((ndx + 1) * sizeof (Elf32_auxv_t) > data_scn->d.d_size)) in gelf_update_auxv()
85 auxv = &((Elf32_auxv_t *) data_scn->d.d_buf)[ndx]; in gelf_update_auxv()
93 if (unlikely ((ndx + 1) * sizeof (Elf64_auxv_t) > data_scn->d.d_size)) in gelf_update_auxv()
99 ((Elf64_auxv_t *) data_scn->d.d_buf)[ndx] = *src; in gelf_update_auxv()
Dgelf_update_rel.c43 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) dst; in gelf_update_rel() local
50 if (unlikely (data_scn->d.d_type != ELF_T_REL)) in gelf_update_rel()
57 scn = data_scn->s; in gelf_update_rel()
75 if (INVALID_NDX (ndx, Elf32_Rel, &data_scn->d)) in gelf_update_rel()
81 rel = &((Elf32_Rel *) data_scn->d.d_buf)[ndx]; in gelf_update_rel()
90 if (INVALID_NDX (ndx, Elf64_Rel, &data_scn->d)) in gelf_update_rel()
96 ((Elf64_Rel *) data_scn->d.d_buf)[ndx] = *src; in gelf_update_rel()
Delf_flagdata.c43 Elf_Data_Scn *data_scn; in elf_flagdata() local
49 data_scn = (Elf_Data_Scn *) data; in elf_flagdata()
51 if (data_scn == NULL || unlikely (data_scn->s->elf->kind != ELF_K_ELF)) in elf_flagdata()
58 result = (data_scn->s->flags |= (flags & ELF_F_DIRTY)); in elf_flagdata()
60 result = (data_scn->s->flags &= ~(flags & ELF_F_DIRTY)); in elf_flagdata()
Dgelf_update_rela.c43 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) dst; in gelf_update_rela() local
50 if (unlikely (data_scn->d.d_type != ELF_T_RELA)) in gelf_update_rela()
57 scn = data_scn->s; in gelf_update_rela()
77 if (INVALID_NDX (ndx, Elf32_Rela, &data_scn->d)) in gelf_update_rela()
83 rel = &((Elf32_Rela *) data_scn->d.d_buf)[ndx]; in gelf_update_rela()
93 if (INVALID_NDX (ndx, Elf64_Rela, &data_scn->d)) in gelf_update_rela()
99 ((Elf64_Rela *) data_scn->d.d_buf)[ndx] = *src; in gelf_update_rela()
Dgelf_update_lib.c47 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_update_lib() local
48 if (unlikely (data_scn->d.d_type != ELF_T_LIB)) in gelf_update_lib()
55 Elf_Scn *scn = data_scn->s; in gelf_update_lib()
60 if (INVALID_NDX (ndx, Elf64_Lib, &data_scn->d)) in gelf_update_lib()
64 ((Elf64_Lib *) data_scn->d.d_buf)[ndx] = *src; in gelf_update_lib()
Dgelf_update_syminfo.c44 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_update_syminfo() local
51 if (unlikely (data_scn->d.d_type != ELF_T_SYMINFO)) in gelf_update_syminfo()
62 scn = data_scn->s; in gelf_update_syminfo()
66 if (INVALID_NDX (ndx, GElf_Syminfo, &data_scn->d)) in gelf_update_syminfo()
72 ((GElf_Syminfo *) data_scn->d.d_buf)[ndx] = *src; in gelf_update_syminfo()
Dgelf_getsym.c44 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_getsym() local
56 rwlock_rdlock (data_scn->s->elf->lock); in gelf_getsym()
61 if (data_scn->s->elf->class == ELFCLASS32) in gelf_getsym()
110 rwlock_unlock (data_scn->s->elf->lock); in gelf_getsym()
Dgelf_getlib.c53 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_getlib() local
55 rwlock_rdlock (data_scn->s->elf->lock); in gelf_getlib()
74 rwlock_unlock (data_scn->s->elf->lock); in gelf_getlib()
Dgelf_getversym.c44 Elf_Data_Scn *data_scn = (Elf_Data_Scn *) data; in gelf_getversym() local
60 scn = data_scn->s; in gelf_getversym()