Commit Graph

7179 Commits

Author SHA1 Message Date
Axel Dörfler
8d35b1a200 platform_start_kernel() now prints out the kernel entry point instead of
the address of the kernel_args structure.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7285 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 11:11:45 +00:00
Axel Dörfler
4eedc697c3 platform_get_boot_partition() will now also get the boot device as parameter.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7284 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 11:10:32 +00:00
Axel Dörfler
4c03f90f63 Now correctly translates the partition block offset into a byte offset.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7283 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 11:09:33 +00:00
Axel Dörfler
42033342bc Added kernel_args heap functions.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7282 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 02:33:07 +00:00
Axel Dörfler
fbe5e77d0b Added a simple second heap that will survive the switch to the kernel.
elf_load_image() now uses this heap for the preloaded_image structures.
Moved gKernelArgs and gKernelEntry to different files.
Improved enabling debug output (it can now be activated by a makefile, too)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7281 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 02:32:36 +00:00
Axel Dörfler
d8023a2fc5 Fills in the required kernel args for the loaded kernel image.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7280 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 01:34:47 +00:00
Axel Dörfler
6ef64f7451 elf_load_image() now also saves the size of the dynamic section.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7279 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 01:33:44 +00:00
Axel Dörfler
840ed4b067 Added a dummy member of the platform_kernel_args structure: obviously, the
kernel didn't count an empty structure, while the boot loader reserved
4 bytes for it - dunno why, a _PACKED everywhere didn't help; it's probably
a compile option issue.
To be on the safe side always, I've now added this dummy.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7278 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 01:32:44 +00:00
Axel Dörfler
95bd98d938 Fixed addr_range structure: struct name didn't match typedef name, now uses
addr_t for the address base/size instead of (the non-portable) uint32.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7277 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 01:29:55 +00:00
Axel Dörfler
8af4cf5fba Replaced addr with addr_t.
Some minor other cleanups.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7276 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 01:28:40 +00:00
Axel Dörfler
d9194b620b We also need the size of the dynamic section.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7275 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 01:27:02 +00:00
Axel Dörfler
185df3d6bd Added a comment about why we are copying the passed in kernel args.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7274 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 01:25:23 +00:00
Matthew Wilber
85eea08ac9 decreased whitespace between files, modified error message text
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7273 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 00:35:57 +00:00
Matthew Wilber
e2ed67d283 removed debugger call
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7272 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 00:08:28 +00:00
Matthew Wilber
1c47da1361 Initial check in for pnginfo, command line program for displaying info about PNG image files
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7271 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 00:05:21 +00:00
Axel Dörfler
822757438d No longer uses the local ka at 0x100000 but the global gKernelArgs structure.
The virtual/physical allocated ranges are now correctly filled in mmu_init_for_kernel(),
and no longer too early.
Now allocates a kernel stack of 8192 bytes.
Added some temporary fillers for the kernel args.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7270 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 00:04:37 +00:00
Matthew Wilber
7678994136 Added pnginfo tool
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7269 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-21 00:03:34 +00:00
Axel Dörfler
ffcff6e28c Added platform_start_kernel() function.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7268 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 23:52:17 +00:00
Axel Dörfler
c93599a8ae Replaced addr with addr_t.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7267 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 23:47:52 +00:00
Axel Dörfler
7b1a988f65 Fixed a warning due to the change in elf_priv.h
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7266 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 23:46:39 +00:00
Axel Dörfler
50f3983035 Added gKernelEntry variable; it's now set in load_kernel().
Removed start_kernel() function - it's now replaced by the platform_start_kernel()
call.
Fixed the kernel add-on boot module search path.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7265 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 23:45:32 +00:00
Axel Dörfler
deb0d0de8a Added platform_start_kernel() prototype.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7264 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 23:41:38 +00:00
Axel Dörfler
85429b59c0 Added definition for the gKernelEntry variable.
Updated the license; it doesn't contain a single line of the former stage2.h
anymore, and we don't have to blame Travis for it :)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7263 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 23:40:57 +00:00
Axel Dörfler
62dbb799d5 Replaced addr with addr_t.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7262 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 23:38:07 +00:00
Axel Dörfler
e1a6f46dc9 Removed ktypes.h dependency; replaced "addr" with "addr_t", some other minor cleanup.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7261 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 23:37:00 +00:00
Matthew Wilber
9f33f8e014 Disabled support for grayscale images with bit depths less than 8. This is because libpng does not support these images when it does gray to RGB conversion. Will need to enhance libpng or add workarounds to PNGTranslator to fix this issue.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7260 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 19:59:10 +00:00
Jérôme Duval
da766ff5ee Should fix a crash when canceling image selection with an empty image list.
Thanks to murai for this one


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7259 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 07:21:18 +00:00
Michael Phipps
775cef0314 Final changes for ScreenSaver Preferences app
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7258 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 02:06:39 +00:00
Michael Phipps
048f424d11 Last round of functionality changes.
"Add" and "test" now work. Be warned - without the input server addon running (and maybe even with), testing will cause the ScreenSaver to run but not to turn off. The way out of this is to alt-f# to a different workspace and kill "OpenBeOS ScreenSaver".

As far as I know, all functionality now in place and working properly. Needs a good workout.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7257 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 02:05:24 +00:00
Axel Dörfler
730036e22e Improved debug output.
start_kernel() now panics, so that we don't run through (since it doesn't
actually jump to the kernel yet).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7256 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 01:36:12 +00:00
Axel Dörfler
f7fced6cf5 Slightly improved debug output.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7255 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 01:34:21 +00:00
Axel Dörfler
276c009500 Moved the platform region and heap functions to mmu.cpp.
The heap will now no longer be mapped in kernel space, but will be placed
at a fixed address (0x110000 - former start of free physical memory).
platform_allocate_region() is now implemented and calls mmu_allocate().
mmu_allocate() now supports mapping to a predefined virtual address
to be able to load the kernel correctly (and only for that).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7254 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 01:31:20 +00:00
Axel Dörfler
0f87a64b54 Add support for the boot partition offset as provided by the BFS boot block.
Now, platform_get_boot_partition() will work correctly.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7253 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 01:26:56 +00:00
Axel Dörfler
cdc8d6b6f5 The source files may now include the boot/partitions.h header.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7252 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 01:21:42 +00:00
Axel Dörfler
c8baeaf6cf Added support for the boot partition offset as provided by the BFS boot block.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7251 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-20 01:20:43 +00:00
Axel Dörfler
9fd7586724 gBootDriveID is now uint8, no longer uint16.
Now prints out a comment if LBA access doesn't work (since CHS access is not yet implemented).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7250 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 23:33:23 +00:00
Axel Dörfler
f52302c408 Actually, one byte is enough for gBIOSDriveID - it only has to store %dl, not %dx.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7249 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 23:31:53 +00:00
Axel Dörfler
502a70f884 Implemented LBA drive access using the BIOS. The boot device is correctly
published, and can be accessed as needed.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7248 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 23:14:05 +00:00
Axel Dörfler
7ca2763dc3 Now uses the kExtraSegmentScratch constant rather than a direct address.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7247 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 22:43:04 +00:00
Axel Dörfler
cc551468f8 Added some constants that define scratch buffers in the data and extra
segment that can be used for BIOS calls.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7246 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 22:38:30 +00:00
Axel Dörfler
6ed14d8c59 Added a global variable gBootDriveID where %dl is stored to.
Moved the data section closer to the end of the 1024 bytes of the boot
block - the region before is reused as scratch buffer in the real mode
data segment.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7245 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 22:36:13 +00:00
Axel Dörfler
c2cb9079b5 Fixed a warning with debug turned on.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7244 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 21:58:43 +00:00
Axel Dörfler
acfef65c84 Fixed a bug that would rescan the boot partition in mount_file_systems() in
case it couldn't be used for booting (lack of a kernel or whatever).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7243 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 21:57:50 +00:00
Rudolf Cornelissen
ccfb6b3711 more logging, removed paneldetection bug
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7242 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 13:57:31 +00:00
Axel Dörfler
a7226c0a48 The boot loader now uses the boot_loader.ld linking script instead of
the stage2.ld script (which is now only used by the old boot mechanism).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7241 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 02:23:50 +00:00
Axel Dörfler
3796dbef26 Added the new files to the build, and implemented a real startup.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7240 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 01:57:29 +00:00
Axel Dörfler
b2f8da6214 Added prototype for the (currently unused) mmu_init_for_kernel() function.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7239 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 01:56:36 +00:00
Axel Dörfler
95aa3fbf11 MMU functions and initialization for the boot loader.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7238 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 01:50:26 +00:00
Axel Dörfler
487cc516ec Register %es was not properly set from the bios_regs structure
(since switch_to_real_mode() overwrites %es).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7237 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 01:31:19 +00:00
Axel Dörfler
65daec27d1 Added a definition for the carry flag.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7236 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-04-19 01:30:13 +00:00