aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/kldxref
Commit message (Collapse)AuthorAgeFilesLines
* kldxref: bump MAXSEGS to 3Ed Maste2017-02-101-1/+1
| | | | | | | | | | | | | | ld.bfd generates two PT_LOAD segments, but certain linkers or linker configurations generate three PT_LOAD segments (one additional for RELRO). PR: 216975 Reported by: Shawn Webb MFC after: 1 week Sponsored by: The FreeBSD Foundation Notes: svn path=/head/; revision=313563
* kldxref: s/sections/segments/ in warning messageEd Maste2017-02-101-1/+1
| | | | | | | | | The message refers to program header segments, not sections. PR: 216975 Notes: svn path=/head/; revision=313562
* Use roundup2() from sys/param.h.Marcelo Araujo2016-08-231-1/+1
| | | | Notes: svn path=/head/; revision=304678
* Use NULL instead of 0 for pointers.Marcelo Araujo2016-05-161-1/+1
| | | | | | | MFC after: 2 weeks. Notes: svn path=/head/; revision=299878
* Add support for relocating AArch64 modules to kldxref. This fixes an errorAndrew Turner2016-01-131-0/+77
| | | | | | | | | | message where it fails to read the module as the unrelocated addresses are zero. Sponsored by: ABT Systems Ltd Notes: svn path=/head/; revision=293852
* Augment kldxref to find the new MODULE_PNP_INFO records now inWarner Losh2015-12-111-3/+344
| | | | | | | | | | modules, simplify them into a more normal form and write them to linker.hints. Differential Review: https://reviews.freebsd.org/D3461 Notes: svn path=/head/; revision=292078
* Add debug file extension to kldxref(8) after r288176Ed Maste2015-10-021-1/+4
| | | | | | | | | | | | | | After r288176 kernel debug files have the extension .debug. They also moved to /usr/lib/debug/boot/kernel by default so in the normal case kldxref does not encounter them. A src.conf(5) setting may be used to continue installing them in /boot/kernel though, so have kldxref skip .debug files in addition to .symbols files. Reported by: fabient Sponsored by: The FreeBSD Foundation Notes: svn path=/head/; revision=288490
* Add META_MODE support.Simon J. Gerraty2015-06-131-0/+18
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | Off by default, build behaves normally. WITH_META_MODE we get auto objdir creation, the ability to start build from anywhere in the tree. Still need to add real targets under targets/ to build packages. Differential Revision: D2796 Reviewed by: brooks imp Notes: svn path=/head/; revision=284345
| * dirdeps.mk now sets DEP_RELDIRSimon J. Gerraty2015-06-081-2/+0
| | | | | | | | Notes: svn path=/projects/bmake/; revision=284172
| * Merge sync of headSimon J. Gerraty2015-05-272-2/+5
| |\ | |/ |/| | | Notes: svn path=/projects/bmake/; revision=283595
| * Merge head from 7/28Simon J. Gerraty2014-08-191-3/+3
| |\ | | | | | | | | | Notes: svn path=/projects/bmake/; revision=270164
| * | Updated dependenciesSimon J. Gerraty2014-05-161-1/+0
| | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=266219
| * | Updated dependenciesSimon J. Gerraty2014-05-101-0/+2
| | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=265802
| * | Merge from headSimon J. Gerraty2014-05-081-8/+9
| |\ \ | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=265720
| * \ \ Merge headSimon J. Gerraty2014-04-281-1/+1
| |\ \ \ | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=265044
| * \ \ \ Merge head@256284Simon J. Gerraty2013-10-131-1/+11
| |\ \ \ \ | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=256424
| * \ \ \ \ Merge from headSimon J. Gerraty2013-09-055-7/+1
| |\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=255263
| * | | | | | Updated dependenciesSimon J. Gerraty2013-03-111-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=248169
| * | | | | | Updated dependenciesSimon J. Gerraty2013-02-161-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=246868
| * | | | | | Sync from headSimon J. Gerraty2012-11-041-4/+3
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=242545
| * | | | | | | Sync FreeBSD's bmake branch with Juniper's internal bmake branch.Marcel Moolenaar2012-08-221-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Requested by: Simon Gerraty <sjg@juniper.net> Notes: svn path=/projects/bmake/; revision=239572
* | | | | | | | Reserve and ignore the a new module metadata type MDT_PNP_INFO forWarner Losh2015-01-151-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | associating an optional PNP hint table with this module. In the future, when these are added, these changes will silently ignore the new type they would otherwise warn about. It will always be safe to ignore this data. Get this into the builds today for some future proofing. MFC After: 3 days Notes: svn path=/head/; revision=277205
* | | | | | | | Bump the largest record we can cope with from 1k to 8k. Other users ofWarner Losh2014-12-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | the hints file don't have any real limits, and longer records will need to be written shortly. Notes: svn path=/head/; revision=275940
* | | | | | | | Remove -fno-strict-alias, as it is no longer needed.Warner Losh2014-12-181-1/+0
| |_|_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | Notes: svn path=/head/; revision=275904
* | | | | | | use .Mt to mark up email addresses consistently (part2)Baptiste Daroussin2014-06-201-3/+3
| |_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PR: 191174 Submitted by: Franco Fichtner <franco@lastsummer.de> Notes: svn path=/head/; revision=267668
* | | | | | kldxref: Clean up error reportingEd Maste2014-04-301-8/+9
| |_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Omit "too many sections" warnings if the ELF file is not dynamically linked (and is therefore skipped anyway), and otherwise output it only once. An errant core file would previously cause kldxref to output a number of warnings. Also introduce a MAXSEGS #define and replace literal 2 with it, to make comparisons clear. Reviewed by: kib Sponsored by: The FreeBSD Foundation Notes: svn path=/head/; revision=265157
* | | | | kldxref: Add static keyword to the new function only used in the same file.Jilles Tjoelker2013-10-161-1/+1
| |_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The WARNS level is not such that the omission broke the build. Reported by: mdf Notes: svn path=/head/; revision=256650
* | | | kldxref: Do not depend on the directory order.Jilles Tjoelker2013-10-041-1/+11
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sort the filenames to get a consistent result between machines of the same architecture. Also, sort FTS_D entries after other entries so kldxref -R works properly in the uncommon case that a directory contains both subdirectories and modules. Previously, this may have happened to work, depending on the order of files in the directory. PR: bin/182098 Submitted by: Derek Schrock (original version) Tested by: Derek Schrock Approved by: re (delphij) MFC after: 1 week Notes: svn path=/head/; revision=256060
* | | Use calloc().Xin LI2013-06-051-2/+1
| | | | | | | | | | | | | | | | | | | | | MFC after: 2 weeks Notes: svn path=/head/; revision=251440
* | | Remove unneeded reference to link.h (sys/link_elf.h).Xin LI2013-06-055-5/+0
| |/ |/| | | | | | | | | | | MFC after: 2 weeks Notes: svn path=/head/; revision=251439
* | Clarify a warning message.Tim Kientzle2012-10-291-1/+2
| | | | | | | | Notes: svn path=/head/; revision=242277
* | Remove variables which are initialized but never used thereafter reported by ↵Eitan Adler2012-06-191-3/+1
|/ | | | | | | | | | gcc46 warning Approved by: cperciva MFC After: 3 days Notes: svn path=/head/; revision=237258
* Reencode files to UTF-8. Drop CP1252 em-dash.Ulrich Spörlein2011-12-301-1/+1
| | | | Notes: svn path=/head/; revision=228976
* Repair some build breakage introduced in r211725 and garbage collect someNathan Whitehorn2010-08-281-1/+1
| | | | | | | code made obsolete in the same commit. Notes: svn path=/head/; revision=211934
* MFtbemd:Warner Losh2010-08-231-2/+2
| | | | | | | | Prefer MACHNE_CPUARCH to MACHINE_ARCH in most contexts where you want to test of all the CPUs of a given family conform. Notes: svn path=/head/; revision=211725
* various cleanups including:Luigi Rizzo2009-01-061-82/+77
| | | | | | | | | | | | + check a possible buffer overflow when creating a temp file, submitted by Christoph Mallon + remove stale struct definitions + clarify the use of dflag and remove useless checks MFC after: 3 days Notes: svn path=/head/; revision=186827
* fix a couple of innocuous compiler warningsLuigi Rizzo2009-01-062-3/+4
| | | | | | | MFC after: 3 days Notes: svn path=/head/; revision=186826
* correct description of how a string is stored, fix a fewLuigi Rizzo2009-01-061-5/+10
| | | | | | | | | | | | typos and reference the kernel file which processes this info. All in all, the content of this file should be moved to kldxref.c or to the kld(4) manpage. MFC after: 3 days Notes: svn path=/head/; revision=186824
* Make the linker.hints file have mode 644 instead of 600.Luigi Rizzo2008-11-301-0/+2
| | | | | | | | | | There is nothing secret in the file, and the missing read permission breaks diskless operation. MFC after: 4 weeks Notes: svn path=/head/; revision=185475
* These are the things that the tinderbox has problems with because itJohn Birrell2007-11-201-0/+1
| | | | | | | | | | | doesn't use the default CFLAGS which contain -fno-strict-aliasing. Until the code is cleaned up, just add -fno-strict-aliasing to the CFLAGS of these for the tinderboxes' sake, allowing the rest of the tree to have -Werror enabled again. Notes: svn path=/head/; revision=173766
* Use safe strlcpy rather than unsafe strncpy. After marcel's last fix,Warner Losh2006-08-051-4/+2
| | | | | | | | | there was still one overflow possible. strlcpy is faster anyway because it doesn't unexpectedly zero the entire length of the string when copying short strings.... Notes: svn path=/head/; revision=161004
* Build shared on PowerPC now that the bug has been found and fixed.Marcel Moolenaar2006-08-041-4/+0
| | | | Notes: svn path=/head/; revision=160984
* Fix (static) buffer overflow bug. The dest buffer is of size MAXPATHLEN,Marcel Moolenaar2006-08-041-1/+1
| | | | | | | | | so dest[MAXPATHLEN] falls outside the buffer. This bug corrupted arenas[0] defined in libc's malloc.c on PowerPC when kldxref is shared, which triggered a delayed SIGSERV. Notes: svn path=/head/; revision=160982
* Use NO_SHARED=YES to force a static link.Marcel Moolenaar2006-07-301-1/+1
| | | | | | | Pointed out by: ru@ Notes: svn path=/head/; revision=160842
* Link kldxref(8) static on PowerPC to work around a SIGSEGV thatMarcel Moolenaar2006-07-291-0/+4
| | | | | | | | | | cannot easily be analyzed due to there being no debugger yet. The SIGSEGV only happens when kldxref is linked shared. Since kldxref(8) is needed for a release build, having it not dump core is important. Notes: svn path=/head/; revision=160820
* Change maketempfile() to return a FILE* so as to eliminate the fopen()Marcel Moolenaar2006-07-291-6/+7
| | | | | | | | | | | | | that immediately follows the only call to it. maketempfile() uses mkstemp(), so the temporary file has already been opened and using fopen() again just opens the file twice. This also fixes the invalid mode used on the fopen(). While here, assign NULL to fxref after fclose() because we test for fxref being !NULL to determine if we have the (temporary) hints file open. Notes: svn path=/head/; revision=160818
* Use posix_memalign() rather than assuming that malloc() provides adequateJason Evans2006-01-121-5/+7
| | | | | | | | | alignment. Approved by: markm (mentor) Notes: svn path=/head/; revision=154251
* Make our ELF64 type definitions match standards. In particular thisMarcel Moolenaar2005-12-187-9/+9
| | | | | | | | | | | | | | | | means: o Remove Elf64_Quarter, o Redefine Elf64_Half to be 16-bit, o Redefine Elf64_Word to be 32-bit, o Add Elf64_Xword and Elf64_Sxword for 64-bit entities, o Use Elf_Size in MI code to abstract the difference between Elf32_Word and Elf64_Word. o Add Elf_Ssize as the signed counterpart of Elf_Size. MFC after: 2 weeks Notes: svn path=/head/; revision=153504
* Explicitly cast ELF_R_TYPE() to the right type.Marcel Moolenaar2005-12-181-1/+1
| | | | Notes: svn path=/head/; revision=153503
* Skip .symbols files.Ruslan Ermilov2005-11-111-1/+4
| | | | Notes: svn path=/head/; revision=152302