aboutsummaryrefslogtreecommitdiff
path: root/sys/boot
Commit message (Collapse)AuthorAgeFilesLines
* Add a missing prototypeBrian Somers2010-06-201-0/+1
| | | | | | | | | PR: 145232 Submitted by: gcooper MFC after: 1 week Notes: svn path=/head/; revision=209361
* Pass the -N flag to linked via -Wl.Roman Divacky2010-06-141-1/+1
| | | | | | | Approved by: ed (mentor) Notes: svn path=/head/; revision=209162
* Fix conditional FDT support in loader(8).Rafal Jaworowski2010-06-133-2/+8
| | | | Notes: svn path=/head/; revision=209125
* Use -Wl,-N instead of the undocumented -N option for GCC.Ed Schouten2010-06-0312-12/+12
| | | | | | | | | | GCC forwards the -N flag directly to ld. This flag is not documented and not supported by (for example) Clang. Just use -Wl,-N. Submitted by: Pawel Worach Notes: svn path=/head/; revision=208789
* zfs boot: fix error handling in zfs_readdirAndriy Gapon2010-05-311-0/+2
| | | | | | | | Found by: clang static analyzer MFC after: 4 days Notes: svn path=/head/; revision=208669
* boot/zfs: fix gang block reading codeAndriy Gapon2010-05-281-4/+8
| | | | | | | | | | | | - use correct size (512) while reading a gang block - skip holes while reading child blocks - advance buffer pointer while reading child blocks PR: 144214 MFC after: 10 days Notes: svn path=/head/; revision=208610
* Initial device tree source (DTS) files for Marvell ARM systems:Rafal Jaworowski2010-05-267-0/+1487
| | | | | | | | | | | | | | | | | o DB-88F5182 o DB-88F5281 o DB-88F6281 o DB-78100 o SheevaPlug This also includes device tree bindings definitions for some newly introduced nodes (mpp, gpio). Reviewed by: imp Sponsored by: The FreeBSD Foundation Notes: svn path=/head/; revision=208561
* Import device tree source (DTS) files for PowerPC MPC8555CDS and MPC8572DSRafal Jaworowski2010-05-262-0/+1337
| | | | | | | | | | | | development systems. Special thanks to Phil Brownfield for help with BSD-style relicensing of these files. Obtained from: Freescale Notes: svn path=/head/; revision=208560
* Bring a missing FDT piece (omitted in the previous commit).Rafal Jaworowski2010-05-251-0/+4
| | | | Notes: svn path=/head/; revision=208539
* Initial loader(8) support for Flattened Device Tree.Rafal Jaworowski2010-05-259-13/+1407
| | | | | | | | | | | | | o This is disabled by default for now, and can be enabled using WITH_FDT at build time. o Tested with ARM and PowerPC. Reviewed by: imp Sponsored by: The FreeBSD Foundation Notes: svn path=/head/; revision=208538
* Mostly revert r200691. U-Boot syscall() entry point returns 1 on success.Rafal Jaworowski2010-05-251-1/+1
| | | | Notes: svn path=/head/; revision=208535
* Use loader devices only when they initialized properly.Rafal Jaworowski2010-05-252-9/+11
| | | | Notes: svn path=/head/; revision=208534
* - Set 'dmadat' earlier so that we properly setup the heap if we fail toJohn Baldwin2010-05-211-4/+6
| | | | | | | | | | | | locate a high memory area for the heap using the SMAP. - Read the number of hard drive devices from the BIOS instead of hardcoding a limit of 128. Some BIOSes duplicate disk devices once you get beyond the maximum drive number. MFC after: 1 month Notes: svn path=/head/; revision=208388
* mdoc: move CAVEATS, BUGS and SECURITY CONSIDERATIONS sections to theUlrich Spörlein2010-05-131-8/+8
| | | | | | | | | | | | | | bottom of the manpages and order them consistently. GNU groff doesn't care about the ordering, and doesn't even mention CAVEATS and SECURITY CONSIDERATIONS as common sections and where to put them. Found by: mdocml lint run Reviewed by: ru Notes: svn path=/head/; revision=208027
* Formatting nitWarner Losh2010-05-101-1/+2
| | | | Notes: svn path=/head/; revision=207854
* Remove if_ar, if_ray, if_sr, if_ppp, if_sl to reflect the current modulesXin LI2010-05-041-6/+2
| | | | | | | | | | | available, they were removed due to NEEDSGIANT. While I'm there, add if_et which was missed quite a while ago. MFC after: 2 weeks Notes: svn path=/head/; revision=207630
* Add support for SPARC64 V (and where it already makes sense for otherMarius Strobl2010-05-021-2/+6
| | | | | | | | | | | | HAL/Fujitsu) CPUs. For the most part this consists of fleshing out the MMU and cache handling, it doesn't add pmap optimizations possible with these CPU, yet, though. With these changes FreeBSD runs stable on Fujitsu Siemens PRIMEPOWER 250 and likely also other models based on SPARC64 V like 450, 650 and 850. Thanks go to Michael Moll for providing access to a PRIMEPOWER 250. Notes: svn path=/head/; revision=207537
* Add driver for Silicon Integrated Systems SiS190/191 Fast/Gigabit Ethernet.Pyun YongHyeon2010-04-141-0/+1
| | | | | | | | | | | | | | | | | | | | This driver was written by Alexander Pohoyda and greatly enhanced by Nikolay Denev. I don't have these hardwares but this driver was tested by Nikolay Denev and xclin. Because SiS didn't release data sheet for this controller, programming information came from Linux driver and OpenSolaris. Unlike other open source driver for SiS190/191, sge(4) takes full advantage of TX/RX checksum offloading and does not require additional copy operation in RX handler. The controller seems to have advanced offloading features like VLAN hardware tag insertion/stripping, TCP segmentation offload(TSO) as well as jumbo frame support but these features are not available yet. Special thanks to xclin <xclin<> cs dot nctu dot edu dot tw> who sent fix for receiving VLAN oversized frames. Notes: svn path=/head/; revision=206625
* Add a copyright.Rui Paulo2010-04-071-0/+26
| | | | Notes: svn path=/head/; revision=206378
* EFI boot loader for FreeBSD/i386.Rui Paulo2010-04-0715-0/+1663
| | | | | | | | Doesn't boot a kernel yet, but it can read an ELF file from the EFI FAT partition. Notes: svn path=/head/; revision=206376
* Our boot loader is capable of booting both i386 and amd64 kernels soXin LI2010-03-263-3/+3
| | | | | | | | | | call it "x86" instead of "i386". Suggested by: jhb in response to Alexander Best's loader proposal MFC after: 1 month Notes: svn path=/head/; revision=205662
* BWCT boards can have 128MB SDRAM.Bernd Walter2010-03-092-2/+6
| | | | Notes: svn path=/head/; revision=204900
* fix signed warningBernd Walter2010-03-091-1/+1
| | | | Notes: svn path=/head/; revision=204899
* Add bwn(4) driver.Weongyo Jeong2010-02-251-0/+1
| | | | Notes: svn path=/head/; revision=204328
* Minor style correction.Rafal Jaworowski2010-02-251-1/+1
| | | | Notes: svn path=/head/; revision=204318
* Fix handling of GPT disk partition index.Rafal Jaworowski2010-02-251-0/+8
| | | | | | | | Obtained from: Semihalf MFC after: 1 week Notes: svn path=/head/; revision=204317
* Let loader(8) for U-Boot use default storage more flexibly.Rafal Jaworowski2010-02-251-7/+18
| | | | | | | | Obtained from: Semihalf MFC after: 1 week Notes: svn path=/head/; revision=204316
* Enable U-Boot storage for PowerPC. While there fix loader(8) help file name.Rafal Jaworowski2010-02-252-5/+5
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=204315
* Some machines can not only consist of CPUs running at different speedsMarius Strobl2010-02-201-1/+1
| | | | | | | | | | | | but also of different types, f.e. Sun Fire V890 can be equipped with a mix of UltraSPARC IV and IV+ CPUs, requiring different MMU initialization and different workarounds for model specific errata. Therefore move the CPU implementation number from a global variable to the per-CPU data. Functions which are called before the latter is available are passed the implementation number as a parameter now. Notes: svn path=/head/; revision=204152
* Enable NETIF_OPEN_CLOSE_ONCE on PowerPC OFW. This fixes netbooting onNathan Whitehorn2010-02-201-0/+5
| | | | | | | | | | PowerPC Book-S hardware, which had been broken for a very long time. Submitted by: Andreas Tobler MFC after: 1 week Notes: svn path=/head/; revision=204129
* Update comment. We also look for GPT partitions.Pawel Jakub Dawidek2010-02-181-1/+1
| | | | Notes: svn path=/head/; revision=204067
* Correct the panic strings introduced in r203830 to match their arguments.Marius Strobl2010-02-131-4/+4
| | | | Notes: svn path=/head/; revision=203831
* Use the SUNW,{d,i}tlb-load methods for entering locked TLB entries likeMarius Strobl2010-02-131-48/+26
| | | | | | | | | | | | | OpenBSD and OpenSolaris do instead of fiddling with the MMUs ourselves. Unlike direct access the firmware methods don't automatically use the next free (?) TLB slot, instead the slot to be used has to be specified. We allocate the TLB slots for the kernel top-down as OpenSolaris suggests that the firmware will always allocate the ones for its own use bottom-up. Besides being simpler, according to OpenBSD using the firmware methods is required to allow booting on Sun Fire E10K with multi-systemboard domains. Notes: svn path=/head/; revision=203830
* - Assert that HEAPSZ is a multiple of PAGE_SIZE as at least the firmwareMarius Strobl2010-02-131-34/+115
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of Sun Fire V1280 doesn't round up the size itself but instead lets claiming of non page-sized amounts of memory fail. - Change parameters and variables related to the TLB slots to unsigned which is more appropriate. - Search the whole OFW device tree instead of only the children of the root nexus device for the BSP as starting with UltraSPARC IV the 'cpu' nodes hang off of from 'cmp' (chip multi-threading processor) or 'core' or combinations thereof. Also in large UltraSPARC III based machines the 'cpu' nodes hang off of 'ssm' (scalable shared memory) nodes which group snooping-coherency domains together instead of directly from the nexus. - Add support for UltraSPARC IV and IV+ BSPs. Due to the fact that these are multi-core each CPU has two Fireplane config registers and thus the module/target ID has to be determined differently so the one specific to a certain core is used. Similarly, starting with UltraSPARC IV the individual cores use a different property in the OFW device tree to indicate the CPU/core ID as it no longer is in coincidence with the shared slot/socket ID. While at it additionally distinguish between CPUs with Fireplane and JBus interconnects as these also use slightly different sizes for the JBus/agent/module/target IDs. - Check the return value of init_heap(). This requires moving it after cons_probe() so we can panic when appropriate. This should be fine as the PowerPC OFW loader uses that order for quite some time now. Notes: svn path=/head/; revision=203829
* Add command-line option -dev to set the default value of the currdevMarcel Moolenaar2010-01-182-14/+58
| | | | | | | | | | variable. This is to be used by the EFI boot manager. While here, re-factor the code a little bit and bump the version to 2.1. Notes: svn path=/head/; revision=202552
* Add gmountver, disk mount verification GEOM class.Edward Tomasz Napierala2010-01-161-0/+1
| | | | | | | | | | | Note that due to e.g. write throttling ('wdrain'), it can stall all the disk I/O instead of just the device it's configured for. Using it for removable media is therefore not a good idea. Reviewed by: pjd (earlier version) Notes: svn path=/head/; revision=202437
* Replace the static NGROUPS=NGROUPS_MAX+1=1024 with a dynamicBrooks Davis2010-01-121-0/+1
| | | | | | | | | | | kern.ngroups+1. kern.ngroups can range from NGROUPS_MAX=1023 to INT_MAX-1. Given that the Windows group limit is 1024, this range should be sufficient for most applications. MFC after: 1 month Notes: svn path=/head/; revision=202143
* Remove debugging printf(). There's no need to print the imageMarcel Moolenaar2010-01-101-2/+0
| | | | | | | base address anymore. Notes: svn path=/head/; revision=201966
* Remove file system support based on the simple file system protocolMarcel Moolenaar2010-01-097-449/+276
| | | | | | | | | | | | | | | | | | | | | | | | | | as this only allows us to access file systems that EFI knows about. With a loader that can only use EFI-supported file systems, we're forced to put /boot on the EFI system partition. This is suboptimal in the following ways: 1. With /boot a symlink to /efi/boot, mergemaster complains about the mismatch and there's no quick solution. 2. The EFI loader can only boot a single version of FreeBSD. There's no way to install multiple versions of FreeBSD and select one at the loader prompt. 3. ZFS maintains /boot/zfs/zpool.cache and with /boot a symlink we end up with the file on a MSDOS file system. ZFS does not have proper handling of file systems that are under Giant. Implement a disk device based on the block I/O protocol instead and pull in file system code from libstand. The disk devices are really the partitions that EFI knows about. This change is backward compatible. MFC after: 1 week Notes: svn path=/head/; revision=201941
* - Add code allowing a network device to only be open and closed onceMarius Strobl2010-01-092-10/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | by keeping it opened after the first open and closing it via the cleanup handler when NETIF_OPEN_CLOSE_ONCE is defined in order to avoid the open-close-dance on every file access which with firmware that for example performs an auto-negotiation on every open causes netbooting to take horribly long. Basically the behavior with this knob enabled resembles the one employed between r60506 and r177108 (and for sparc64 also again since r182919) with the addition that the network device now is closed eventually before entering the kernel and before rebooting. Actually I think this should be the desired MI behavior, however the U-Boot loader actually requires net_close() to be called after every transaction in order for some local shutdown operations to be performed (and which I think thus will break on concurrent opens, i.e. when netdev_opens is > 1, like the loader does at least for disks when LOADER_GZIP_SUPPORT is enabled). - Use NETIF_OPEN_CLOSE_ONCE to replace the hack, which artificially increased netdev_opens for sparc64 in order to keep the network device opened forever, as at least some firmware versions require the network device to be closed eventually before entering the kernel or otherwise will DMA received packets to stale memory. The powerpc OFW loader probably wants NETIF_OPEN_CLOSE_ONCE to be set as well for the same reasons. Notes: svn path=/head/; revision=201932
* Remove clause 3 and 4 from TNF licenses (this was the only 4-clause TNFMarius Strobl2010-01-091-10/+1
| | | | | | | | | license FreeBSD had in sys/boot). Obtained from: NetBSD Notes: svn path=/head/; revision=201901
* Space cleanup for revision 201689 committed separately for easier review.Xin LI2010-01-061-35/+35
| | | | | | | | | | | This commit is purely space changes. Submitted by: Matt Reimer Sponsored by: VPOP Technologies, Inc. MFC after: 2 weeks Notes: svn path=/head/; revision=201690
* Instead of assuming all vdevs are healthy, check the newest vdev labelXin LI2010-01-061-22/+66
| | | | | | | | | | | | for each vdev's status. Booting from a degraded vdev should now be more robust. Submitted by: Matt Reimer <mattjreimer at gmail.com> Sponsored by: VPOP Technologies, Inc. MFC after: 2 weeks Notes: svn path=/head/; revision=201689
* Fix typo: s/partion/partition/Martin Blapp2010-01-021-1/+1
| | | | | | | | Submitted by: Marc Balmer <marc@msys.ch> MFC after: 3 days Notes: svn path=/head/; revision=201399
* Reimplement the boot2 for pc98 completely.Yoshihiro Takahashi2009-12-3122-4590/+1335
| | | | | | | | | | | | | | | | | | | It's based on the newest i386's one and has the advantage of: - ELF binary support. - UFS2 filesystem support. - Many FreeBSD slices support on a disk. Tested by: SATOU Tomokazu ( tomo1770 _ maple _ ocn _ ne _ jp ), WATANABE Kazuhiro ( CQG00620 _ nifty _ ne _ jp ) and nyan MFC after: 2 week Happy New Year in Japan!! Notes: svn path=/head/; revision=201342
* Don't use 15M-16M area on pc98. It's reserved for some devices.Yoshihiro Takahashi2009-12-312-1/+20
| | | | | | | MFC after: 2 week Notes: svn path=/head/; revision=201340
* Add setting machine type support to the loader.Yoshihiro Takahashi2009-12-314-1/+112
| | | | | | | MFC after: 2 week Notes: svn path=/head/; revision=201339
* (S)LIST_HEAD_INITIALIZER takes a (S)LIST_HEAD as an argument.Antoine Brodin2009-12-281-1/+1
| | | | | | | | | | | | Fix some wrong usages. Note: this does not affect generated binaries as this argument is not used. PR: 137213 Submitted by: Eygene Ryabinkin (initial version) MFC after: 1 month Notes: svn path=/head/; revision=201145
* Execute the cleanup handlers before jumping to the kernel justMarius Strobl2009-12-241-0/+2
| | | | | | | like the other architectures do. Notes: svn path=/head/; revision=200946
* - Consistently wrap debugging in NETIF_DEBUG. This basically mergesMarius Strobl2009-12-241-6/+22
| | | | | | | | NetBSD rev 1.19. - Make the functions match their prototypes regarding static. Notes: svn path=/head/; revision=200945