Lines Matching defs:seg
208 KXLDSeg * seg = NULL;
291 seg = kxld_array_get_item(&object->segs, i);
292 kxld_seg_set_vm_protections(seg,
296 seg = kxld_object_get_seg_by_name(object, SEG_LINKEDIT);
297 if (seg) {
298 (void) kxld_seg_populate_linkedit(seg, object->symtab,
508 KXLDSeg *seg = NULL;
586 seg = NULL;
598 seg = kxld_array_get_item(&object->segs, segi++);
600 rval = kxld_seg_init_from_macho_32(seg, seg_hdr);
616 seg = kxld_array_get_item(&object->segs, segi++);
618 rval = kxld_seg_init_from_macho_64(seg, seg_hdr);
678 if (seg) {
681 for (j = 0; j < seg->sects.nitems; ++j, ++secti) {
691 rval = kxld_seg_add_section(seg, sect);
694 rval = kxld_seg_finish_init(seg);
717 KXLDSeg *seg = NULL;
763 seg = kxld_array_get_item(&object->segs, i);
765 for (j = 0; j < seg->sects.nitems; ++j, ++k) {
766 sect = *(KXLDSect **) kxld_array_get_item(&seg->sects, j);
1052 KXLDSeg *seg = NULL;
1064 seg = kxld_array_get_item(&object->segs, i);
1065 header_size += kxld_seg_get_macho_header_size(seg, object_is_32_bit);
1096 KXLDSeg *seg = NULL;
1104 seg = kxld_array_get_item(&object->segs, i);
1105 data_size += (u_long) kxld_seg_get_vmsize(seg);
1120 seg = kxld_object_get_seg_by_name(object, SEG_LINKEDIT);
1121 seg_vmsize = (u_long) kxld_seg_get_vmsize(seg);
1164 KXLDSeg *seg = NULL;
1168 seg = kxld_array_get_item(&object->segs, i);
1170 if (streq_safe(segname, seg->segname, sizeof(seg->segname))) break;
1172 seg = NULL;
1175 return seg;
1520 KXLDSeg *seg = NULL;
1533 seg = kxld_array_get_item(&object->segs, i);
1534 kxld_seg_clear(seg);
1576 KXLDSeg *seg = NULL;
1589 seg = kxld_array_get_slot(&object->segs, i);
1590 kxld_seg_deinit(seg);
1727 KXLDSeg *seg = NULL;
1773 seg = kxld_array_get_item(&object->segs, i);
1775 rval = kxld_seg_export_macho_to_vm(seg, linked_object, &header_offset,
1780 seg = kxld_object_get_seg_by_name(object, SEG_LINKEDIT);
1781 data_offset = (u_long) (seg->link_addr - object->link_addr);
1936 KXLDSeg *seg = NULL;
1945 seg = kxld_array_get_item(&object->segs, i);
1946 kxld_seg_relocate(seg, link_address);
2176 KXLDSeg *seg = NULL;
2182 seg = kxld_array_get_item(&object->segs, i);
2183 start = seg->base_addr;
2184 end = seg->base_addr + seg->vmsize;
2186 if (start <= base_addr && base_addr < end) return seg;
2199 KXLDSeg *seg = NULL;
2206 seg = get_seg_by_base_addr(object, reloc->address);
2207 require_action(seg, finish, rval=KERN_FAILURE);
2210 seg, object->link_addr);
2218 seg = get_seg_by_base_addr(object, reloc->address);
2219 require_action(seg, finish, rval=KERN_FAILURE);
2222 seg, object->link_addr);