aboutsummaryrefslogtreecommitdiffstats
path: root/xen/arch/x86/bzimage.c
Commit message (Collapse)AuthorAgeFilesLines
* libelf: Check pointer references in elf_is_elfbinaryIan Jackson2013-06-141-2/+2
| | | | | | | | | | | | | | | | | | | | | | elf_is_elfbinary didn't take a length parameter and could potentially access out of range when provided with a very short image. We only need to check the size is enough for the actual dereference in elf_is_elfbinary; callers are just using it to check the magic number and do their own checks (usually via the new elf_ptrval system) before dereferencing other parts of the header. This is part of the fix to a security issue, XSA-55. Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com> Acked-by: Ian Campbell <ian.campbell@citrix.com> Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com> v7: Add a comment about the limited function of elf_is_elfbinary. v2: Style fix. Fix commit message subject.
* Fix emacs local variable block to use correct C style variable.David Vrabel2013-02-211-1/+1
| | | | | | | The emacs variable to set the C style from a local variable block is c-file-style, not c-set-style. Signed-off-by: David Vrabel <david.vrabel@citrix.com
* x86: allow Dom0 image to be compressed ELFJan Beulich2011-06-231-16/+34
| | | | | | | | | | | | Rather than being able to decompress only the payloads of bzImage containers, extend the logic to also decompress simple compressed ELF images. At once, allow uncompressed bzImage payloads. This is a prerequisite for native EFI booting support (where, in the absence of a capable secondary boot loader, the image will always be in compressed form). Signed-off-by: Jan Beulich <jbeulich@novell.com>
* Move more kernel decompression bits to .init.* sectionsJan Beulich2011-03-091-9/+10
| | | | | | | | Based on how c/s 22986:076b63b74cf6 changed xen/libelf/Makefile I suppose this is compatibile with those clang/llvm changes, but I didn't actually test it. Signed-off-by: Jan Beulich <jbeulich@novell.com>
* x86/dom0: support bzip2 and lzma compressed bzImage payloadsKeir Fraser2009-11-091-16/+36
| | | | | | | | | | | | | This matches functionality in the tools already supporting the same for DomU-s. Code taken from Linux 2.6.32-rc and adjusted as little as possible to be usable in Xen. The question is whether, particularly for non-Linux Dom0-s, plain ELF images compressed by bzip2 or lzma should also be supported. Signed-off-by: Jan Beulich <jbeulich@novell.com>
* Scattered code arrangement cleanups.Keir Fraser2009-10-071-0/+1
| | | | | | | | - remove redundant declarations - add/move prototypes to headers - move things where they belong to Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
* Panic rather than BUG if an error is encountered decompressing a bzImageKeir Fraser2009-03-061-2/+1
| | | | | | | | This gives a more useful error message without an unnecessary stack dump. Noticed by Jeremy Fitzhardinge. Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
* x86: Although bzimage_headroom() doesn't return -ve values,Keir Fraser2009-01-291-2/+2
| | | | | bzimage_parse() can. Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
* x86: bzimage_headroom does not return -ve error codes.Keir Fraser2009-01-291-1/+1
| | | | Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
* Allow memflags to be specified to alloc_xenheap_pages().Keir Fraser2009-01-281-1/+1
| | | | Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
* x86: Support booting a bzImage format domain 0 kernel.Keir Fraser2009-01-221-0/+242
This requires a bzImage v2.08 or later kernel. xen/common/inflate.c is taken unmodified from Linux v2.6.28. Signed-off-by: Ian Campbell <ian.campbell@citrix.com>