Lines Matching refs:elf
63 from elftools.elf.elffile import ELFFile
64 from elftools.elf.sections import SymbolTableSection
486 def unpack_pointer(elf, data, offset): argument
487 endian_code = "<" if elf.little_endian else ">"
488 if elf.elfclass == 32:
499 def addr_deref(elf, addr): argument
500 for section in elf.iter_sections():
507 return unpack_pointer(elf, data, offset)
512 def device_get_api_addr(elf, addr): argument
514 offset = 8 if elf.elfclass == 32 else 16
515 return addr_deref(elf, addr + offset)
518 def find_kobjects(elf, syms): argument
524 if not elf.has_dwarf_info():
540 di = elf.get_dwarf_info()
692 apiaddr = device_get_api_addr(elf, addr)
717 def get_symbols(elf): argument
718 for section in elf.iter_sections():
1034 elf = ELFFile(open(args.kernel, "rb"))
1035 syms = get_symbols(elf)
1037 objs = find_kobjects(elf, syms)
1048 write_gperf_table(fp, syms, objs, elf.little_endian,