aboutsummaryrefslogtreecommitdiff
path: root/sys/boot/common/misc.c
Commit message (Collapse)AuthorAgeFilesLines
* Move sys/boot to stand. Fix all references to new locationWarner Losh2017-11-141-219/+0
| | | | | | | Sponsored by: Netflix Notes: svn path=/head/; revision=325834
* Enable warnings in EFI boot codeSteven Hartland2016-01-121-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Set WARNS if not set for EFI boot code and fix the issues highlighted by setting it. Most components are set to WARNS level 6 with few being left at lower levels due to the amount of changes needed to fix at higher levels. Error types fixed: * Missing / invalid casts * Missing inner structs * Unused vars * Missing static for internal only funcs * Missing prototypes * Alignment changes * Use of uninitialised vars * Unknown pragma (intrinsic) * Missing types etc due to missing includes * printf formatting types Reviewed by: emaste (in part) MFC after: 2 weeks X-MFC-With: r293268 Sponsored by: Multiplay Differential Revision: https://reviews.freebsd.org/D4839 Notes: svn path=/head/; revision=293724
* In alloc_pread() and kern_pread(), print errors only when DEBUG isMarcel Moolenaar2014-11-051-0/+10
| | | | | | | | | | defined. An error is not fatal and is supposed to be handled by the caller. Obtained from: Juniper Networks, Inc. Notes: svn path=/head/; revision=274127
* Setting a variable to the same value twice doesn't actually make itColin Percival2008-08-041-1/+1
| | | | | | | | | more likely to have the right value. Remove superfluous assignments. Found by: LLVM/Clang Static Checker Notes: svn path=/head/; revision=181278
* Add a few helper functions for zeroing kernel space and readingIan Dowse2004-08-281-0/+68
| | | | | | | from specified file offsets. Make use of these in load_elf.c. Notes: svn path=/head/; revision=134441
* Use __FBSDID().David E. O'Brien2003-08-251-2/+3
| | | | | | | Also some minor style cleanups. Notes: svn path=/head/; revision=119483
* Delay calling the device cleanup routines until the absolute lastPaul Saab2000-06-141-0/+11
| | | | | | | | | moment. We were cleaning up after PXE too early and the module dependancy code would not be able to load any files if it needed too. Notes: svn path=/head/; revision=61659
* $Id$ -> $FreeBSD$Peter Wemm1999-08-281-1/+1
| | | | Notes: svn path=/head/; revision=50477
* Insert whitespace between unargv'd arguments.Mike Smith1998-10-051-3/+7
| | | | | | | Submitted by: "Louis A. Mamakos" <louie@TransSys.COM> Notes: svn path=/head/; revision=39968
* * Add old UFS compatibility code to alpha/boot1.Doug Rabson1998-09-261-2/+2
| | | | | | | | | * Fix a raft of warnings, printf and otherwise. * Allocate the correct amount in mod_searchmodule to prevent an overflow. * Fix the makefiles so they work outside my home directory (oops). Notes: svn path=/head/; revision=39673
* Add a generic hexdump tool for debugging purposes.Mike Smith1998-09-191-1/+41
| | | | Notes: svn path=/head/; revision=39472
* Bootstrap updates.Mike Smith1998-09-031-1/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Move some startup code from MD to MI sections - Add a 'copyout' and some copyout-related functions. These will be obsoleted when BTX is available for the 386 and the kernel load area becomes directly addressable. - Add the ability load an arbitrary file as a module, associating and arbitrary type string with it. This can be used eg. for loading splash-screen images etc. - Add KLD module dependancy infrastructure. We know how to look for dependancies inside KLD modules, how to resolve these dependancies and what to do if things go wrong. Only works for a.out at the moment, due to lack of an MI ELF loader. Attach KLD module information to loaded modules as metadata, but don't pass it to the kernel (it can find it itself). - Load a.out KLD modules on a page boundary. Only pad the a.out BSS for the kernel, as it may want to throw symbols away. (We might want to do this for KLD modules too.) - Allow commands to be hidden from the '?' display, to avoid cluttering it with things like 'echo'. Add 'echo'. - Bring the 'prompt' command into line with the parser syntax. - Fix the verbose 'ls'; it was using an uninitialised stack variable. - Add a '-v' flag to 'lsmod' to have it display module metadata as well (not terribly useful for the average user) - Support a 'module searchpath' for required modules. - The bootstrap file on i386 is now called 'loader' to permit the /boot directory to use that name. - Discard the old i386 pread() function, as it's replaced by arch_readin() Notes: svn path=/head/; revision=38764
* This is the new unified bootstrap, sometimes known previously as theMike Smith1998-08-211-0/+55
'three-stage' bootstrap. There are a number of caveats with the code in its current state: - The i386 bootstrap only supports booting from a floppy. - The kernel and kld do not yet know how to deal with the extended information and module summary passed in. - PnP-based autodetection and demand loading of modules is not implemented. - i386 ELF kernel loading is not ready yet. - The i386 bootstrap is loaded via an ugly blockmap. On the alpha, both net- and disk-booting (SRM console machines only) is supported. No blockmaps are used by this code. Obtained from: Parts from the NetBSD/i386 standalone bootstrap. Notes: svn path=/cvs2svn/branches/MSMITH/; revision=38465