Home | History | Annotate | Download | only in libdwfl
      1 2008-12-16  Roland McGrath  <roland (a] redhat.com>
      2 
      3 	* dwfl_module_build_id.c (dwfl_module_build_id): Define with alias and
      4 	symver magic to bind to ELFUTILS_0.138.
      5 	(_BUG_COMPAT_dwfl_module_build_id): New function, bug compatible
      6 	wrapper for ELFUTILS_0.130 version set.
      7 
      8 2008-12-18  Roland McGrath  <roland (a] redhat.com>
      9 
     10 	* derelocate.c (dwfl_module_relocate_address): Fix last fix: ET_DYN
     11 	addresses are taken as relative to MOD->low_addr.
     12 
     13 2008-12-15  Roland McGrath  <roland (a] redhat.com>
     14 
     15 	* derelocate.c (dwfl_module_relocate_address): Apply main.bias, not
     16 	debug.bias.
     17 
     18 2008-12-11  Roland McGrath  <roland (a] redhat.com>
     19 
     20 	* offline.c (process_archive): Don't call elf_end and close if
     21 	returning NULL.  Check first elf_begin call and set error code
     22 	specially for empty archive.
     23 	Fixes RHBZ#465878.
     24 
     25 2008-12-02  Roland McGrath  <roland (a] redhat.com>
     26 
     27 	* dwfl_getmodules.c (dwfl_getmodules): Typo fix in last change.
     28 
     29 2008-11-26  Roland McGrath  <roland (a] redhat.com>
     30 
     31 	* dwfl_getmodules.c (dwfl_getmodules): Encode iteration style in
     32 	return value, and interpret encoded OFFSET argument.
     33 
     34 2008-10-07  Roland McGrath  <roland (a] redhat.com>
     35 
     36 	* dwfl_module_build_id.c (check_notes): Fix typo in vaddr calculation.
     37 
     38 2008-09-29  Roland McGrath  <roland (a] redhat.com>
     39 
     40 	* segment.c (insert): Must realloc DWFL->lookup_module here too.
     41 	(dwfl_report_segment): Clear DWFL->lookup_module before insert calls.
     42 
     43 2008-08-28  Roland McGrath  <roland (a] redhat.com>
     44 
     45 	* segment.c (reify_segments): Fix last change.
     46 
     47 2008-08-27  Roland McGrath  <roland (a] redhat.com>
     48 
     49 	* linux-proc-maps.c (read_proc_memory): Return 0 for EINVAL or EPERM
     50 	failure from pread64.
     51 
     52 2008-08-26  Roland McGrath  <roland (a] redhat.com>
     53 
     54 	* segment.c (reify_segments): Insert a trailing segment for a module
     55 	end that is above the highest current segment.
     56 
     57 2008-08-25  Roland McGrath  <roland (a] redhat.com>
     58 
     59 	* dwfl_module_getdwarf.c (open_elf): Extract elf_errno () for
     60 	coded return value, not plain DWFL_E_LIBELF.  Return DWFL_E_BADELF
     61 	if FILE->elf is not ELF_K_ELF.
     62 
     63 	* dwfl_segment_report_module.c: Add a cast.
     64 
     65 2008-08-21  Denys Vlasenko  <dvlasenk (a] redhat.com>
     66 
     67 	* dwfl_module_addrsym.c (dwfl_module_addrsym): Improve logic
     68 	which decides which symbol is "closest" to a given address.
     69 
     70 2008-08-15  Roland McGrath  <roland (a] redhat.com>
     71 
     72 	* argp-std.c (offline_callbacks): Use dwfl_build_id_find_elf.
     73 	(options, parse_opt): Handle --core.
     74 
     75 	* core-file.c: New file.
     76 	* Makefile.am (libdwfl_a_SOURCES): Add it.
     77 	* libdwflP.h (dwfl_core_file_report): Declare it.
     78 
     79 	* link_map.c: New file.
     80 	* Makefile.am (libdwfl_a_SOURCES): Add it.
     81 	* libdwflP.h (dwfl_link_map_report): Declare it.
     82 
     83 	* libdwflP.h (MIN, MAX): New macros.
     84 	(Dwfl_Memory_Callback): New typedef.
     85 	(Dwfl_Module_Callback): New typedef.
     86 	(dwfl_segment_report_module): Declare it.
     87 	* dwfl_segment_report_module.c: New file.
     88 	* Makefile.am (libdwfl_a_SOURCES): Add it.
     89 
     90 	* derelocate.c (dwfl_module_address_section): Add INTDEF.
     91 	* libdwflP.h: Add INTDECL.
     92 
     93 	* segment.c: New file.
     94 	* Makefile.am (libdwfl_a_SOURCES): Add it.
     95 	* libdwfl.h: Declare dwfl_addrsegment, dwfl_report_segment.
     96 	* libdwflP.h (struct Dwfl): New members lookup_elts, lookup_alloc,
     97 	lookup_addr, lookup_module, lookup_segndx, replace removed members
     98 	modules, nmodules.
     99 	(struct Dwfl_Module): New member segment.
    100 	* dwfl_end.c (dwfl_end): Free the new ones.  Iterate via modulelist
    101 	to each free module.
    102 	* dwfl_module.c (dwfl_report_begin_add): Do nothing.
    103 	(dwfl_report_begin): Don't call it.  Truncate the segment table instead.
    104 	(dwfl_report_module): Don't touch DWFL->nmodules.
    105 	(dwfl_report_end): Don't touch DWFL->modules and DWFL->nmodules.
    106 	(compare_modules): Function removed.
    107 	* dwfl_getmodules.c: Rewritten.
    108 	Add INTDEF.
    109 	* libdwflP.h: Add INTDECLs.
    110 	* dwfl_getdwarf.c: Rewritten to call dwfl_getmodules.
    111 	* dwfl_addrmodule.c: Rewritten to just call dwfl_addrsegment.
    112 
    113 2008-08-03  Roland McGrath  <roland (a] redhat.com>
    114 
    115 	* linux-kernel-modules.c: Include <fts.h> before <config.h>.
    116 
    117 2008-07-17  Roland McGrath  <roland (a] redhat.com>
    118 
    119 	* dwfl_build_id_find_elf.c (__libdwfl_open_by_build_id): Set errno to
    120 	zero if the failure was only ENOENT.
    121 
    122 2008-06-03  Roland McGrath  <roland (a] redhat.com>
    123 
    124 	* dwfl_module_addrsym.c (dwfl_module_addrsym): Exclude undefined
    125 	symbols.
    126 
    127 2008-05-22  Petr Machata  <pmachata (a] redhat.com>
    128 
    129 	* dwfl_module_getdwarf.c (open_elf): Bias of ET_EXEC files is always 0.
    130 
    131 2008-05-06  Roland McGrath  <roland (a] frob.com>
    132 
    133 	* linux-kernel-modules.c (dwfl_linux_kernel_report_offline): Use
    134 	FTS_LOGICAL here too.
    135 	(dwfl_linux_kernel_find_elf): Likewise.
    136 
    137 2008-04-29  Roland McGrath  <roland (a] redhat.com>
    138 
    139 	* find-debuginfo.c (dwfl_standard_find_debuginfo): Try path search
    140 	based on canonicalize_file_name if it differs from the supplied name.
    141 
    142 	* linux-kernel-modules.c (check_module_notes): Use FTS_LOGICAL so
    143 	we accept symlinks.
    144 
    145 2008-04-27  Roland McGrath  <roland (a] redhat.com>
    146 
    147 	* linux-kernel-modules.c (report_kernel): Fix crash when
    148 	dwfl_report_elf fails.
    149 
    150 2008-04-05  Roland McGrath  <roland (a] redhat.com>
    151 
    152 	* linux-proc-maps.c (proc_maps_report): Don't leak LAST_FILE.
    153 
    154 	* dwfl_module_getdwarf.c (find_file): Always free build_id_bits.
    155 	Clear it after freeing.
    156 	* dwfl_module_report_build_id.c (dwfl_module_report_build_id): Likewise.
    157 
    158 2008-03-26  Roland McGrath  <roland (a] redhat.com>
    159 
    160 	* dwfl_module_getdwarf.c (load_symtab): Don't return success for
    161 	SHT_DYNSYM, just set *SYMSCN like the comment says.
    162 
    163 	* dwfl_end.c (dwfl_end): Iterate on modulelist chain, not modules array.
    164 
    165 	* argp-std.c (parse_opt): On failure, call dwfl_end before argp_failure.
    166 
    167 2008-03-19  Roland McGrath  <roland (a] redhat.com>
    168 
    169 	* dwfl_module_getsrc.c: Adjust address for module bias before search.
    170 
    171 2008-03-01  Roland McGrath  <roland (a] redhat.com>
    172 
    173 	* libdwflP.h (__libdwfl_seterrno): Remove parameter name from
    174 	prototype to avoid older compiler's complaint about reuse of the name.
    175 	(__libdwfl_canon_error): Likewise.
    176 
    177 2008-02-19  Roland McGrath  <roland (a] redhat.com>
    178 
    179 	* relocate.c (relocate_section): Check for an unhandled relocation
    180 	type before resolving a reloc's symbol.  Lift DWFL_E_BADRELTYPE ->
    181 	DWFL_E_UNKNOWN_MACHINE check out of loops.
    182 
    183 	* dwfl_module_getdwarf.c (load_dw): Skip relocation if
    184 	DEBUGFILE->relocated is already set.
    185 
    186 2008-01-26  Roland McGrath  <roland (a] redhat.com>
    187 
    188 	* dwfl_module_getdwarf.c (open_elf): Open FILE->name if it's non-null.
    189 
    190 	* dwfl_build_id_find_elf.c (__libdwfl_open_by_build_id): Don't clear
    191 	incoming *FILE_NAME at the start.
    192 
    193 2008-01-08  Roland McGrath  <roland (a] redhat.com>
    194 
    195 	* Makefile.am (euinclude): Variable removed.
    196 	(pkginclude_HEADERS): Set this instead of euinclude_HEADERS.
    197 
    198 2007-10-23  Roland McGrath  <roland (a] redhat.com>
    199 
    200 	* linux-kernel-modules.c (report_kernel_archive): Reorder the kernel
    201 	module to appear first.
    202 
    203 2007-10-20  Roland McGrath  <roland (a] redhat.com>
    204 
    205 	* offline.c (process_archive_member): Take FD argument, pass it down
    206 	to process_file.  Return Elf_Cmd, not bool.
    207 	Call elf_next here, always before elf_end.
    208 	(process_archive): Update caller.  Don't close FD here unless there
    209 	are no member refs.
    210 
    211 	* dwfl_module.c (free_file): Close fd only when elf_end returns zero.
    212 
    213 	* libdwflP.h (struct dwfl_file): New bool member `relocated'.
    214 	* dwfl_module_getdwarf.c (dwfl_module_getelf): For ET_REL, apply
    215 	partial relocation to one or both files.
    216 	(dwfl_module_getdwarf): For ET_REL, make sure extra sections'
    217 	relocations have been applied to the debug file if dwfl_module_getelf
    218 	has been used before.
    219 
    220 	* relocate.c (resolve_symbol): New function.
    221 	(relocate_section): Call it.
    222 
    223 	* relocate.c (relocate_getsym): Handle null MOD->symfile.
    224 	(relocate_section): Take new bool arg, PARTIAL.  If true,
    225 	no error for BADRELTYPE/RELUNDEF, instead just skip them
    226 	and leave only those skipped relocs behind the reloc section.
    227 	(__libdwfl_relocate_section): Take new arg, pass it down.
    228 	(__libdwfl_relocate): Take new bool arg, DEBUG.  If false,
    229 	do partial relocation on all sections.
    230 	* dwfl_module_getdwarf.c (load_dw): Update caller.
    231 	* libdwflP.h: Update decls.
    232 	* derelocate.c (dwfl_module_address_section): Pass new argument
    233 	to __libdwfl_relocate_section, true.
    234 
    235 	* derelocate.c (cache_sections): Don't cache reloc sections when
    236 	section_address callback is null.
    237 
    238 2007-10-19  Roland McGrath  <roland (a] redhat.com>
    239 
    240 	* relocate.c (relocate_section): Fix fencepost error in r_offset check.
    241 
    242 	* derelocate.c (struct dwfl_relocation): Add member `relocs'.
    243 	(struct secref): Likewise.
    244 	(cache_sections): Cache the relocation section referring to each
    245 	section we cache, if any.
    246 	(dwfl_module_address_section): Use __libdwfl_relocate_section as
    247 	necessary.
    248 
    249 	* relocate.c (struct reloc_symtab_cache): New type.
    250 	(relocate_getsym): Use it instead of four arguments.
    251 	(__libdwfl_relocate): Update caller.
    252 	(relocate_section): New function, broken out of ...
    253 	(__libdwfl_relocate): ... here.
    254 	(__libdwfl_relocate_section): New function.
    255 	* libdwflP.h: Declare it.
    256 
    257 2007-10-17  Roland McGrath  <roland (a] redhat.com>
    258 
    259 	* dwfl_module_getsym.c (dwfl_module_getsym): Apply MOD->symfile->bias
    260 	to relocated st_value.
    261 
    262 	* dwfl_report_elf.c (__libdwfl_report_elf): Align initial BASE for
    263 	ET_REL to 0x100.
    264 
    265 2007-10-16  Roland McGrath  <roland (a] redhat.com>
    266 
    267 	* dwfl_report_elf.c (__libdwfl_report_elf): Readjust BASE when a later
    268 	section has larger alignment requirements not met by the original BASE,
    269 	rather than padding more between sections.
    270 
    271 	* dwfl_report_elf.c (__libdwfl_report_elf): Fix bias calculation.
    272 
    273 	* dwfl_module_build_id.c (__libdwfl_find_build_id): Apply module bias
    274 	to sh_addr value.
    275 
    276 	* dwfl_report_elf.c (__libdwfl_report_elf): Don't be confused by BASE
    277 	at zero in ET_REL case.  Adjust BASE to necessary alignment.
    278 
    279 	* dwfl_module_build_id.c (check_notes): Take -1, not 0, as stub value
    280 	for DATA_VADDR.
    281 	(__libdwfl_find_build_id): Update caller.
    282 
    283 	* relocate.c (__libdwfl_relocate_value): Don't use sh_offset.
    284 	* dwfl_report_elf.c (__libdwfl_report_elf): Likewise.
    285 	* offline.c (dwfl_offline_section_address): Bail early if there is
    286 	separate debug file.
    287 
    288 	* relocate.c (__libdwfl_relocate): Don't return DWFL_E_NO_DWARF.
    289 
    290 2007-10-09  Roland McGrath  <roland (a] redhat.com>
    291 
    292 	* dwfl_report_elf.c (__libdwfl_report_elf): Clear SHDR->sh_offset when
    293 	caching SHDR->sh_addr = 0.
    294 	* offline.c (dwfl_offline_section_address): Never called for sh_addr
    295 	really at 0, don't check for it.  Use MOD->debug directly, not symfile.
    296 
    297 	* dwfl_module_getdwarf.c (load_symtab): Return success properly when
    298 	we've found SHT_SYMTAB.
    299 
    300 	* relocate.c (relocate_getsym): New function.
    301 	(__libdwfl_relocate): Use it.
    302 	(__libdwfl_relocate_value): Take new Elf * argument.  Make SYMSHSTRNDX
    303 	be a pointer instead of value; cache getshstrndx result there.
    304 	* libdwflP.h: Update decl.
    305 	* derelocate.c (cache_sections): Update caller.
    306 	Always work on the main file, not the symfile.
    307 	(dwfl_module_address_section): Likewise.
    308 	* dwfl_module_getsym.c (dwfl_module_getsym): Update caller.
    309 
    310 2007-10-07  Roland McGrath  <roland (a] redhat.com>
    311 
    312 	* offline.c (process_archive): Initialize MOD.
    313 
    314 	* linux-kernel-modules.c (get_release): New function, broken out of ...
    315 	(report_kernel): ... here.  Call it.
    316 	(try_kernel_name): Take new arg TRY_DEBUG, only try ".debug" if set.
    317 	(find_kernel_elf): Update caller.
    318 	(report_kernel_archive): New function.
    319 	(dwfl_linux_kernel_report_offline): Call it.
    320 
    321 	* offline.c (process_file): Take new arg PREDICATE, pass it down.
    322 	(process_archive): Likewise.
    323 	(process_archive_member): Likewise.  When nonnull, let the predicate
    324 	decide whether to use this member.
    325 	(__libdwfl_report_offline): New function, broken out of ...
    326 	(dwfl_report_offline): ... here.  Call it.
    327 	* libdwflP.h: Declare it.
    328 
    329 	* offline.c (process_archive, process_archive_member): New functions.
    330 	(process_elf, process_file): New functions, broken out of ...
    331 	(dwfl_report_offline): ... here.  Call process_file, which recurses on
    332 	ELF_K_AR files.
    333 
    334 	* dwfl_report_elf.c (__libdwfl_report_elf): New, broken out of ...
    335 	(dwfl_report_elf): ... here.  Call it.
    336 	* libdwflP.h: Declare it.
    337 
    338 2007-10-06  Roland McGrath  <roland (a] redhat.com>
    339 
    340 	* derelocate.c (dwfl_module_relocations): Don't call
    341 	dwfl_module_getdwarf.
    342 
    343 	* derelocate.c (find_section): Use __libdwfl_seterrno, not
    344 	__libdw_seterrno.
    345 
    346 	* relocate.c (__libdwfl_relocate_value): Abuse sh_offset, not
    347 	SHF_ALLOC, to cache sh_addr resolved to 0.
    348 
    349 	* dwfl_report_elf.c (dwfl_report_elf): When an ET_REL file has sh_addr
    350 	values nonzero already, just use its existing layout.
    351 
    352 	* relocate.c (__libdwfl_relocate): Clear size of reloc section in its
    353 	in-core shdr after applying it.
    354 
    355 2007-10-04  Ulrich Drepper  <drepper (a] redhat.com>
    356 
    357 	* linux-kernel-modules.c (dwfl_linux_kernel_report_kernel): Fake
    358 	initialization of notes variable.
    359 
    360 2007-10-04  Roland McGrath  <roland (a] redhat.com>
    361 
    362 	* linux-kernel-modules.c (intuit_kernel_bounds): Take new arg NOTES,
    363 	fill in with vaddr of "__start_notes" symbol if found.
    364 	(check_notes): New function.
    365 	(check_kernel_notes): New function.
    366 	(dwfl_linux_kernel_report_kernel): Call it.
    367 	(check_module_notes): New function.
    368 	(dwfl_linux_kernel_report_modules): Call it.
    369 
    370 	* linux-kernel-modules.c (dwfl_linux_kernel_find_elf):
    371 	Try dwfl_build_id_find_elf first.
    372 
    373 	* linux-kernel-modules.c (report_kernel): Don't leak FD if !REPORT.
    374 	Set kernel module e_type to ET_DYN.
    375 
    376 2007-10-03  Roland McGrath  <roland (a] redhat.com>
    377 
    378 	* find-debuginfo.c (validate): New function, broken out of ...
    379 	(find_debuginfo_in_path): ... here.  New function, broken out of ...
    380 	(dwfl_standard_find_debuginfo): ... here.  Call it, after trying
    381 	dwfl_build_id_find_debuginfo first.
    382 
    383 	* dwfl_build_id_find_elf.c: New file.
    384 	* dwfl_build_id_find_debuginfo.c: New file.
    385 	* Makefile.am (libdwfl_a_SOURCES): Add them.
    386 	* libdwfl.h: Declare them.
    387 	* libdwflP.h: Add INTDECLs.
    388 
    389 	* dwfl_module_build_id.c: New file.
    390 	* dwfl_module_report_build_id.c: New file.
    391 	* Makefile.am (libdwfl_a_SOURCES): Add them.
    392 	* libdwfl.h: Declare them.
    393 	* libdwflP.h (struct Dwfl_Module): New members build_id_bits,
    394 	build_id_len, build_id_vaddr.  Declare __libdwfl_find_build_id.
    395 	* dwfl_module.c (__libdwfl_module_free): Free MOD->build_id_bits.
    396 
    397 	* dwfl_module_getdwarf.c (find_offsets): New function.
    398 	(find_dynsym): New function, calls that.
    399 	(find_symtab): Call it.
    400 
    401 2007-09-11  Roland McGrath  <roland (a] redhat.com>
    402 
    403 	* dwfl_module_addrsym.c: Prefer a later global symbol at the same
    404 	address if its st_size is smaller.
    405 
    406 2007-08-13  Roland McGrath  <roland (a] redhat.com>
    407 
    408 	* dwfl_module_addrsym.c: Add dead initializer for stupid compiler.
    409 
    410 2007-08-12  Roland McGrath  <roland (a] redhat.com>
    411 
    412 	* linux-kernel-modules.c (dwfl_linux_kernel_report_offline): Don't use
    413 	FTS_LOGICAL.
    414 
    415 	* elf-from-memory.c (elf_from_remote_memory): Don't reset LOADBASE on
    416 	a second phdr if it happens to match EHDR_VMA exactly.
    417 
    418 2007-08-08  Roland McGrath  <roland (a] redhat.com>
    419 
    420 	* dwfl_module_addrsym.c: Don't use STT_SECTION, STT_FILE symbols and
    421 	those with no names.  Rewrite best symbol algorithm not to assume a
    422 	sorted table and to be smarter handling sizeless symbols.
    423 
    424 2007-07-16  Roland McGrath  <roland (a] redhat.com>
    425 
    426 	* dwfl_module.c (dwfl_report_module): Increment DWFL->nmodules when
    427 	reviving an existing module.
    428 
    429 2007-06-08  Roland McGrath  <roland (a] redhat.com>
    430 
    431 	* libdwflP.h: Fix #ifndef for config.h to use PACKAGE_NAME.
    432 
    433 2007-05-17  Roland McGrath  <roland (a] redhat.com>
    434 
    435 	* linux-kernel-modules.c (dwfl_linux_kernel_report_offline): Look at
    436 	whole /lib/modules/VERSION tree, not just /lib/modules/VERSION/kernel.
    437 	(dwfl_linux_kernel_find_elf): Likewise.
    438 
    439 	* linux-kernel-modules.c (dwfl_linux_kernel_report_modules): Use
    440 	getline and sscanf instead of fscanf.
    441 
    442 2007-05-08  Roland McGrath  <roland (a] redhat.com>
    443 
    444 	* offline.c (dwfl_offline_section_address): Don't assume section
    445 	numbers match between stripped and debuginfo files.  Instead, assume
    446 	only that the ordering among SHF_ALLOC sections matches.
    447 
    448 	* linux-kernel-modules.c (report_kernel): Change RELEASE argument to
    449 	pointer to string.
    450 	(dwfl_linux_kernel_report_offline): Update caller.
    451 	(dwfl_linux_kernel_report_kernel): Likewise.
    452 
    453 2007-04-23  Roland McGrath  <roland (a] redhat.com>
    454 
    455 	* argp-std.c (options): Fix group title string.
    456 
    457 	* argp-std.c (parse_opt): Handle ARGP_KEY_ERROR, free the Dwfl.
    458 	Update via STATE->input every time we set STATE->hook, not only at
    459 	ARGP_KEY_SUCCESS.
    460 
    461 	* dwfl_module.c (free_file): Free FILE->name.
    462 
    463 2007-04-16  Roland McGrath  <roland (a] redhat.com>
    464 
    465 	* derelocate.c (cache_sections): Apply bias to sh_addr.
    466 	(compare_secrefs): Fix address comparison to avoid signed overflow.
    467 	(find_section): New function, broken out of ...
    468 	(dwfl_module_relocate_address): ... here, call it.
    469 	(check_module): New function, broken out of ...
    470 	(dwfl_module_relocate_address): ... here, call it.
    471 	(dwfl_module_address_section): New function.
    472 	* libdwfl.h: Declare it.
    473 
    474 2007-03-26  Roland McGrath  <roland (a] redhat.com>
    475 
    476 	* dwfl_module.c (__libdwfl_module_free): Free MOD itself.
    477 
    478 2007-03-18  Roland McGrath  <roland (a] redhat.com>
    479 
    480 	* dwfl_module_getdwarf.c (find_debuglink): New function, broken out of
    481 	(find_debuginfo): ... here.  Call it.
    482 	Don't return error for libelf errors finding .gnu_debuglink section.
    483 
    484 2007-03-12  Roland McGrath  <roland (a] redhat.com>
    485 
    486 	* dwfl_module.c (dwfl_report_begin_add): New function broken out of ...
    487 	(dwfl_report_begin): ... here.  Call it.
    488 	* libdwfl.h: Declare it.
    489 	* libdwflP.h: Add INTDECL.
    490 
    491 	* elf-from-memory.c (elf_from_remote_memory): Fix 32/64 typo.
    492 
    493 	* offline.c: Comment typo fix.
    494 
    495 2007-03-04  Roland McGrath  <roland (a] redhat.com>
    496 
    497 	* linux-kernel-modules.c (KERNEL_MODNAME): New macro for "kernel".
    498 	(find_kernel_elf): New function, broken out of ...
    499 	(report_kernel): ... here.  Call it.
    500 	(dwfl_linux_kernel_find_elf): Use it for module named KERNEL_MODNAME.
    501 	(intuit_kernel_bounds): New function, grovel /proc/kallsyms to guess
    502 	virtual address bounds of kernel from symbols rounded to page size.
    503 	(dwfl_linux_kernel_report_kernel): Use that if it works, before
    504 	resorting to report_kernel.
    505 
    506 	* dwfl_module_getdwarf.c (open_elf): Set MOD->e_type to ET_DYN for an
    507 	ET_EXEC file with nonzero bias.
    508 
    509 	* dwfl_module_addrname.c (dwfl_module_addrname): Just call
    510 	dwfl_module_addrsym.  Guts moved to ...
    511 	* dwfl_module_addrsym.c: ... here; new file.
    512 	* Makefile.am (libdwfl_a_SOURCES): Add it.
    513 	* libdwfl.h: Declare dwfl_module_addrsym.
    514 	* libdwflP.h: Add INTDECL.
    515 
    516 2007-03-03  Roland McGrath  <roland (a] redhat.com>
    517 
    518 	* dwfl_module.c (free_file): New function, broken out of ...
    519 	(__libdwfl_module_free): ... here.  In it, close fd after elf_end.
    520 
    521 	* dwfl_module_getdwarf.c (open_elf): Close fd and reset to -1
    522 	on libelf failure.
    523 
    524 2007-03-02  Roland McGrath  <roland (a] redhat.com>
    525 
    526 	* linux-kernel-modules.c: Fix bogus error test for asprintf call.
    527 
    528 2007-02-02  Roland McGrath  <roland (a] redhat.com>
    529 
    530 	* dwfl_addrmodule.c (dwfl_addrmodule): Match a module's high boundary
    531 	address exactly if it's no other module's low boundary.
    532 
    533 	* dwfl_module_addrname.c (dwfl_module_addrname): If no symbol's value
    534 	and size cover the address, select the closest symbol with st_size==0
    535 	that lies in the same section.
    536 
    537 2007-01-29  Roland McGrath  <roland (a] redhat.com>
    538 
    539 	* dwfl_version.c (dwfl_version): Return PACKAGE_VERSION,
    540 	not PACKAGE_STRING.
    541 
    542 2007-01-20  Roland McGrath  <roland (a] redhat.com>
    543 
    544 	* relocate.c (__libdwfl_relocate_value): Treat section_address of -1
    545 	as omitted, not 0.
    546 	* libdwfl.h (Dwfl_Callbacks): Update comment.
    547 	* derelocate.c (cache_sections): Don't ignore sh_addr == 0 sections.
    548 	* linux-kernel-modules.c (dwfl_linux_kernel_module_section_address):
    549 	For ignored missing section, use -1 instead of 0.
    550 	* offline.c (dwfl_offline_section_address): Expect a call for 0.
    551 
    552 2007-01-19  Roland McGrath  <roland (a] redhat.com>
    553 
    554 	* argp-std.c (parse_opt): For -e, reset DWFL->offline_next_address to
    555 	zero so a lone -e foo.so is shown without address bias.
    556 
    557 2007-01-10  Roland McGrath  <roland (a] redhat.com>
    558 
    559 	* linux-kernel-modules.c (report_kernel): Check asprintf return value
    560 	directly instead of via side effect, to silence warn_unused_result.
    561 	(dwfl_linux_kernel_report_offline): Likewise.
    562 	(dwfl_linux_kernel_find_elf): Likewise.
    563 	(dwfl_linux_kernel_module_section_address): Likewise.
    564 	* find-debuginfo.c (try_open): Likewise.
    565 	* linux-proc-maps.c (find_sysinfo_ehdr): Likewise.
    566 	(dwfl_linux_proc_report): Likewise.
    567 
    568 	* libdwfl.h (dwfl_begin): Require nonnull argument.
    569 
    570 2006-12-27  Roland McGrath  <roland (a] redhat.com>
    571 
    572 	* dwfl_module.c (compare_modules): Fix address comparison to avoid
    573 	signed overflow.  Patch by Frank Ch. Eigler <fche (a] redhat.com>.
    574 
    575 2006-10-30  Roland McGrath  <roland (a] redhat.com>
    576 
    577 	* dwfl_module.c (dwfl_report_module): Comment typo fix.
    578 
    579 2006-09-05  Roland McGrath  <roland (a] redhat.com>
    580 
    581 	* derelocate.c (cache_sections): Use alloca instead of variable-sized
    582 	auto array, in function already alloca.
    583 
    584 2006-08-14  Roland McGrath  <roland (a] redhat.com>
    585 
    586 	* linux-kernel-modules.c (try_kernel_name): If the call to
    587 	dwfl_standard_find_debuginfo produces no results, try it again
    588 	with NULL as DEBUGLINK_FILE to try *FNAME with .debug suffix.
    589 
    590 	* find-debuginfo.c (DEFAULT_DEBUGINFO_PATH): Macro moved ...
    591 	* libdwflP.h: ... to here.
    592 	* linux-kernel-modules.c (try_kernel_name): Skip manual open if it
    593 	repeats the first thing dwfl_standard_find_debuginfo will try.
    594 
    595 	* linux-kernel-modules.c (MODULE_SECT_NAME_LEN): New macro.
    596 	(dwfl_linux_kernel_module_section_address): If a /sys file is missing
    597 	and the section name is >= MODULE_SECT_NAME_LEN, try truncating the
    598 	section name.
    599 
    600 2006-07-12  Ulrich Drepper  <drepper (a] redhat.com>
    601 
    602 	* cu.c: Adjust for internal_function_def removal.
    603 	* dwfl_error.c: Likewise.
    604 	* dwfl_module.c: Likewise.
    605 	* dwfl_module_getdwarf.c: Likewise.
    606 	* lines.c: Likewise.
    607 	* relocate.c: Likewise.
    608 
    609 2006-07-11  Ulrich Drepper  <drepper (a] redhat.com>
    610 
    611 	* dwfl_module.c (compare_modules): Don't return GElf_Sxword value,
    612 	it can overflow the return value type.
    613 	Patch by Tim Moore <timoore (a] redhat.com>.
    614 
    615 2006-06-28  Roland McGrath  <roland (a] redhat.com>
    616 
    617 	* libdwfl.h: Cosmetic changes.
    618 
    619 	* dwfl_line_comp_dir.c: New file.
    620 	* Makefile.am (libdwfl_a_SOURCES): Add it.
    621 	* libdwfl.h: Declare dwfl_line_comp_dir.
    622 
    623 	* dwfl_lineinfo.c (dwfl_lineinfo): Remove stray extern in defn.
    624 
    625 	* dwfl_linecu.c: New file.
    626 	* Makefile.am (libdwfl_a_SOURCES): Add it.
    627 	* libdwfl.h: Declare dwfl_linecu.
    628 
    629 	* libdwflP.h (dwfl_linecu_inline): Function renamed from dwfl_linecu.
    630 	(dwfl_linecu): Define as macro.
    631 
    632 	* relocate.c (__libdwfl_relocate): Use dwfl_module_getsym.
    633 
    634 	* dwfl_module_getdwarf.c (dwfl_module_getsymtab): New function.
    635 	(dwfl_module_addrname): Function moved ...
    636 	* dwfl_module_addrname.c: ... here, new file.
    637 	* dwfl_module_getsym.c: New file.
    638 	* Makefile.am (libdwfl_a_SOURCES): Add them.
    639 	* libdwfl.h: Declare dwfl_module_getsymtab, dwfl_module_getsym.
    640 	* libdwflP.h: Add INTDECLs.
    641 
    642 2006-06-27  Roland McGrath  <roland (a] redhat.com>
    643 
    644 	* dwfl_module.c (dwfl_report_end): Whitespace fix.
    645 
    646 2006-06-13  Roland McGrath  <roland (a] redhat.com>
    647 
    648 	* elf-from-memory.c (elf_from_remote_memory): Fix 32/64 typo.
    649 	Use __libdwfl_seterrno for elf_memory failure.
    650 
    651 2006-05-22  Roland McGrath  <roland (a] redhat.com>
    652 
    653 	* dwfl_module_return_value_location.c
    654 	(dwfl_module_return_value_location): Use __libdwfl_module_getebl.
    655 
    656 2006-05-27  Ulrich Drepper  <drepper (a] redhat.com>
    657 
    658 	* libdwfl.h: Add extern "C".
    659 
    660 2006-05-22  Ulrich Drepper  <drepper (a] redhat.com>
    661 
    662 	* cu.c (addrarange): Handle files without aranges information.
    663 
    664 2006-05-16  Ulrich Drepper  <drepper (a] redhat.com>
    665 
    666 	* dwfl_addrmodule.c (dwfl_addrmodule): Also return NULL of
    667 	->modules is NULL.
    668 
    669 2006-02-26  Roland McGrath  <roland (a] redhat.com>
    670 
    671 	* dwfl_version.c: New file.
    672 	* Makefile.am (libdwfl_a_SOURCES): Add it.
    673 	* libdwfl.h: Declare dwfl_version.
    674 
    675 	* offline.c (dwfl_report_offline): Account for dwfl_report_elf having
    676 	aligned up from DWFL->offline_next_address when checking for overlap.
    677 
    678 2005-12-22  Roland McGrath  <roland (a] redhat.com>
    679 
    680 	* argp-std.c (parse_opt): Call dwfl_end in failure cases.
    681 
    682 	* linux-proc-maps.c (proc_maps_report): New function, broken out of ...
    683 	(dwfl_linux_proc_report): ... here.  Call it.
    684 	(dwfl_linux_proc_maps_report): New function.
    685 	* libdwfl.h: Declare it.
    686 	* libdwflP.h: Add INTDECL.
    687 	* argp-std.c (options, parse_opt): Grok -M/--linux-process-map.
    688 
    689 	* dwfl_nextcu.c (dwfl_nextcu): Don't fail when dwfl_module_getdwarf
    690 	failed with DWFL_E_NO_DWARF.
    691 
    692 2005-11-26  Roland McGrath  <roland (a] redhat.com>
    693 
    694 	* dwfl_end.c (dwfl_end): Free the DWFL itself.
    695 
    696 2005-11-25  Roland McGrath  <roland (a] redhat.com>
    697 
    698 	* dwfl_module_getdwarf.c (__libdwfl_module_getebl): New function.
    699 	(load_dw): Use it.
    700 	* dwfl_module_register_names.c (dwfl_module_register_names): Likewise.
    701 	* libdwflP.h: Declare it.
    702 
    703 	* dwfl_module_register_names.c: New file.
    704 	* Makefile.am (libdwfl_a_SOURCES): Add it.
    705 	* libdwfl.h: Declare dwfl_module_register_names.
    706 
    707 2005-11-21  Roland McGrath  <roland (a] redhat.com>
    708 
    709 	* linux-kernel-modules.c (dwfl_linux_kernel_module_section_address):
    710 	Don't leak malloc'd file name.
    711 	If a /sys/.../sections file is missing and starts with ".init",
    712 	try the variant with "_init" too; catches PPC64 kernel braindamage.
    713 
    714 2005-11-15  Roland McGrath  <roland (a] redhat.com>
    715 
    716 	* libdwfl.h: Comment fixes.
    717 
    718 	* dwfl_module_return_value_location.c: Add unlikely for error case.
    719 
    720 2005-11-13  Roland McGrath  <roland (a] redhat.com>
    721 
    722 	* dwfl_return_value_location.c: New file.
    723 	* Makefile.am (libdwfl_a_SOURCES): Add it.
    724 	* libdwfl.h: Declare dwfl_module_return_value_location.
    725 	* libdwflP.h (DWFL_ERRORS): Add DWFL_E_WEIRD_TYPE.
    726 
    727 2005-10-20  Roland McGrath  <roland (a] redhat.com>
    728 
    729 	* libdwflP.h (DWFL_ERRORS): New error UNKNOWN_MACHINE.
    730 	* relocate.c (__libdwfl_relocate): Return DWFL_E_UNKNOWN_MACHINE
    731 	instead of DWFL_E_BADRELTYPE if ebl_get_elfmachine yields EM_NONE.
    732 
    733 2005-10-01  Roland McGrath  <roland (a] redhat.com>
    734 
    735 	* linux-kernel-modules.c (report_kernel): Return ENOENT if we fail
    736 	with errno 0.
    737 
    738 2005-09-19  Roland McGrath  <roland (a] redhat.com>
    739 
    740 	* linux-kernel-modules.c (dwfl_linux_kernel_report_modules): Use
    741 	PRIx64 instead of PRIi64, lest addresses with high bits set overflow
    742 	the signed integer reading; they will just have to be in hexadecimal.
    743 	(dwfl_linux_kernel_module_section_address): Likewise.
    744 
    745 2005-08-28  Ulrich Drepper  <drepper (a] redhat.com>
    746 
    747 	* Makefile.am (%.os): Use COMPILE.os.
    748 	(COMPILE.os): Filter out gconv options.
    749 
    750 2005-08-25  Roland McGrath  <roland (a] redhat.com>
    751 
    752 	* cu.c (__libdwfl_nextcu): Return success when dwarf_nextcu hits end.
    753 	* dwfl_nextcu.c (dwfl_nextcu): Skip modules with no dwarf info.
    754 
    755 2005-08-24  Roland McGrath  <roland (a] redhat.com>
    756 
    757 	* dwfl_lineinfo.c (dwfl_lineinfo): Add bias, don't subtract it.
    758 
    759 	* argp-std.c [_MUDFLAP] (__libdwfl_argp_mudflap_options): New function,
    760 	magic initializer to set -heur-stack-bound option.
    761 
    762 2005-08-22  Roland McGrath  <roland (a] redhat.com>
    763 
    764 	* dwfl_validate_address.c: New file.
    765 	* Makefile.am (libdwfl_a_SOURCES): Add it.
    766 	* libdwfl.h: Declare dwfl_validate_address.
    767 
    768 	* derelocate.c (dwfl_module_relocate_address): Add INTDEF.
    769 	* libdwflP.h: Add INTDECL.
    770 
    771 	* dwfl_module_getdwarf.c (find_symtab): Use elf_getdata instead of
    772 	elf_rawdata for symbol-related sections.
    773 
    774 	* offline.c (dwfl_report_offline): Move offline_next_address outside
    775 	module's range, in case it's an ET_EXEC using fixed segment locations.
    776 	* libdwfl.h: Update comment.
    777 
    778 	* dwfl_report_elf.c (dwfl_report_elf): Align BASE to first segment's
    779 	required alignment.
    780 
    781 2005-08-20  Roland McGrath  <roland (a] redhat.com>
    782 
    783 	* linux-kernel-modules.c (report_kernel): Take new argument PREDICATE,
    784 	function to choose whether to report.
    785 	(dwfl_linux_kernel_report_offline): Likewise.
    786 	* libdwfl.h: Update decl.
    787 	* argp-std.c (parse_opt): Update caller.
    788 
    789 	* dwfl_getsrclines.c: New file.
    790 	* dwfl_onesrcline.c: New file.
    791 	* Makefile.am (libdwfl_a_SOURCES): Add them.
    792 	* libdwfl.h: Declare dwfl_getsrclines, dwfl_onesrcline.
    793 
    794 	* linux-kernel-modules.c (dwfl_linux_kernel_find_elf): Don't leak
    795 	MODULESDIR[0].  Call fts_close on failure.
    796 
    797 	* dwfl_module_getdwarf.c (load_dw): Take dwfl_file * instead of Elf *.
    798 	Close ET_REL file descriptors after relocation.
    799 	(find_dw): Update caller.
    800 	* offline.c (dwfl_report_offline): Get the file into memory and close
    801 	the file descriptor.
    802 
    803 	* dwfl_module_getdwarf.c (find_debuginfo): Do nothing when
    804 	MOD->debug.elf is already set.
    805 
    806 	* find-debuginfo.c (try_open): Use TEMP_FAILURE_RETRY.
    807 	(dwfl_standard_find_debuginfo): Fail on errors not ENOENT or ENOTDIR.
    808 
    809 	* argp-std.c (options, parse_opt): Grok -K/--offline-kernel, use
    810 	dwfl_linux_kernel_report_offline with offline_callbacks.
    811 
    812 	* linux-kernel-modules.c (report_kernel): New function, broken out of
    813 	...
    814 	(dwfl_linux_kernel_report_kernel): ... here.  Use it.
    815 	(dwfl_linux_kernel_report_offline): New function.
    816 	* libdwfl.h: Declare it.
    817 	* libdwflP.h: Add INTDECL.
    818 
    819 2005-08-19  Roland McGrath  <roland (a] redhat.com>
    820 
    821 	Use standard debuginfo search path to look for vmlinux.
    822 	* find-debuginfo.c (dwfl_standard_find_debuginfo): Don't check CRC if
    823 	passed zero.
    824 	* linux-kernel-modules.c (try_kernel_name): New function, broken out
    825 	of ...
    826 	(dwfl_linux_kernel_report_kernel): ... here.  Use it.
    827 
    828 	* argp-std.c (offline_callbacks): New variable.
    829 	(parse_opt): Use it for -e.  Allow multiple -e options.
    830 
    831 	* offline.c: New file.
    832 	* Makefile.am (libdwfl_a_SOURCES): Add it.
    833 	* libdwfl.h: Declare dwfl_offline_section_address, dwfl_report_offline.
    834 	* libdwflP.h: Add INTDECLs.
    835 	(OFFLINE_REDZONE): New macro.
    836 	(struct Dwfl): New member `offline_next_address'.
    837 	* dwfl_begin.c (dwfl_begin): Initialize it.
    838 	* dwfl_module.c (dwfl_report_begin): Likewise.
    839 
    840 	* dwfl_report_elf.c (dwfl_report_elf): Accept all types.  When ET_REL,
    841 	do a nominal absolute section layout starting at BASE.
    842 	* libdwfl.h: Update comment.
    843 
    844 2005-08-18  Roland McGrath  <roland (a] redhat.com>
    845 
    846 	* dwfl_module_getsrc_file.c (dwfl_module_getsrc_file): Do
    847 	dwfl_module_getdwarf if necessary.
    848 
    849 	* dwfl_report_elf.c (dwfl_report_elf): Permit ET_REL with BASE==0.
    850 	* libdwfl.h: Update comment.
    851 
    852 	* derelocate.c: New file.
    853 	* Makefile.am (libdwfl_a_SOURCES): Add it.
    854 
    855 	* libdwflP.h (struct Dwfl_Module): isrel -> e_type.
    856 	* dwfl_report_elf.c (dwfl_report_elf): Initialize it.
    857 	* dwfl_module_getdwarf.c (open_elf): Update initialization.
    858 	(load_dw, dwfl_module_addrname): Update uses.
    859 	* relocate.c (__libdwfl_relocate): Likewise.
    860 
    861 2005-08-04  Roland McGrath  <roland (a] redhat.com>
    862 
    863 	* libdwfl.h (Dwfl_Callbacks.section_address): Take additional
    864 	arguments SHNDX, SHDR.
    865 	(dwfl_linux_kernel_module_section_address): Update prototype.
    866 	* relocate.c (__libdwfl_relocate_value): Update caller.
    867 	* linux-kernel-modules.c (dwfl_linux_kernel_module_section_address):
    868 	Take the new arguments.
    869 
    870 2005-08-10  Roland McGrath  <roland (a] redhat.com>
    871 
    872 	* relocate.c (__libdwfl_relocate): Take argument DEBUGFILE,
    873 	use it instead of MOD->debug.file.
    874 	* libdwflP.h: Update decl.
    875 	* dwfl_module_getdwarf.c (load_dw): Update caller.
    876 	Fixes bug #165598.
    877 
    878 2005-08-09  Roland McGrath  <roland (a] redhat.com>
    879 
    880 	* libdwflP.h: Include ../libdw/libdwP.h for its INTDECLs.
    881 	* cu.c: Use INTUSE on dwarf_* calls.
    882 	* dwfl_error.c: Likewise.
    883 	* dwfl_module.c: Likewise.
    884 	* dwfl_module_getdwarf.c: Likewise.
    885 	* dwfl_module_getsrc_file.c: Likewise.
    886 	* lines.c: Likewise.
    887 
    888 2005-08-07  Roland McGrath  <roland (a] redhat.com>
    889 
    890 	* linux-kernel-modules.c (dwfl_linux_kernel_find_elf): When module
    891 	names contain '_' or '-', look for files named either "foo-bar.ko"
    892 	or "foo_bar.ko".
    893 
    894 2005-07-29  Roland McGrath  <roland (a] redhat.com>
    895 
    896 	* loc2c.c: File removed.
    897 	* loc2c.h: File removed.
    898 	* loc2c-runtime.h: File removed.
    899 	* test2.c: File removed.
    900 	* Makefile.am (EXTRA_DIST): Variable removed.
    901 	(noinst_HEADERS): Remove loc2c.h from here.
    902 
    903 2005-07-28  Ulrich Drepper  <drepper (a] redhat.com>
    904 
    905 	* libdwfl.h: Add a few missing extern for function prototypes.
    906 
    907 	* libdwfl_crc32.c: New file.
    908 	* libdwfl_crc32_file.c: New file.
    909 	* libdwflP.h: Declare the new functions.
    910 	* Makefile.am (libdwfl_a_SOURCES): Add libdwfl_crc32.c and
    911 	libdwfl_crc32_file.c.
    912 	* libdwfl/find-debuginfo.c (check_crc): Use __libdwfl_crc32_file
    913 	instead of crc32_file.
    914 
    915 2005-07-28  Roland McGrath  <roland (a] redhat.com>
    916 
    917 	* ptest.c: Moved to ../tests/dwflmodtest.c.
    918 
    919 	* Makefile.am (noinst_PROGRAMS): Variable removed.
    920 	(libdwfl_so_SOURCES, libdwfl_LIBS, libdwfl_so_LDADD): Likewise.
    921 	(EXTRA_DIST, ptest_LDADD, test2_LDADD): Likewise.
    922 	(libdwfl): Don't use libdwfl.so any more.
    923 	(libdwfl.so, install, uninstall): Targets removed.
    924 	(test2_SOURCES): Define EXTRA_DIST instead of this.
    925 	* libdwfl.map: File removed.
    926 
    927 	* libdwfl.h: Use "" for libdw.h #include.
    928 
    929 2005-07-27  Roland McGrath  <roland (a] redhat.com>
    930 
    931 	* libdwfl.map: Add dwfl_getmodules.
    932 
    933 2005-07-23  Ulrich Drepper  <drepper (a] redhat.com>
    934 
    935 	* Makefile.am: Fix rules to allow building with mudflap.
    936 
    937 2005-07-21  Roland McGrath  <roland (a] redhat.com>
    938 
    939 	* Makefile.am (noinst_HEADERS): Add loc2c.c.
    940 
    941 	* test2.c (main): Check sscanf result to quiet warning.
    942 
    943 2005-07-20  Roland McGrath  <roland (a] redhat.com>
    944 
    945 	* libdwfl-branch merged, creating this direcotry.
    946