#
04be20a7 |
|
01-May-2021 |
Jérôme Duval <jerome.duval@gmail.com> |
Implement stack protection support this adds kernel & libroot stack protector hooks. it uses /dev/random in userspace. A configure option --enable-stack-protector is added to activate -fstack-protector on selected system components (ATM apps, kits, servers). Change-Id: If3a2920ba9aa0a85eaff4ba6778947f8c76ade31 Reviewed-on: https://review.haiku-os.org/c/haiku/+/3895 Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
|
#
2555f335 |
|
14-May-2020 |
Michael Lotz <mmlr@mlotz.ch> |
Cleanup: Various comment and whitespace fixes. Change-Id: I37c3e3346813efc595df651421b7e8ff4fbf3339 Reviewed-on: https://review.haiku-os.org/c/haiku/+/2845 Reviewed-by: waddlesplash <waddlesplash@gmail.com>
|
#
56bb1bd5 |
|
20-Feb-2020 |
Jérôme Duval <jerome.duval@gmail.com> |
kernel: load cpu microcode update if loaded by the bootloader add optional fields for microcode in kernel_args. Change-Id: Ic5fb54cf6c9f489a2d1cdda00f63980c11dcdaeb Reviewed-on: https://review.haiku-os.org/c/haiku/+/2264 Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
|
#
f111c8c6 |
|
11-Jan-2020 |
Axel Dörfler <axeld@pinc-software.de> |
kernel: Add debug level to welcome message
|
#
db9b70ee |
|
07-May-2018 |
Jérôme Duval <jerome.duval@gmail.com> |
kernel: add a compatibility commpage on x86_64. * x86 uses a commpage with 32-bit addresses, incompatible with the one used for x86_64. For this reason, a compatibility commpage is needed to support a 32-bit userland on x86_64. * define ADDRESS_TYPE as a macro for addr_t (default) or uint32 (for the 32-bit commpage). * team_create_thread_start_internal() will use clone_commpage_area() with KERNEL_USER_DATA_BASE or clone_commpage_compat_area() with KERNEL_USER32_DATA_BASE, to setup the correct commpage. * real_time_clock (in compatibility mode) also updates the compatibility commpage with real time data. Change-Id: I61605077ce0beabab4439ef54edd1eae26f26fd2
|
#
89168ad8 |
|
15-Apr-2015 |
Axel Dörfler <axeld@pinc-software.de> |
Boot the system via launch_daemon. * This is actually working already, although we cannot reproduce all the features of the former Bootscript yet. This is without any dependency support in launch_daemon. * All shell activity like cleaning out /tmp, setting up the environment, setting the time, etc. is not yet working.
|
#
035e3e77 |
|
15-Apr-2015 |
Axel Dörfler <axeld@pinc-software.de> |
kernel: profile system when SYSTEM_PROFILER is defined. * This enables a mechanism to profile almost the complete boot process (starting with main2()), if SYSTEM_PROFILER is defined to 1. * You can access the profiling data using "profile -r".
|
#
6a2fd3a5 |
|
03-Apr-2014 |
Jonathan Schleifer <js@webkeks.org> |
Add __dso_handle to bootloader and kernel Clang references these when building for x86_64.
|
#
52b442a6 |
|
05-Dec-2013 |
Pawel Dziepak <pdziepak@quarnos.org> |
kernel: smp_cpu_rendezvous(): Use counter instead of bitmap
|
#
7db89e8d |
|
25-Nov-2013 |
Pawel Dziepak <pdziepak@quarnos.org> |
kernel: Rework cpuidle module * Create new interface for cpuidle modules (similar to the cpufreq interface) * Generic cpuidle module is no longer needed * Fix and update Intel C-State module
|
#
343c4896 |
|
20-Oct-2013 |
Pawel Dziepak <pdziepak@quarnos.org> |
kernel: Create CPU topology tree
|
#
824ed26c |
|
16-Oct-2013 |
Pawel Dziepak <pdziepak@quarnos.org> |
kernel: Fully detect CPU topology before initializing scheduler
|
#
de49e349 |
|
04-Oct-2013 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Add symbol versioning for find_directory() Should already have been done back when the semantics for the B_COMMON_*DIRECTORY constants was changed. Currently old and new version behave the same. So this is just a contingency measure ATM.
|
#
b8a9a3a1 |
|
26-Jun-2012 |
Alex Smith <alex@alex-smith.me.uk> |
Copied the x86 debug console functions to x86_64. Note that this is only temporary so that I have serial output from the kernel, the x86 and x86_64 versions will be merged later.
|
#
e5fc2bfc |
|
26-Jun-2012 |
Alex Smith <alex@alex-smith.me.uk> |
Implemented long mode setup/switch code, the bootloader can now start the 64-bit kernel! The setup procedure is fairly simple: create a 64-bit GDT and 64-bit page tables that include all kernel mappings from the 32-bit address space, but at the correct 64-bit address, then go through kernel_args and changes all virtual addresses to 64-bit addresses, and finally switch to long mode and jump to the kernel.
|
#
0e88a887 |
|
13-Jun-2012 |
Alex Smith <alex@alex-smith.me.uk> |
First round of 64-bit safety fixes in the kernel. * Most of this is incorrect printf format strings. Changed all strings causing errors to use the B_PRI* format string definitions, which means the strings should be correct across all platforms. * Some other fixes for errors, casts required, etc.
|
#
323b6546 |
|
21-Nov-2011 |
Oliver Tappe <zooey@hirschkaefer.de> |
Filtered flat import of Oliver's svn package management branch Bring the changes that aren't package management related and the ones that are but don't take effect as long as they are ignored by the build system into the master. Summary of changes: * Introduce private header <directories.h> with constants for a good deal of paths that should usually be retrieved via find_directory(). * Replace hard-coded paths by using find_directory() or the <directories.h> constants (e.g. in drivers and the kernel). * Add find_directory() constants needed for package management. * Add __HAIKU_ABI_NAME and B_HAIKU_ABI_NAME macros. * src/apps/deskbar: BeMenu.* -> DeskbarMenu.*, DeskBarUtils.* -> DeskbarUtils.* * Change deskbar menu settings directory from ~/config/be to ~/config/settings/deskbar. * Other smaller cleanups, changes, and fixes.
|
#
3dfd9cb9 |
|
16-Jun-2011 |
Oliver Tappe <zooey@hirschkaefer.de> |
Flat commit of all changes from package-management branch in svn
|
#
24df6592 |
|
11-Jun-2011 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Merged signals-merge branch into trunk with the following changes: * Reorganized the kernel locking related to threads and teams. * We now discriminate correctly between process and thread signals. Signal handlers have been moved to teams. Fixes #5679. * Implemented real-time signal support, including signal queuing, SA_SIGINFO support, sigqueue(), sigwaitinfo(), sigtimedwait(), waitid(), and the addition of the real-time signal range. Closes #1935 and #2695. * Gave SIGBUS a separate signal number. Fixes #6704. * Implemented <time.h> clock and timer support, and fixed/completed alarm() and [set]itimer(). Closes #5682. * Implemented support for thread cancellation. Closes #5686. * Moved send_signal() from <signal.h> to <OS.h>. Fixes #7554. * Lots over smaller more or less related changes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42116 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6250297a |
|
08-May-2011 |
Oliver Tappe <zooey@hirschkaefer.de> |
Switch haiku-revision from uint32 to string, as that's going to be required soon, no matter if we switch to Git or Mercurial * increase _SYS_NAMELEN defined in sys/utsname.h to 128 to allow long(ish) revisions * sHaikuRevision is now a static character array (in both libroot and kernel) * adjust build tool set_haiku_revision to write the revision as string git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41389 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
d2bf328d |
|
15-Dec-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Implemented a generic system watching mechanism with a userland API. Currently only a few events can be watched (team creation/deletion/exec, thread creation/ deletion/name changes). The functions start_system_watching()/ stop_system_watching start/stop watching events. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@39862 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
01f964ef |
|
08-Sep-2010 |
Fredrik Holmqvist <fredrik.holmqvist@gmail.com> |
Introduce a gSystemShutdown flag to be able to check if system is shutting down. ACPI Embedded Controller now uses polling when it is set to true. This might help with ACPI shutdown issues, if not this change can be reverted. Not verified as it works on all my machines even without this. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38585 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
cd7a1392 |
|
05-May-2010 |
Axel Dörfler <axeld@pinc-software.de> |
* boot_item_init() must come before debug_init_post_vm() or else neither the boot screen cannot be updated, nor might VESA work. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36625 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
8c8fcd77 |
|
05-May-2010 |
Axel Dörfler <axeld@pinc-software.de> |
* Moved the addition of the basic debugger commands directly after the VM init. * Separated the other stuff previously done in debug_init_post_vm() to the new debug_init_post_settings(). * Removed superfluous status_t return codes - they are ignored, anyway, and if there really is a show stopper in the init process, panicking would be the thing one should do. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36623 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
7f987e49 |
|
30-Apr-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Added a rendez-vous variable parameter to smp_trap_non_boot_cpus() and make boot CPU wait until all other CPUs are ready to wait. This solves a theoretical problem in main(): The boot CPU could run fully through the early initialization and reset sCpuRendezvous2 before the other CPUs left smp_cpu_rendezvous(). It's very unlikely on real hardware that the non-boot CPUs are so much slower, but it might be a concern in emulation. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36558 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
28d05e02 |
|
29-Apr-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Make scheduler_reschedule() an no-op until we're ready to start the scheduler. This avoids the need to use the send_signal_etc() work-around for resume_thread() during the early kernel initialization. Might fix #5851. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36530 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
9de17be6 |
|
14-Apr-2010 |
Axel Dörfler <axeld@pinc-software.de> |
* Moved I/O APIC initialization to a later point, now the APCI and DPC modules can safely be used. * Since using the I/O APIC is disabled by default, I've removed the "return" that prevented its use when enabled. Let's see if it already does anything. * Adapted other arch_int.cpp with a bit of cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36290 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
813d4cbe |
|
11-Apr-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Moved created subdirectory src/system/kernel/lock.cpp to new subdirectory locks. * Added syscalls for a new kind of mutex. A mutex consists only of an int32 and doesn't require any kernel resources. So it's initialization cannot fail (it consists only of setting the mutex value to 0). An uncontended lock or unlock operation can basically consist of an atomic_*() in userland. The syscalls (when the mutex is contended) are a bit more expensive than semaphore operations, though. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36158 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e50cf876 |
|
02-Dec-2009 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Moved the VM headers into subdirectory vm/. * Renamed vm_cache.h/vm_address_space.h to VMCache.h/VMAddressSpace. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34449 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
12fef51b |
|
23-Nov-2009 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Since r33809 dprintf() acquires a mutex when called with interrupts enabled. This is something must must not do in an idle thread or we get the scheduler into trouble. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34196 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e8885f20 |
|
22-Oct-2009 |
Axel Dörfler <axeld@pinc-software.de> |
Basically rewrote the ports subsystem to use: * its own heap allocator instead of cbuf - this makes cbuf superfluous, and I therefore removed it from the kernel. The heap is swappable, so lifts the kernel's resource usage a bit. In the future, the heap should grow as well; right now it should be at least as good as before. * it no longer uses spinlocks, but just mutexes now for better scalability - it was not usable with interrupts turned off anyway (due to its semaphore usage). * it no longer uses semaphores, but condition variables. * Needed to move the port initialization to a later point, as swappable memory wasn't usable that early. * All ports test are still passing, hopefully I didn't mess anything up :-) git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33728 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
fab1c05c |
|
24-Jun-2009 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Split the commpage initialization into two parts. The second part is executed after all CPUs have been queried for their features. On SMP machines sysenter/sysexit weren't used before due to the non-boot CPUs appearing not to have the feature. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31226 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
53e10177 |
|
04-Apr-2009 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
bonefish + mmlr: * We started the "main2" thread too late. Since the scheduler was already started on all CPUs, the idle thread could wait (for a mutex) while spawing the "main2" thread. This violated the assumption in the scheduler that all idle threads would always be ready or running. We now create the thread while the kernel runs still single-threaded. * scheduler_start() is now invoked with interrupts still disabled. We enable them after the function returns. This prevents scheduler_reschedule() from potentially being invoked before scheduler_start(). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29914 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
51755cf8 |
|
15-Mar-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Added DefaultNotificationService and DefaultUserNotificationService implementations that can be used by subsystems that want to have a pretty standard service. Only the latter is really complete, though. * The notification manager is now available earlier in the boot process. * Added notifications to teams/ports (only add/remove). * The network notification implementation is now using the DefaultUserNotificationService. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29543 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
53892c92 |
|
20-Oct-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Replaced scheduler_remove_from_run_queue() by scheduler_set_thread_priority(). Setting the thread priority was the only situation in which it was used. * Renamed scheduler.cpp to scheduler_simple.cpp. * The scheduler functions are no longer called directly. Instead there's an operation vector now, which is initialized at kernel init time. This allows for picking the most suitable scheduler for the machine (e.g. a non-SMP scheduler on a non-SMP machine). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28262 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
83d8936c |
|
16-Oct-2008 |
Michael Lotz <mmlr@mlotz.ch> |
Move semaphore initialization a bit earlier in boot. They'll be needed by ACPI. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28186 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6075e354 |
|
26-Sep-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Call module_init_post_boot_device() right after the boot volume has been mounted, before anyone could try to load any modules from it. Also pass it a flag whether the boot volume is where the boot loader pre-loaded the modules from. * module_init_post_boot_device() changes the pre-loaded module image paths to normalized boot volume paths, now. Got rid of the code in register_preloaded_module_image() which tried something like this. * Changed module image ref counting. A referenced module has single reference to its image, which is released when the module becomes unreferenced. * get_module() for a reference module will not try to re-get and re-set the module's image anymore. That could lead to a similar module (from different paths) being loaded at the same time. A module from a new file can only be loaded when the old one has been put completely. * Simplified B_KEEP_ALIVE module handling a bit. When the module is initialized, we add another reference, which we'll never free. Thus the module remains loaded without special handling. Removed module_image::keep_loaded. A B_KEEP_ALIVE module remains referenced and thus its image remains referenced, too. * Removed module::file, a cached path to the module's image. An optimization that wouldn't work with multiple root directories for modules (/boot/beos/..., /boot/common/...) or when module files were moved. get_module() does now always search the image file, when the module is still unreferenced. This should be a bit slower than before, but I didn't notice any difference in VMware at least. If it turns out to be a problem we could introduce a more intelligent cache that stays up to date by using node monitoring. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27752 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
ca7cb625 |
|
17-Sep-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Implemented a (private for now) get_system_info_etc() call, that can retrieve various system information. * Implemented retrieving some VM stats via this call. * The VM now maintains a page fault counter, and sets system_info::page_faults accordingly. * Added a (pretty simple) "vmstat" command line app. * Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27597 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
40dae370 |
|
11-Sep-2008 |
Salvatore Benedetto <salvatore.benedetto@gmail.com> |
* Adding msg{rcv,snd,get,ctl} syscalls to the system * Add message queue init function call to main.cpp git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27417 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
f273b13d |
|
31-Aug-2008 |
Salvatore Benedetto <salvatore.benedetto@gmail.com> |
* Renamed xsi_ipc_init() to xsi_sem_init() as there will be a xsi_msg_init() for message queue * Removed unnecessary header Vector.h * Removed HasSemaphoreSet method: since there will be an IPC table for each subsystem, if a key exist, it already has a semaphore set associated with it git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27256 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5a123e35 |
|
22-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Added a post boot device module init function that unloads all unused modules, as they aren't unloaded when there is no boot device yet. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27136 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
423fcd43 |
|
04-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Shuffled initializers around: the team, ELF, and module initializers come now a lot earlier. * That makes it now possible to use modules pretty early in the kernel (like before timer_init(), or int_init_post_vm()). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26790 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
35560421 |
|
03-Aug-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Patch by Zhao Shuai with changes by myself: * Keep track of the stack space actually allocated for the cache and let Write() fail when we've already allocated as much as reserved. * Added second phase of swap initialization (swap_init_post_modules()) which reads the virtual memory driver settings and creates/resizes a swap file. ATM truncate() is used to resize the swap file, but that is a bit slow. We should probably introduce a VFS function to use BFS's fast method. This should make swap support work somewhat, but since swap space is never freed ATM this would be a relatively short pleasure. Still disabled by default. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26783 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
27245755 |
|
02-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Renamed kernel_startup to gKernelStartup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26731 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
11790544 |
|
02-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26729 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
47ca7595 |
|
28-Jul-2008 |
Axel Dörfler <axeld@pinc-software.de> |
First patch by Salvatore to implement XSI semaphores with a few changes by myself: * renamed xsi_do_undo() to xsi_sem_undo() (there is more to XSI than sems). * Fixed coding style issues in sys/sem.h and xsi_sem.cpp. * Added _kern_*() syscall prototypes to syscalls.h. * Added a TODO in xsi_sem.cpp and xsi_semaphore.h about moving union semun to a shared header. * Made the team::xsi_sem_undo_requests int32 - due to padding, it would have needed 4 bytes anyway; please always use specific types over int/short/long. * xsi_sem_undo() now checks if it needs to do anything - the calls in team.cpp no longer needs to do this. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26676 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
c586076d |
|
24-Jul-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Patch by Zhao Shuai with changes by myself: * Init swap support in main(). * Added "bool swappable" parameter to VMCacheFactory::CreateAnonymousCache(). A cache supporting swapping is created when true. Adjusted invocations accordingly. * The page writer does now write non-locked swappable pages (when memory is low). * Fixed header guard of VMAnonymousNoSwapCache.h. * Swap support is compiled conditionally, controlled by the ENABLE_SWAP_SUPPORT in src/system/kernel/vm/VMAnonymousCache.h. It is disabled ATM. Since no swap files are added, it wouldn't have much effect anyway. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26625 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5c99d639 |
|
22-Jul-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Merged branch haiku/branches/developer/bonefish/vm into trunk. This introduces the following relevant changes: * VMCache: - Renamed vm_cache to VMCache, merged it with vm_store and made it a C++ class with virtual methods (replacing the store operations). Turned the different store implementations into subclasses. - Introduced MergeStore() callback, changed semantics of Commit(). - Changed locking and referencing semantics. A reference can only be acquired/released with the cache locked. An unreferenced cache is deleted and a mergeable cache merged when it is unlocked. This removes the "busy" state of a cache and simplifies the page fault code. * Added VMAnonymousCache, which will implement swap support (work by Zhao Shuai). It is not integrated and used yet, though. * Enabled the mutex/recursive lock holder asserts. * Fixed DoublyLinkedList::Swap(). * Generalized the low memory handler to a low resource handler. And made semaphores and reserved memory handled resources. Made vm_try_resource_memory() optionally wait (with timeout), and used that feature to reserve memory for areas. ... git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26572 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
383a9ac4 |
|
09-Jul-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Added an explicit boot_splash_uninit(). Not really needed, but makes it clear when boot_splash_set_stage() must no longer be used. * Free the memory associated with the kernel args before starting the init process. Unlike the original TODO stated there are quite a few more users of the kernel args (including the boot splash screen), hence we can't really do that earlier, unless we decide to copy the data over to the kernel heap. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26344 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
f5b3a6a7 |
|
05-Jun-2008 |
Michael Lotz <mmlr@mlotz.ch> |
* Initialize all static mutexes in the kernel through a MUTEX_INITIALIZER() and remove the then unneeded mutex_init() for them. * Remove the workaround for allowing uninitialized mutexes on kernel startup. As they are all initialized statically through the MUTEX_INITIALIZER() now this is not needed anymore. * An uninitialized mutex will now cause a panic when used to find possibly remaining cases. * Remove now unnecessary driver_settings_init_post_sem() function. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25812 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
1c8de858 |
|
01-Jun-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Added optional spinlock contention measurement feature. Enabled when B_DEBUG_SPINLOCK_CONTENTION is defined to 1. It typedefs spinlock to a structure (thus breaking BeOS binary compatibility), containing a counter which is incremented whenever a thread has to wait for the spinlock. * Added macros for spinlock initialization and access and changed code using spinlocks accordingly. This breaks compilation for BeOS -- the macros should be defined in the respective compatibility wrappers. * Added generic syscall to get the spinlock counters for the thread and the team spinlocks. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25752 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
368167ed |
|
26-May-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Integration of the new driver architecture. * Moved devfs from fs/ to device_manager/, and separated the legacy driver support from it. * Removed fast_log module. * There are a couple of (temporary) regressions, though: - legacy SATA and ISA IDE support is disabled, the drivers haven't been ported yet. - The not yet used ATA bus manager hasn't been ported yet, either. - AHCI changes have not been tested. - the listdev command has been removed from the build (as it currently doesn't work anymore). - device manager generated IDs currently are not freed anymore when a device node is removed. - generic drivers can't yet use the new driver architecture. - simple busses that do not support device types won't work yet. - legacy driver publishing/unpublishing (ie. what USB needs) has not been tested, and may be broken. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25662 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
7c61d84f |
|
14-May-2008 |
Stephan Aßmus <superstippi@gmx.de> |
Patch by Vasilis Kaoutsis: * Renamed main.c to main.cpp * Use find_directory() to construct the Bootscript path. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25509 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
89168ad8b98352ee9058331237ed7f59e416d9bf |
|
15-Apr-2015 |
Axel Dörfler <axeld@pinc-software.de> |
Boot the system via launch_daemon. * This is actually working already, although we cannot reproduce all the features of the former Bootscript yet. This is without any dependency support in launch_daemon. * All shell activity like cleaning out /tmp, setting up the environment, setting the time, etc. is not yet working.
|
#
035e3e77ed4550c9e9e5d932d02125be0d80d04c |
|
15-Apr-2015 |
Axel Dörfler <axeld@pinc-software.de> |
kernel: profile system when SYSTEM_PROFILER is defined. * This enables a mechanism to profile almost the complete boot process (starting with main2()), if SYSTEM_PROFILER is defined to 1. * You can access the profiling data using "profile -r".
|
#
6a2fd3a50eca601f2fc2dd22dfe9a581333c9420 |
|
03-Apr-2014 |
Jonathan Schleifer <js@webkeks.org> |
Add __dso_handle to bootloader and kernel Clang references these when building for x86_64.
|
#
52b442a687680ddd6a55478baeaa42ec87077f49 |
|
05-Dec-2013 |
Pawel Dziepak <pdziepak@quarnos.org> |
kernel: smp_cpu_rendezvous(): Use counter instead of bitmap
|
#
7db89e8dc395db73368479fd9817b2b67899f3f6 |
|
25-Nov-2013 |
Pawel Dziepak <pdziepak@quarnos.org> |
kernel: Rework cpuidle module * Create new interface for cpuidle modules (similar to the cpufreq interface) * Generic cpuidle module is no longer needed * Fix and update Intel C-State module
|
#
343c4896892733387f1e1b1ed01f151107e7da5f |
|
20-Oct-2013 |
Pawel Dziepak <pdziepak@quarnos.org> |
kernel: Create CPU topology tree
|
#
824ed26c51252bbe23ea16252f795e011e1687fb |
|
16-Oct-2013 |
Pawel Dziepak <pdziepak@quarnos.org> |
kernel: Fully detect CPU topology before initializing scheduler
|
#
de49e34927ea27d282f6e85c866db5073df379af |
|
04-Oct-2013 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Add symbol versioning for find_directory() Should already have been done back when the semantics for the B_COMMON_*DIRECTORY constants was changed. Currently old and new version behave the same. So this is just a contingency measure ATM.
|
#
b8a9a3a16073d8f474ee3415e208d04f4b58b4b0 |
|
26-Jun-2012 |
Alex Smith <alex@alex-smith.me.uk> |
Copied the x86 debug console functions to x86_64. Note that this is only temporary so that I have serial output from the kernel, the x86 and x86_64 versions will be merged later.
|
#
e5fc2bfcab8c15a3ff7d33c358f9aa82ed73c823 |
|
26-Jun-2012 |
Alex Smith <alex@alex-smith.me.uk> |
Implemented long mode setup/switch code, the bootloader can now start the 64-bit kernel! The setup procedure is fairly simple: create a 64-bit GDT and 64-bit page tables that include all kernel mappings from the 32-bit address space, but at the correct 64-bit address, then go through kernel_args and changes all virtual addresses to 64-bit addresses, and finally switch to long mode and jump to the kernel.
|
#
0e88a887b4a9ecaaf1062078d9ca9bfca78fcf3a |
|
13-Jun-2012 |
Alex Smith <alex@alex-smith.me.uk> |
First round of 64-bit safety fixes in the kernel. * Most of this is incorrect printf format strings. Changed all strings causing errors to use the B_PRI* format string definitions, which means the strings should be correct across all platforms. * Some other fixes for errors, casts required, etc.
|
#
323b65468e5836bb27a5e373b14027d902349437 |
|
21-Nov-2011 |
Oliver Tappe <zooey@hirschkaefer.de> |
Filtered flat import of Oliver's svn package management branch Bring the changes that aren't package management related and the ones that are but don't take effect as long as they are ignored by the build system into the master. Summary of changes: * Introduce private header <directories.h> with constants for a good deal of paths that should usually be retrieved via find_directory(). * Replace hard-coded paths by using find_directory() or the <directories.h> constants (e.g. in drivers and the kernel). * Add find_directory() constants needed for package management. * Add __HAIKU_ABI_NAME and B_HAIKU_ABI_NAME macros. * src/apps/deskbar: BeMenu.* -> DeskbarMenu.*, DeskBarUtils.* -> DeskbarUtils.* * Change deskbar menu settings directory from ~/config/be to ~/config/settings/deskbar. * Other smaller cleanups, changes, and fixes.
|
#
3dfd9cb95ce45f59160d50975210bc55e3fc0709 |
|
16-Jun-2011 |
Oliver Tappe <zooey@hirschkaefer.de> |
Flat commit of all changes from package-management branch in svn
|
#
24df65921befcd0ad0c5c7866118f922da61cb96 |
|
11-Jun-2011 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Merged signals-merge branch into trunk with the following changes: * Reorganized the kernel locking related to threads and teams. * We now discriminate correctly between process and thread signals. Signal handlers have been moved to teams. Fixes #5679. * Implemented real-time signal support, including signal queuing, SA_SIGINFO support, sigqueue(), sigwaitinfo(), sigtimedwait(), waitid(), and the addition of the real-time signal range. Closes #1935 and #2695. * Gave SIGBUS a separate signal number. Fixes #6704. * Implemented <time.h> clock and timer support, and fixed/completed alarm() and [set]itimer(). Closes #5682. * Implemented support for thread cancellation. Closes #5686. * Moved send_signal() from <signal.h> to <OS.h>. Fixes #7554. * Lots over smaller more or less related changes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42116 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6250297a0862f935bdd9e1770bb7dde9cdab2e3f |
|
08-May-2011 |
Oliver Tappe <zooey@hirschkaefer.de> |
Switch haiku-revision from uint32 to string, as that's going to be required soon, no matter if we switch to Git or Mercurial * increase _SYS_NAMELEN defined in sys/utsname.h to 128 to allow long(ish) revisions * sHaikuRevision is now a static character array (in both libroot and kernel) * adjust build tool set_haiku_revision to write the revision as string git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41389 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
d2bf328d7214cbba46b4781d70c5abda13083b89 |
|
15-Dec-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Implemented a generic system watching mechanism with a userland API. Currently only a few events can be watched (team creation/deletion/exec, thread creation/ deletion/name changes). The functions start_system_watching()/ stop_system_watching start/stop watching events. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@39862 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
01f964efebc3ee74f0733fbdf921817ddb6c1a6f |
|
08-Sep-2010 |
Fredrik Holmqvist <fredrik.holmqvist@gmail.com> |
Introduce a gSystemShutdown flag to be able to check if system is shutting down. ACPI Embedded Controller now uses polling when it is set to true. This might help with ACPI shutdown issues, if not this change can be reverted. Not verified as it works on all my machines even without this. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38585 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
cd7a1392734eb7c13ad4fad06d668993e895c85e |
|
05-May-2010 |
Axel Dörfler <axeld@pinc-software.de> |
* boot_item_init() must come before debug_init_post_vm() or else neither the boot screen cannot be updated, nor might VESA work. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36625 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
8c8fcd770ae49ca577c4b308549889c49f9f7807 |
|
05-May-2010 |
Axel Dörfler <axeld@pinc-software.de> |
* Moved the addition of the basic debugger commands directly after the VM init. * Separated the other stuff previously done in debug_init_post_vm() to the new debug_init_post_settings(). * Removed superfluous status_t return codes - they are ignored, anyway, and if there really is a show stopper in the init process, panicking would be the thing one should do. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36623 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
7f987e49d77f20a4a98a4f88f1e007f838ea2975 |
|
30-Apr-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Added a rendez-vous variable parameter to smp_trap_non_boot_cpus() and make boot CPU wait until all other CPUs are ready to wait. This solves a theoretical problem in main(): The boot CPU could run fully through the early initialization and reset sCpuRendezvous2 before the other CPUs left smp_cpu_rendezvous(). It's very unlikely on real hardware that the non-boot CPUs are so much slower, but it might be a concern in emulation. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36558 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
28d05e026f982a3b5fef1545d1b508d847410f80 |
|
29-Apr-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Make scheduler_reschedule() an no-op until we're ready to start the scheduler. This avoids the need to use the send_signal_etc() work-around for resume_thread() during the early kernel initialization. Might fix #5851. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36530 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
9de17be600220db91400c27772b19546284f470f |
|
14-Apr-2010 |
Axel Dörfler <axeld@pinc-software.de> |
* Moved I/O APIC initialization to a later point, now the APCI and DPC modules can safely be used. * Since using the I/O APIC is disabled by default, I've removed the "return" that prevented its use when enabled. Let's see if it already does anything. * Adapted other arch_int.cpp with a bit of cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36290 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
813d4cbe94b99e33ac2b921ae76df4d1b2b39b40 |
|
11-Apr-2010 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Moved created subdirectory src/system/kernel/lock.cpp to new subdirectory locks. * Added syscalls for a new kind of mutex. A mutex consists only of an int32 and doesn't require any kernel resources. So it's initialization cannot fail (it consists only of setting the mutex value to 0). An uncontended lock or unlock operation can basically consist of an atomic_*() in userland. The syscalls (when the mutex is contended) are a bit more expensive than semaphore operations, though. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36158 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e50cf8765be50a7454c9488db38b638cf90805af |
|
02-Dec-2009 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Moved the VM headers into subdirectory vm/. * Renamed vm_cache.h/vm_address_space.h to VMCache.h/VMAddressSpace. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34449 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
12fef51bc74b3b5c1499e2e6b4a7181cafd627e0 |
|
23-Nov-2009 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Since r33809 dprintf() acquires a mutex when called with interrupts enabled. This is something must must not do in an idle thread or we get the scheduler into trouble. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34196 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e8885f2097350aad05676d1d4af009375fe06a9b |
|
22-Oct-2009 |
Axel Dörfler <axeld@pinc-software.de> |
Basically rewrote the ports subsystem to use: * its own heap allocator instead of cbuf - this makes cbuf superfluous, and I therefore removed it from the kernel. The heap is swappable, so lifts the kernel's resource usage a bit. In the future, the heap should grow as well; right now it should be at least as good as before. * it no longer uses spinlocks, but just mutexes now for better scalability - it was not usable with interrupts turned off anyway (due to its semaphore usage). * it no longer uses semaphores, but condition variables. * Needed to move the port initialization to a later point, as swappable memory wasn't usable that early. * All ports test are still passing, hopefully I didn't mess anything up :-) git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33728 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
fab1c05c0521518ed89f3ed4ebc176dfe1cdbf70 |
|
24-Jun-2009 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Split the commpage initialization into two parts. The second part is executed after all CPUs have been queried for their features. On SMP machines sysenter/sysexit weren't used before due to the non-boot CPUs appearing not to have the feature. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31226 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
53e1017720991eca80c1488adaed143d818f1277 |
|
04-Apr-2009 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
bonefish + mmlr: * We started the "main2" thread too late. Since the scheduler was already started on all CPUs, the idle thread could wait (for a mutex) while spawing the "main2" thread. This violated the assumption in the scheduler that all idle threads would always be ready or running. We now create the thread while the kernel runs still single-threaded. * scheduler_start() is now invoked with interrupts still disabled. We enable them after the function returns. This prevents scheduler_reschedule() from potentially being invoked before scheduler_start(). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29914 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
51755cf83253c3ebc37694505611eb82189c3b4d |
|
15-Mar-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Added DefaultNotificationService and DefaultUserNotificationService implementations that can be used by subsystems that want to have a pretty standard service. Only the latter is really complete, though. * The notification manager is now available earlier in the boot process. * Added notifications to teams/ports (only add/remove). * The network notification implementation is now using the DefaultUserNotificationService. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29543 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
53892c92a02939d7e657f4fbb9563bc692716318 |
|
20-Oct-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Replaced scheduler_remove_from_run_queue() by scheduler_set_thread_priority(). Setting the thread priority was the only situation in which it was used. * Renamed scheduler.cpp to scheduler_simple.cpp. * The scheduler functions are no longer called directly. Instead there's an operation vector now, which is initialized at kernel init time. This allows for picking the most suitable scheduler for the machine (e.g. a non-SMP scheduler on a non-SMP machine). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28262 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
83d8936cff9803288cad5110de9576d4c40a0d93 |
|
16-Oct-2008 |
Michael Lotz <mmlr@mlotz.ch> |
Move semaphore initialization a bit earlier in boot. They'll be needed by ACPI. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28186 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6075e354abea9c571e3e74ecdc56662de736c4eb |
|
26-Sep-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Call module_init_post_boot_device() right after the boot volume has been mounted, before anyone could try to load any modules from it. Also pass it a flag whether the boot volume is where the boot loader pre-loaded the modules from. * module_init_post_boot_device() changes the pre-loaded module image paths to normalized boot volume paths, now. Got rid of the code in register_preloaded_module_image() which tried something like this. * Changed module image ref counting. A referenced module has single reference to its image, which is released when the module becomes unreferenced. * get_module() for a reference module will not try to re-get and re-set the module's image anymore. That could lead to a similar module (from different paths) being loaded at the same time. A module from a new file can only be loaded when the old one has been put completely. * Simplified B_KEEP_ALIVE module handling a bit. When the module is initialized, we add another reference, which we'll never free. Thus the module remains loaded without special handling. Removed module_image::keep_loaded. A B_KEEP_ALIVE module remains referenced and thus its image remains referenced, too. * Removed module::file, a cached path to the module's image. An optimization that wouldn't work with multiple root directories for modules (/boot/beos/..., /boot/common/...) or when module files were moved. get_module() does now always search the image file, when the module is still unreferenced. This should be a bit slower than before, but I didn't notice any difference in VMware at least. If it turns out to be a problem we could introduce a more intelligent cache that stays up to date by using node monitoring. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27752 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
ca7cb625b9769be2657365e2137197bdc3a9692d |
|
17-Sep-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Implemented a (private for now) get_system_info_etc() call, that can retrieve various system information. * Implemented retrieving some VM stats via this call. * The VM now maintains a page fault counter, and sets system_info::page_faults accordingly. * Added a (pretty simple) "vmstat" command line app. * Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27597 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
40dae3708fbc0d84a0a2a4bd2cf024992c03db0d |
|
11-Sep-2008 |
Salvatore Benedetto <salvatore.benedetto@gmail.com> |
* Adding msg{rcv,snd,get,ctl} syscalls to the system * Add message queue init function call to main.cpp git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27417 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
f273b13ddb6c92afd516f79f92447c1106a47238 |
|
31-Aug-2008 |
Salvatore Benedetto <salvatore.benedetto@gmail.com> |
* Renamed xsi_ipc_init() to xsi_sem_init() as there will be a xsi_msg_init() for message queue * Removed unnecessary header Vector.h * Removed HasSemaphoreSet method: since there will be an IPC table for each subsystem, if a key exist, it already has a semaphore set associated with it git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27256 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5a123e35911db0e706f1376638fb67d10c94d464 |
|
22-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Added a post boot device module init function that unloads all unused modules, as they aren't unloaded when there is no boot device yet. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27136 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
423fcd43ae4e19a6799924f121b1b12d9303f560 |
|
04-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Shuffled initializers around: the team, ELF, and module initializers come now a lot earlier. * That makes it now possible to use modules pretty early in the kernel (like before timer_init(), or int_init_post_vm()). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26790 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
355604212d43a7a476436ee0df209043d52c0872 |
|
03-Aug-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Patch by Zhao Shuai with changes by myself: * Keep track of the stack space actually allocated for the cache and let Write() fail when we've already allocated as much as reserved. * Added second phase of swap initialization (swap_init_post_modules()) which reads the virtual memory driver settings and creates/resizes a swap file. ATM truncate() is used to resize the swap file, but that is a bit slow. We should probably introduce a VFS function to use BFS's fast method. This should make swap support work somewhat, but since swap space is never freed ATM this would be a relatively short pleasure. Still disabled by default. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26783 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
272457553e0ff0860cf931c1d193c2c6020a7da8 |
|
02-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Renamed kernel_startup to gKernelStartup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26731 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
11790544cd764ffd3947d8ce656e07ff840775ea |
|
02-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26729 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
47ca7595ca54e08dac7482950a35b045e6ad8801 |
|
28-Jul-2008 |
Axel Dörfler <axeld@pinc-software.de> |
First patch by Salvatore to implement XSI semaphores with a few changes by myself: * renamed xsi_do_undo() to xsi_sem_undo() (there is more to XSI than sems). * Fixed coding style issues in sys/sem.h and xsi_sem.cpp. * Added _kern_*() syscall prototypes to syscalls.h. * Added a TODO in xsi_sem.cpp and xsi_semaphore.h about moving union semun to a shared header. * Made the team::xsi_sem_undo_requests int32 - due to padding, it would have needed 4 bytes anyway; please always use specific types over int/short/long. * xsi_sem_undo() now checks if it needs to do anything - the calls in team.cpp no longer needs to do this. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26676 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
c586076dcafe59a79b7f3073f2471497d62b29af |
|
24-Jul-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Patch by Zhao Shuai with changes by myself: * Init swap support in main(). * Added "bool swappable" parameter to VMCacheFactory::CreateAnonymousCache(). A cache supporting swapping is created when true. Adjusted invocations accordingly. * The page writer does now write non-locked swappable pages (when memory is low). * Fixed header guard of VMAnonymousNoSwapCache.h. * Swap support is compiled conditionally, controlled by the ENABLE_SWAP_SUPPORT in src/system/kernel/vm/VMAnonymousCache.h. It is disabled ATM. Since no swap files are added, it wouldn't have much effect anyway. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26625 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5c99d639708df9b4e2cc847b38d510149d19ec78 |
|
22-Jul-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Merged branch haiku/branches/developer/bonefish/vm into trunk. This introduces the following relevant changes: * VMCache: - Renamed vm_cache to VMCache, merged it with vm_store and made it a C++ class with virtual methods (replacing the store operations). Turned the different store implementations into subclasses. - Introduced MergeStore() callback, changed semantics of Commit(). - Changed locking and referencing semantics. A reference can only be acquired/released with the cache locked. An unreferenced cache is deleted and a mergeable cache merged when it is unlocked. This removes the "busy" state of a cache and simplifies the page fault code. * Added VMAnonymousCache, which will implement swap support (work by Zhao Shuai). It is not integrated and used yet, though. * Enabled the mutex/recursive lock holder asserts. * Fixed DoublyLinkedList::Swap(). * Generalized the low memory handler to a low resource handler. And made semaphores and reserved memory handled resources. Made vm_try_resource_memory() optionally wait (with timeout), and used that feature to reserve memory for areas. ... git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26572 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
383a9ac435e037cd13f6a13d2eddf1147d7830eb |
|
09-Jul-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Added an explicit boot_splash_uninit(). Not really needed, but makes it clear when boot_splash_set_stage() must no longer be used. * Free the memory associated with the kernel args before starting the init process. Unlike the original TODO stated there are quite a few more users of the kernel args (including the boot splash screen), hence we can't really do that earlier, unless we decide to copy the data over to the kernel heap. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26344 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
f5b3a6a7968b849c8cb3d06ffe6d19acccf910a8 |
|
05-Jun-2008 |
Michael Lotz <mmlr@mlotz.ch> |
* Initialize all static mutexes in the kernel through a MUTEX_INITIALIZER() and remove the then unneeded mutex_init() for them. * Remove the workaround for allowing uninitialized mutexes on kernel startup. As they are all initialized statically through the MUTEX_INITIALIZER() now this is not needed anymore. * An uninitialized mutex will now cause a panic when used to find possibly remaining cases. * Remove now unnecessary driver_settings_init_post_sem() function. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25812 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
1c8de8581b66c14ea94bccd7ddcea99291955796 |
|
01-Jun-2008 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Added optional spinlock contention measurement feature. Enabled when B_DEBUG_SPINLOCK_CONTENTION is defined to 1. It typedefs spinlock to a structure (thus breaking BeOS binary compatibility), containing a counter which is incremented whenever a thread has to wait for the spinlock. * Added macros for spinlock initialization and access and changed code using spinlocks accordingly. This breaks compilation for BeOS -- the macros should be defined in the respective compatibility wrappers. * Added generic syscall to get the spinlock counters for the thread and the team spinlocks. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25752 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
368167ede8118f72da8c9ac5bb98ce9b46a8a639 |
|
26-May-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Integration of the new driver architecture. * Moved devfs from fs/ to device_manager/, and separated the legacy driver support from it. * Removed fast_log module. * There are a couple of (temporary) regressions, though: - legacy SATA and ISA IDE support is disabled, the drivers haven't been ported yet. - The not yet used ATA bus manager hasn't been ported yet, either. - AHCI changes have not been tested. - the listdev command has been removed from the build (as it currently doesn't work anymore). - device manager generated IDs currently are not freed anymore when a device node is removed. - generic drivers can't yet use the new driver architecture. - simple busses that do not support device types won't work yet. - legacy driver publishing/unpublishing (ie. what USB needs) has not been tested, and may be broken. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25662 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
7c61d84fcd53518c0a155315f72a71e21d5c3574 |
|
14-May-2008 |
Stephan Aßmus <superstippi@gmx.de> |
Patch by Vasilis Kaoutsis: * Renamed main.c to main.cpp * Use find_directory() to construct the Bootscript path. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25509 a95241bf-73f2-0310-859d-f6bbb57e9c96
|