Commit Graph

553 Commits

Author SHA1 Message Date
Scott Long
05d0bf79ed Remove the last vestiges of the userconfig option. None of this actually
did anything, so this commit should be considered a NO-OP.
2004-12-01 04:59:33 +00:00
Ruslan Ermilov
ddfd677a57 Pick up loader.rc from its old home. 2004-11-29 09:31:04 +00:00
Scott Long
700f9eef96 Disable the beastie menu. It offends some and annoys everyone else, and I'm
frankly tired of the controversy.  When people ask me why FreeBSD isn't user-
friendly, I'll tell them that I tried.  RIP.
2004-11-29 01:32:10 +00:00
John Baldwin
4e38f13b5b - If the COMSPEED is set to 0, then don't try to initialize the serial port
and assume that the BIOS has set it up for us.  This allows folks with a
  serial-aware BIOS to set the BIOS to speeds above 9600 and allow boot0 to
  just use the existing settings.
- Purge some gratuitous cpp comments as per style(9).

Submitted by:	Danny Braniss danny at cs dot huji dot ac dot il (1)
MFC after:	1 month
2004-11-24 15:39:04 +00:00
John Baldwin
8b8d44db27 Fix comments for serial I/O function prototypes that were broken in the
assembler to cpp(1) comment conversions.  This allows btx to compile again
when BTX_SERIAL is defined.

Reported by:	Danny Braniss danny at cs dot huji dot ac dot il
MFC after:	1 month
2004-11-24 14:54:33 +00:00
Peter Wemm
cf0c439f9d Remove a pre-tier-1 kernel compatability helper. This means a 6.x loader
won't boot a pre-5.1 development amd64 kernel.  That's no big loss though.
2004-11-08 23:59:44 +00:00
Giorgos Keramidas
550b156641 Clean up the comments, rewording, adding missing punctuation
and other minor nits.

Approved by:	jhb
2004-11-06 06:13:13 +00:00
Ruslan Ermilov
a35d88931c For variables that are only checked with defined(), don't provide
any fake value.
2004-10-24 15:33:08 +00:00
Hidetoshi Shimokawa
6ee737aae3 Respect RB_MULTIPLE flag. 2004-10-22 14:57:28 +00:00
Hidetoshi Shimokawa
167938e1e7 - Add FireWire subclass and OHCI interface.
- Add some PCI BIOS function calls.
	(find_devclass, read_config, write_config)
2004-10-22 14:56:23 +00:00
Ruslan Ermilov
69a02bda38 Document boot_cdrom, boot_multicons, and boot_serial.
Reduce diffs between help.common and loader(8).
Mention that boot_userconfig is currently a no-op.
2004-09-30 13:09:00 +00:00
Wes Peters
ecaf63f715 Trap invalid sector size 0 in disk probe, refusing to add such a
device to the list.  This prevents crashes on /0 errors in 'lsdev'
et al.

Reviewed-by:	jhb@
MT5 after:	RE approval
2004-09-21 06:46:44 +00:00
John Baldwin
ca9b2364c3 A long, long time ago in a CVS branch far away (specifically, HEAD prior
to 4.0 and RELENG_3), the BTX mini-kernel used paging rather than flat
mode and clients were limited to a virtual address space of 16 megabytes.
Because of this limitation, boot2 silently masked all physical addresses
in any binaries it loaded so that they were always loaded into the first
16 Meg.  Since BTX no longer has this limitation (and hasn't for a long
time), remove the masking from boot2.  This allows boot2 to load kernels
larger than about 12 to 14 meg (12 for non-PAE, 14 for PAE).

Submitted by:	Sergey Lyubka devnull at uptsoft dot com
MFC after:	1 month
2004-09-18 02:07:00 +00:00
Ian Dowse
941fdb393b Add the loader side of support for preloading ELF relocatable object
format modules, which are currently only used on the amd64 platform.
This initial implementation just parses enough of the module to
allow it to extract dependencies and load all the bits into the
right place in memory, so the kernel must still do the full relocation
and linking. The details of the loaded sections are passed to the
kernel by supplying a copy of the ELF section header table as module
metadata with the MODINFOMD_SHDR tag.
2004-08-29 00:48:42 +00:00
Yaroslav Tykhiy
a30e1135b4 Don't be too smart, just try packet mode of INT13 first.
This way of operation is more robust than the "AI" used
before.

Add flags to mbr accessible from make.conf as BOOT_MBR_FLAGS.
Only one flag is defined now, "allow using packet mode", which
is 0x80 in accord with the rest of i386 boot code.  The "packet"
flag is on by default.

PR:             i386/70241
Submitted by:   Valentin Nechayev <netch <@> netch.kiev.ua> (inital version)
Discussed with: jhb (by Valentin Nechayev)
Tested on:      bochs (with EDD turned on or off by patching the BIOS), PCs
2004-08-28 08:39:35 +00:00
Yaroslav Tykhiy
57888b4c83 Try packet mode of INT13 on a hard disk first if not prohibited by
the flag, fall back to the old INT13/AH=02 function if that fails.
This way of operation is less likely to fail with modern BIOSes and
large disks of strange geometries.

PR:		i386/70241
Submitted by:	Valentin Nechayev <netch <@> netch.kiev.ua> (inital version)
Discussed with:	jhb (by Valentin Nechayev)
Tested on:	bochs (with EDD turned on or off by patching the BIOS), PCs
2004-08-28 08:32:23 +00:00
Yaroslav Tykhiy
9e4211a1b8 B1FLAGS -> BOOT_BOOT1_FLAGS, which is consistent with
naming of other boot-related make vars.
2004-08-27 15:01:56 +00:00
David E. O'Brien
8ae136ae71 In conjunction with having boot0cfg(8) default boot0 to packet mode.
Submitted by:	Tor.Egge@cvsup.no.freebsd.org
2004-08-27 00:18:03 +00:00
Alexander Kabaev
2939c8a0b9 Move boot2 BSS zeroing into btx startup code out of boot1. boot1 does not
have clear idea on boot2 BSS size and leaves portion of it not zeroed out.
btxcsu.s is in much better position for this job.

Obtained from: DragonflyBSD (with minor adjustments)
2004-08-05 06:00:05 +00:00
Alexander Kabaev
3cd25b7e7b Compile boot2 with -fno-unit-at-a-time. GCCs aggressive optimization
breaks boot in spectacular ways otherwise.
2004-07-30 04:27:20 +00:00
Alexander Kabaev
1bc32c1ffc Clean up local memcpy implementation to take void * parameters. 2004-07-30 00:33:09 +00:00
Alexander Kabaev
d9eedfd93c Define our own memcpy here instead of relying on GCC to provide one. 2004-07-28 06:03:27 +00:00
John Baldwin
becfd988a3 Update the copyright to use a 3 clause BSD license rather than one that
is less clear about allowing redistribution of modified copies.

Requested by:	Tom Cosgrove tom dot cosgrove at arches-consulting dot com
2004-06-22 21:55:22 +00:00
John Baldwin
3c077ec681 Remove a bogus increment of %di when scanning the list of loader paths.
%di will already point to the character after the nul char when the
'repnz scasb' terminates.

Submitted by:	Tom Cosgrove tom dot cosgrove at arches-consulting dot com
2004-06-22 21:52:20 +00:00
Poul-Henning Kamp
d33ccadc81 Save a couple of bytes for the SIO case. 2004-06-17 12:02:25 +00:00
Poul-Henning Kamp
ad165b6f6d Unspam sys/boot, the dev_t commit should not have touched these.
Spotted by:	peter
2004-06-16 18:21:22 +00:00
Poul-Henning Kamp
89c9c53da0 Do the dreaded s/dev_t/struct cdev */
Bump __FreeBSD_version accordingly.
2004-06-16 09:47:26 +00:00
Poul-Henning Kamp
4ee9ad6b13 Premptively fix GCC3.4 issue: add break; after empty default: clauses.
PR:	65493
Submitted by:	Pawel Worach <sajd@telia.com>
2004-06-16 08:12:06 +00:00
Poul-Henning Kamp
f89485e2b1 Merge boot0 and boot0sio so they behave the same. 2004-06-11 09:45:18 +00:00
Poul-Henning Kamp
d7d485798f Some embedded platforms have no keyboard controller. Give up waiting
for it to react after a timeout.
2004-06-02 09:38:32 +00:00
Nate Lawson
2c0d74e8e8 Use the correct location of the EBDA for searching for the RSDP.
The EBDA is the 1 KB area addressed by the 16 bit pointer at 0x40E.

Pointed out by:	robert.moore AT intel.com
2004-05-25 05:52:48 +00:00
Ruslan Ermilov
237266b2e6 Back out last revision that unnecessarily changed valid assembler
line comments and damaged the CVS history.

Prompted by:	bde, jhb
2004-05-14 20:29:30 +00:00
Ruslan Ermilov
b09ce52594 Partly back out last revision that unnecessarily changed valid
assembler line comments and damaged the CVS history.

Prompted by:	bde, jhb
2004-05-14 20:28:31 +00:00
John Polstra
15a3ddef19 Fix a potential stack buffer overflow on systems whose ACPI OEMID
fills its field (6 characters).  In that case the OEMID is not
null-terminated, and the sprintf that was used would copy up to the
next null byte, which could be pretty far away.
2004-05-14 01:29:21 +00:00
Ruslan Ermilov
3c96564d00 Convert block comments into C-style that is understood by cpp(1).
Keep line comments in assembler style.  A few lines that match
the '^[[:space:]]+#' regexp still need to be fixed, somehow.

OK'ed by:	bde, jhb
2004-04-29 18:58:38 +00:00
Ruslan Ermilov
848c1050ee Thanks to David's patches, we can now simplify these makefiles
further, and just use PROG directly (without FILES).

Suggested by:	bde
2004-04-28 21:31:21 +00:00
Ruslan Ermilov
dfca089741 Properly merge boot0sio.s and boot0.s into boot0.S. 2004-04-28 21:14:40 +00:00
Ruslan Ermilov
df1a364da7 Switch to using C99 comments in assembler preprocessed with cpp(1). 2004-04-28 20:55:01 +00:00
Ruslan Ermilov
69dd73b976 - Properly merge boot0sio.s and boot0.s into boot0.S.
boot0sio.s was repo-copied to boot0.S.

- Rename boot0ext.s to boot0ext.S, to stay consistent
  with other preprocessed asm files around here, and
  for better portability.

Repocopied by:	joe
2004-04-28 20:49:17 +00:00
Ruslan Ermilov
6886d8ff2a Temporary precaution measure until repocopy requests are
processed: don't forget to clean generated .s sources.
2004-04-28 16:16:16 +00:00
Ruslan Ermilov
edfa817773 After talking to Bruce Evans and reading more standards specs,
switch to using C99-style comments everywhere in preprocessed
assembler.  The reason is that lines starting with the regexp
'^[[:space:]]#' are treated as preprocessing directives, and
while it seems to work now with GCC, it's not necessarily has
to work.  Use C99 comments `//' for the trailing comments to
save whitespace.
2004-04-28 14:31:44 +00:00
Ruslan Ermilov
d1974eb1c5 Use C (and CPP) style comments for assembler-with-cpp sources,
for lines that start with a comment.
2004-04-28 10:09:21 +00:00
Ruslan Ermilov
4b35719adf Use C (and CPP) style comments for assembler-with-cpp sources,
for lines that start with a comment.
2004-04-28 09:57:12 +00:00
Ruslan Ermilov
37e931894e - Use C (and CPP) style comments for assembler-with-cpp sources,
for lines that start with a comment.
- Preserve as(1) style comments for the rest.
2004-04-28 09:49:22 +00:00
Ruslan Ermilov
c9be1bb2f8 Removed now redundant CLEANFILES assignments.
Not read enough of my patch by:	obrien ;)
2004-04-27 19:45:16 +00:00
Poul-Henning Kamp
f025129b8a Change from '#' to "//" comment character to allow CPP preprocessing.
Merge boot0.s and boot0sio.s into boot0_512.s controlled by "#ifdef SIO".

Add Makefile magic to generate boot0.s and boot0sio.s from boot0_512.s.

The compile boot0 and boot0sio have unchanged MD5 checksums.
2004-04-27 19:07:35 +00:00
David E. O'Brien
a606451bd2 Use a more compact syntax for passing the "binary" options to 'ld'. 2004-04-25 20:36:44 +00:00
David E. O'Brien
a50d1c0876 Simplify the building of our i386 'binary' boot components by directly
producing them using 'ld' options rather than post-processing with 'objcopy'.

Idea by:	Ryan Sommers <ryans@gamersimpact.com>
2004-04-25 19:50:20 +00:00
David E. O'Brien
d2f313a8ae Fix a last second typo in 'vi' that caused a problem. 2004-04-20 13:34:18 +00:00
David E. O'Brien
a3ab3e07c5 White space style cleanup. 2004-04-20 03:15:59 +00:00