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