summaryrefslogtreecommitdiff
path: root/kdump
AgeCommit message (Collapse)Author
2016-06-08kdump: print mmap() offset in hexRussell King
When mmap() fails, printing a large decimal number is mostly meaningless - it's not obvious what it means. Printing a hex number is more obvious, because we can see whether it's over 32-bit, or not page aligned. Reviewed-by: Pratyush Anand <panand@redhat.com> Signed-off-by: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Simon Horman <horms@verge.net.au>
2016-06-08kdump: fix kdump mappingRussell King
When kdump tries to map the program header, it fails to take account of ehdr->e_phoff being an offset from the start of the ELF "file", which causes: Cannot mmap /dev/mem offset: 64 size: 392: Invalid argument Ensure that we take account of the start address when mapping this. This fix has been extracted from a larger patch by Vitaly Andrianov adding support for Keystone 2. Signed-off-by: Russell King <rmk@arm.linux.org.uk> Reviewed-by: Pratyush Anand <panand@redhat.com> Signed-off-by: Simon Horman <horms@verge.net.au>
2016-06-08kdump: actually write out the memoryRussell King
Actually write out the memory rather than writing the notes a second time. Reviewed-by: Pratyush Anand <panand@redhat.com> Signed-off-by: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Simon Horman <horms@verge.net.au>
2016-06-08kdump: fix multiple program header entriesRussell King
generate_new_headers() forgot to increment the program header pointer after adding each program header from the kexec template. Fix it to increment it correctly. Without this, the program headers contain only the last entry, which means we will be missing most of the kernel image in the dump. Reviewed-by: Pratyush Anand <panand@redhat.com> Signed-off-by: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Simon Horman <horms@verge.net.au>
2016-06-08kdump: mmap() and munmap() only work on page-aligned quantitesRussell King
The man page for mmap() and munmap() says that mmap() and munmap() only works for page-aligned addresses, sizes and offsets. Arrange to give these interfaces what they want. Reviewed-by: Pratyush Anand <panand@redhat.com> Signed-off-by: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Simon Horman <horms@verge.net.au>
2013-03-27kexec: Fix Makefile of linking kdump fileLi Haifeng
When make kdump object file, the expression of linking kdump ignores LDFLAGS. If someone want to build kdump with static links, it won't product object file with static attributes. So, fix it. Signed-off-by: Haifeng Li <omycle@gmail.com> Signed-off-by: Simon Horman <horms@verge.net.au>
2012-02-08Fix out-of-tree buildTyler Hall
Use automatic variables for prerequisites when copying man pages and include a makefile relative to $(srcdir). Signed-off-by: Tyler Hall <tylerwhall@gmail.com> Signed-off-by: Simon Horman <horms@verge.net.au>
2010-02-02Avoid possible overflows from signed/unsigned comparisonsSimon Horman
Signed-off-by: Simon Horman <horms@verge.net.au>
2008-05-21Use target CC and LD to build kdump and kexec_test.Jamey Sharp
Signed-off-by: Jamey Sharp <jamey@thetovacompany.com> Signed-off-by: Simon Horman <horms@verge.net.au>
2008-02-21Only include needed files in distribution tarballSimon Horman
With the recent build changes a number of unneded files crept into tarballs, including .o and .d files. This patch is farily verbose, but hopefully in the long run this system will be obvious enough to be maintainable. Signed-off-by: Simon Horman <horms@verge.net.au>
2007-12-19make clean cleanupJeremy Kerr
Use a $(clean) variable to store all items that need to be removed on 'make clean' (eg, .o files). Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Simon Horman <horms@verge.net.au> Conflicts: Makefile.in
2007-12-19Use general _SRCS and _OBJS, rather and _C_{SRCS, OBJS} and _S_{SRCS, OBJS}Jeremy Kerr
Since we use the implicit ruls for .c and .S, just colelct all sources in the one variable. Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Simon Horman <horms@verge.net.au>
2007-12-19Build system simplification/standardisationJeremy Kerr
This change makes kexec-tools work more like a standard configure-make- make-install-type project: * Remove $(OBJDIR) stuff. To do an out-of-tree build, just configure from a different directory. * Use the implicit Makefile rules more, and just edit the compiler flags for specific targets. * Simplify compiler/linker flags - no need for EXTRA_* * Add TARGET_CC, and improve checks for BUILD_CC too. * Set arch-specific flags in arch-specific makefiles, not conditional on $(ARCH). * Generate dependency files in the main compile, rather than as a separate step. * Don't #include sha256.c, but re-build it into the purgatory. Still a work-in-progress. Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Simon Horman <horms@verge.net.au>
2006-11-27kexec-tools: make sure written is initialised in write_all()Simon Horman
I noticed this because of a compiler warning, and I guess it was working as the memory that written is occupying happens to be 0. Signed-Off-By: Simon Horman <horms@verge.net.au>
2006-10-06build-cpp-and-ld-flagsSimon Horman
[BUILD] CPPFLAGS, CFLAGS and LDFLAGS fixes * Set internal CPPFLAGS as EXTRA_CPPFLAGS, CFLAGS as EXTRA_CFLAGS, and LDFLAGS as EXTRA_LDFLAGS - Don't overwrite CPPFLAGS, LDLFAGS or CFLAGS from the environment - They are irrelevant for BUILD_CC - When cross-compiling for a ppc64 host on a non-ppc64 host, EXTRA_CFLAGS, which is included in BUILD_CPPFLAGS contains -mcall-aixdesc, which does not work on i386 at least * Use LDFLAGS when linking kexec - Append rather than overwrite in purgatory/Makefile The purpose of these changes is three-fold. * CPPFLAGS, CFLAGS and LDFLAGS from the environment really ought to be honoured. For one thing; * Without these changes, the confgiure taget in the toplevel makefile can't work * Without these changes, cross compiling does not work - well, I can't work out how to get it to work anyway. Signed-Off-By: Simon Horman <horms@verge.net.au>
2006-07-27ia64 supportKhalid Aziz
This patch adds support for kexec-tools on ia64. This patch applies on top of -kdump7 patch from <http://lse.sourceforge.net/kdump/>. Signed-off-by: Khalid Aziz <khalid.aziz@hp.com> Signed-off-by: Maneesh Soni <maneesh@in.ibm.com>
2006-07-27Cleanup the warnings in gcc-4.1.0 compilationMohan
Cleanup the warnings generated in GCC 4.1.0 compilation of kexec-tools. This patch is created on top of the following level of kexec-tools: - kexec-tools-1.101.tar.gz (from eric biederman's site or from lse site) - kexec-tools-1.101-kdump6.patch (consolidated patch posted on http://lse.sourceforge.net/kdump/patches/1.101-kdump6/kexec-tools-1.101-kdump6.patch) Review and suggestions are welcome. Note: Resending the patch since its not delivered to both fastboot and linuxppc64-dev mailing list. Regards, Mohan. Signed-off-by: Mohan <mohan@in.ibm.com> Signed-off-by: Maneesh Soni <maneesh@in.ibm.com>
2006-07-27kexec-tools-1.101Eric W. Biederman
- Initial import into git - initial nbi image formage support - ppc32 initial register setting fixes. - gzipped multiboot file support