summaryrefslogtreecommitdiffstats
path: root/sys/boot
Commit message (Collapse)AuthorAgeFilesLines
* Fix a fallout from SSP commit, and make this compile again.ru2008-06-261-2/+1
| | | | | | | | Bonus: including kern.mk just to pick kernel warning flags was an extremely bad idea anyway, because it also picked up CFLAGS (it probably wasn't the case at the time of CVS rev. 1.1, I haven't checked). Remove duplicate CWARNFLAGS from CFLAGS.
* Enable GCC stack protection (aka Propolice) for userland:ru2008-06-2518-0/+39
| | | | | | | | | | | | | | | | | | | | | - It is opt-out for now so as to give it maximum testing, but it may be turned opt-in for stable branches depending on the consensus. You can turn it off with WITHOUT_SSP. - WITHOUT_SSP was previously used to disable the build of GNU libssp. It is harmless to steal the knob as SSP symbols have been provided by libc for a long time, GNU libssp should not have been much used. - SSP is disabled in a few corners such as system bootstrap programs (sys/boot), process bootstrap code (rtld, csu) and SSP symbols themselves. - It should be safe to use -fstack-protector-all to build world, however libc will be automatically downgraded to -fstack-protector because it breaks rtld otherwise. - This option is unavailable on ia64. Enable GCC stack protection (aka Propolice) for kernel: - It is opt-out for now so as to give it maximum testing. - Do not compile your kernel with -fstack-protector-all, it won't work. Submitted by: Jeremie Le Hen <jeremie@le-hen.org>
* Implement a workaround for a long-standing problem inolli2008-06-161-8/+32
| | | | | | | | | | | | | | | | | | | | | | libi386's time(), caused by a qemu bug. The bug might be present in other BIOSes, too. qemu either does not simulate the AT RTC correctly or has a broken BIOS 1A/02 implementation, and will return an incorrect value if the RTC is read while it is being updated. The effect is worsened by the fact that qemu's INT 15/86 function ("wait" a.k.a. usleep) is non-implmeneted or broken and returns immediately, causing beastie.4th to spin in a tight loop calling the "read RTC" function millions of times, triggering the problem quickly. Therefore, we keep reading the BIOS value until we get the same result twice. This change fixes beastie.4th's countdown under qemu. Approved by: des (mentor)
* Fix the incorrect calculation of a block address within a single indirectkib2008-06-071-1/+1
| | | | | | | | block. PR: 108215 Submitted by: Yuichiro Goto, y7goto gmail com MFC after: 2 weeks
* Workaround a bug in the BIOS of Dell R900 machines. Specifically, eachjhb2008-06-071-1/+4
| | | | | | | | | | | | | entry in the SMAP is a 20 byte structure and they are queried from the BIOS via sucessive BIOS calls. Due to an apparent bug in the R900's BIOS, for some SMAP requests the BIOS overflows the 20 byte buffer trashing a few bytes of memory immediately after the SMAP structure. As a workaround, add 8 bytes of padding after the SMAP structure used in the loader for SMAP queries. PR: i386/122668 Submitted by: Mike Hibler mike flux.utah.edu, silby MFC after: 3 days
* Add an entry for the jme(4) module.yongari2008-05-271-0/+1
|
* Add an entry for the age(4) module.yongari2008-05-191-0/+1
|
* Revert the previous change and let PROBE_KEYBOARD function identical to -Pjhb2008-04-091-4/+2
| | | | in boot2/gptboot.
* Add a couple of missing wireless NIC driver modules.weongyo2008-04-081-0/+5
| | | | Approved by: thompsa (mentor)
* Add a couple of missing NIC driver modules.brueffer2008-03-281-0/+6
| | | | | Approved by: rwatson (mentor) MFC after: 3 days
* Fix some "in in" typos in comments.brueffer2008-03-262-2/+2
| | | | | | | PR: 121490 Submitted by: Anatoly Borodin <anatoly.borodin@gmail.com> Approved by: rwatson (mentor), jkoshy MFC after: 3 days
* style(9) & style.Makefile(9)obrien2008-03-1314-258/+297
| | | | Reviewed by: raj
* Improve handling U-Boot's "eth%daddr" while PowerPC metadata preparation.raj2008-03-121-3/+20
| | | | | | | | We're now more robust against cases of non-sorted and/or non-continuous numbering of those entries. Reviewed by: imp, marcel Approved by: cognet (mentor)
* Eliminate artificial increasing of 'netdev_opens' counter in loader's ↵raj2008-03-127-87/+101
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | net_open(). This was introduced as a workaround long time ago for some Alpha firmware (which is now gone), and actually prevented net_close() to ever be called. Certain firmwares (U-Boot) need local shutdown operations to be performed on a network controller upon transaction end: such platform-specific hooks are supposed to be called via netif_close() (from within net_close()). This change effectively reverts the following CVS commit: sys/boot/common/dev_net.c revision 1.7 date: 2000/05/13 15:40:46; author: dfr; state: Exp; lines: +2 -1 Only probe network settings on the first open of the network device. The alpha firmware takes a seriously long time to open the network device the first time. Also suppress excessive output while netbooting via loader, unless debugging. While there, make sys/boot/uboot more style(9) compliant. Reviewed by: imp Approved by: cognet (mentor)
* Change the BTX kernel to drop all the way out to real mode to invoke BIOSjhb2008-03-101-401/+316
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | routines (V86 requests from the client and hardware interrupt handlers): - Install trampoline real mode interrupt handlers at IDT vectors 0x20-0x2f to handle hardware interrupts by invoking the appropriate vector (0x8-0xf or 0x70-0x78). This allows the 8259As to use vectors 0x20-0x2f in real mode as well as protected mode will ensuring that the master 8259A doesn't share IDT space with CPU exceptions in protected mode. - Since we don't need to reserve space for page tables and a page directory anymore since dropping paging support, move the TSS and protected mode IDT up by 16k. Grow the ring 1 link stack by 16k as a result. - Repurpose the ring 1 link stack to be used as a real mode stack when invoking real mode routines either via a V86 request or a hardware interrupts. This simplifies a few things as we avoid disturbing the original user stack. - Add some more block comments to explain how the code interacts with the V86 structure as this wasn't immediately obvious from the prior comments (e.g. that we explicitly copy the seg regs for real mode out of the V86 struct onto the stack to be popped off when going into real mode, etc.). Also, document some of the stack frames we create going to real mode and back. - Remove all of the virtual 86 related code including having to simulate various instructions and BIOS calls on a trap from virtual 86 mode. - Explicitly panic if a user client attempts to perform a V86 CALL request that isn't a far call. - Bump version to 1.2. Assuming this works ok this should fix some of the long standing issues with USB booting as well as etherboot. MFC after: 2 weeks Submitted by: kib (some parts from his original real mode patch)
* In the PROBE_KEYBOARD case, always enable multiple consoles and set thejhb2008-03-061-2/+4
| | | | | | serial console as the primary console if the keyboard probe fails. MFC after: 1 week
* MFi386: revision 1.43nyan2008-02-291-0/+7
| | | | Do not attempt to make an NFS rpc call if using tftp
* MFi386: revision 1.55.nyan2008-02-291-4/+27
| | | | Tweak the verbose disk printing a bit.
* Tweak the verbose disk printing a bit:jhb2008-02-281-59/+51
| | | | | | | | | | | | - Consolidate the code to humanize the size of a disk partition into a single function based on the code for GPT partitions and use it for GPT partitions, BSD slices, and BSD partitions. - Teach the humanize code to use KB for small partitions (e.g. GPT boot partitions now show up as 64KB rather than 0MB). - Pad a few partition type names out so that things line up in the common case. MFC after: 1 week
* MFi386:nyan2008-02-282-57/+2
| | | | | Retire the support for using paging in BTX. It hasn't been used since before 4.0.
* Rev 1.72 fixed a bug where if /boot.config changed the console its contentsjhb2008-02-282-4/+6
| | | | | | | | | | | weren't displayed on the new console. However, the config string has been altered as part of being parsed so we only display the first option. Fix this by saving a copy of /boot.config before parsing it and displaying the saved copy after parsing. MFC after: 1 week PR: i386/103972 Submitted by: Alexandre Belloni alexandre.belloni of netasq.com
* Retire the support for using paging in BTX. It hasn't been used sincejhb2008-02-272-57/+2
| | | | | | before 4.0. Submitted by: kib
* o Build and install the U-Boot loader as ubldr.marcel2008-02-232-10/+6
| | | | | | o Don't build/install the manual pages or configuration files that are already installed by the OFW loader. o Hook the U-Boot loader to the build.
* style(9) commit.marcel2008-02-231-211/+218
|
* Setup the new bootinfo structure.marcel2008-02-231-36/+99
| | | | While here, make local function static and update copyright.
* o Keep running on U-Boot's stack.marcel2008-02-231-21/+23
| | | | | | | | | | o Disable interrupts while not running U-Boot code. We clobber registers that the U-Boot interrupt handlers assume to be fixed as per the U-Boot register usage. At this time this only applies to r14. U-Boot uses r2 now for what they used r29 for. After we restore r14 in preparation of doing the syscall, we re-enable interrupts. When we return from the syscall, we disable interrupts and restore the callee-saved r14.
* The NFS file system support is conditional upon LOADER_NFS_SUPPORT,marcel2008-02-231-1/+1
| | | | not LOADER_NET_SUPPORT.
* Add __elfN(relocation_offset). It holds the offset between the virtualmarcel2008-02-232-2/+30
| | | | | | | | | | (link) address and the physical (load) address. Ideally, the mapping between link and load addresses should be abstracted by the copyin(), copyout() and readin() functions, so that we don't have to add kluges in __elfN(loadimage)(). Then, we could also have paged virtual memory for the kernel. This can be important under EFI, where you need to allocate physical memory form the firmware if you want to work in all scenarios.
* o Include glue.hmarcel2008-02-231-12/+10
| | | | o Support multiple memory regions.
* o Build libuboot with -msoft-float like everything else.marcel2008-02-233-50/+88
| | | | | | | o Move the API prototypes to a separate header (glue.h) o Allow the platform to hint libuboot about where to look for the API signature. The uboot_address variable is expected to be defined by the platform.
* Add the appropriate license information. This file is doublemarcel2008-02-231-1/+55
| | | | | | licensed under GPL and BSD. Thanks to: raj@
* We build ficl and libofw with -msoft-float. Build the loadermarcel2008-02-231-1/+1
| | | | with -msoft-float too.
* Move the $FreeBSD$ tag in a comment as __FBSDID doesn't work.marcel2008-02-171-3/+2
|
* Hook the U-Boot library up to the build.marcel2008-02-171-0/+5
|
* MFp4 (e500):marcel2008-02-167-0/+817
| | | | | | | Add support for U-Boot. This uses the U-Boot API as developed by Rafal and which is (will be) part of U-Boot 1.3.2 and later. Credits to: raj@
* MFp4 (e500):marcel2008-02-1616-0/+1933
| | | | | | | Add support for U-Boot. This uses the U-Boot API as developed by Rafal and which is (will be) part of U-Boot 1.3.2 and later. Credits to: raj@
* Clean up PowerPC loader(8) build config.raj2008-02-112-2/+2
| | | | | | | | | | Turn off TFTP support by default: when both TFTP and NFS are enabled in the loader, strange interactions occur in the pure netbooting scenario (i.e. loader is TFTP-ed, kernel+world mounted over NFS), leading to very slow access to the NFS-exported files. Reviewed by: grehan Approved by: cognet (mentor)
* Make the openfirmware getchar entry point non-blocking. This catches upgrehan2008-02-061-4/+4
| | | | | | with jhb's 2005/05/27 loader multiple-console change. Tested by: marius/sparc64, grehan/ofwppc
* Bump manpage date for rev 1.27keramida2008-01-161-1/+1
| | | | MFC after: 3 days
* Document that loader(8) stops reading `loader.conf' when itkeramida2008-01-161-0/+10
| | | | | | | | encounters a syntax error, and add a tip about adding first the `vital' options and then experimental ones. PR: docs/119658 Submitted by: Julian Stacey, jhs at berklix.org
* "FreeBSD/Open Firmware/PowerPC ..." is confusing and non-standard.marcel2007-12-261-1/+1
| | | | Use "FreeBSD/powerpc Open Firmware ..." instead.
* - remove code from oroginal file, which is not required on BWCT boardsticso2007-12-231-52/+86
| | | | | | | - Be more chatty on startup, since we have enough code space on AT91RM9200 - init DS1672 charging - init USART GPIO
* BWCT boards uses two different SPI flash chipsticso2007-12-231-2/+3
| | | | check for both status codes
* Allow negative values to be specified in the loader.ambrisko2007-12-191-0/+2
|
* Remove file after being repocopied to ../ofw, where it lives on.marcel2007-12-177-749/+0
| | | | Repocopy by: simon@
* Build the OFW loader from its new location after the sourcesmarcel2007-12-171-1/+1
| | | | were repocopied from ./loader to ./ofw.
* Add a note to indicate that these files do borrow in part from mbr.s andjhb2007-11-262-0/+4
| | | | | | boot1.S Requested by: rnordier
* MFi386: revision 1.18nyan2007-11-181-1/+1
| | | | | Add a trailing \0 to the read error string so that read errors don't print out two error messages.
* Add a trailing \0 to the read error string so that read errors don't printjhb2007-11-171-1/+1
| | | | | | out two error messages. MFC after: 3 days
* Though we are currently not interested in the EDD3 flag,bz2007-11-121-1/+1
| | | | | | | Enhanced Disk Drive Specification Ver 3.0 defines that the version of extension in AH would be 30h. Correct the check for that to be >=30h instead of >3h. MFC after: 2 months
OpenPOWER on IntegriCloud