Lines Matching defs:swap
101 static Elf32_Word read_elf_word(Elf32_Word word, bool swap)
103 return swap ? swab32(word) : word;
106 static Elf32_Half read_elf_half(Elf32_Half half, bool swap)
108 return swap ? swab16(half) : half;
111 static void write_elf_word(Elf32_Word val, Elf32_Word *dst, bool swap)
113 *dst = swap ? swab32(val) : val;
125 bool swap;
159 swap = inhdr->e_ident[EI_DATA] != HOST_ORDER;
161 if (read_elf_half(inhdr->e_type, swap) != ET_DYN)
164 if (read_elf_half(inhdr->e_machine, swap) != EM_ARM)
167 e_flags = read_elf_word(inhdr->e_flags, swap);
200 write_elf_word(e_flags, &outhdr->e_flags, swap);