Revision tags: release/4.1.1_cvs |
|
#
0384fff8 |
| 07-Sep-2000 |
Jason Evans <jasone@FreeBSD.org> |
Major update to the way synchronization is done in the kernel. Highlights include:
* Mutual exclusion is used instead of spl*(). See mutex(9). (Note: The alpha port is still in transition and c
Major update to the way synchronization is done in the kernel. Highlights include:
* Mutual exclusion is used instead of spl*(). See mutex(9). (Note: The alpha port is still in transition and currently uses both.)
* Per-CPU idle processes.
* Interrupts are run in their own separate kernel threads and can be preempted (i386 only).
Partially contributed by: BSDi (BSD/OS) Submissions by (at least): cp, dfr, dillon, grog, jake, jhb, sheldonh
show more ...
|
#
37b087a6 |
| 11-Aug-2000 |
Peter Wemm <peter@FreeBSD.org> |
Clean up some low level bootstrap code:
- stop using the evil 'struct trapframe' argument for mi_startup() (formerly main()). There are much better ways of doing it. - do not use prepare_usermode
Clean up some low level bootstrap code:
- stop using the evil 'struct trapframe' argument for mi_startup() (formerly main()). There are much better ways of doing it. - do not use prepare_usermode() - setregs() in execve() will do it all for us as long as the p_md.md_regs pointer is set. (which is now done in machdep.c rather than init_main.c. The Alpha port did it this way all along and is much cleaner). - collect all the magic %cr0 etc register settings into one place and have the AP's call that instead of using magic numbers (!!) that keep changing over and over again. - Make it safe to call kthread_create() earlier, including during the device probe sequence. It doesn't need the callback mechanism that NetBSD's version uses. - kthreads created this way are root-less as they exist before the root filesystem is mounted. init(1) is set up so that it aquires the root pointers prior to running. If other kthreads want filesystem acccess we can make this code more generic. - set all threads start times once we have decided what time it is. - init uses a trampoline rather than the evil prepare_usermode() hack. - kern_descrip.c has a couple of tweaks to deal with forking when there is no rootdir or cwd etc. - adjust the early SYSINIT() sequence so that a few prereqisites are in place. eg: make sure the run queue is initialized before doing forks.
With this, the USB code can easily create a kthread to do the device tree discovery. (I have tested it, it works nicely).
There are still some open issues before this is truely useful. - tsleep() does not like working before the clock is running. It sort-of tries to spin wait, but it can do more useful things now. - stopping a kthread in kld code at unload time is "interesting" but we have a solution for that.
The Alpha code needs no changes for this. It already uses pretty much the same strategies, but a little cleaner.
show more ...
|
Revision tags: release/4.1.0, release/3.5.0_cvs |
|
#
36e9f877 |
| 28-Mar-2000 |
Matthew Dillon <dillon@FreeBSD.org> |
Commit major SMP cleanups and move the BGL (big giant lock) in the syscall path inward. A system call may select whether it needs the MP lock or not (the default being that it does need it).
Commit major SMP cleanups and move the BGL (big giant lock) in the syscall path inward. A system call may select whether it needs the MP lock or not (the default being that it does need it).
A great deal of conditional SMP code for various deadended experiments has been removed. 'cil' and 'cml' have been removed entirely, and the locking around the cpl has been removed. The conditional separately-locked fast-interrupt code has been removed, meaning that interrupts must hold the CPL now (but they pretty much had to anyway). Another reason for doing this is that the original separate-lock for interrupts just doesn't apply to the interrupt thread mechanism being contemplated.
Modifications to the cpl may now ONLY occur while holding the MP lock. For example, if an otherwise MP safe syscall needs to mess with the cpl, it must hold the MP lock for the duration and must (as usual) save/restore the cpl in a nested fashion.
This is precursor work for the real meat coming later: avoiding having to hold the MP lock for common syscalls and I/O's and interrupt threads. It is expected that the spl mechanisms and new interrupt threading mechanisms will be able to run in tandem, allowing a slow piecemeal transition to occur.
This patch should result in a moderate performance improvement due to the considerable amount of code that has been removed from the critical path, especially the simplification of the spl*() calls. The real performance gains will come later.
Approved by: jkh Reviewed by: current, bde (exception.s) Some work taken from: luoqi's patch
show more ...
|
Revision tags: release/4.0.0_cvs |
|
#
383774c4 |
| 02-Mar-2000 |
Peter Dufault <dufault@FreeBSD.org> |
Patches that eliminate extra context switches in FIFO case. Fixes p1003_1b regression test in the simple case of no RR and FIFO processes competing.
Reviewed by: jkh, bde
|
#
664a31e4 |
| 29-Dec-1999 |
Peter Wemm <peter@FreeBSD.org> |
Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" is an application space macro and the applications are supposed to be free to use it as they please (but cannot). This is cons
Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" is an application space macro and the applications are supposed to be free to use it as they please (but cannot). This is consistant with the other BSD's who made this change quite some time ago. More commits to come.
show more ...
|
Revision tags: release/3.4.0_cvs, release/3.3.0_cvs |
|
#
c3aac50f |
| 28-Aug-1999 |
Peter Wemm <peter@FreeBSD.org> |
$Id$ -> $FreeBSD$
|
#
eec2e836 |
| 10-Jul-1999 |
Bruce Evans <bde@FreeBSD.org> |
Go back to the old (icu.s rev.1.7 1993) way of keeping the AST-pending bit separate from ipending, since this is simpler and/or necessary for SMP and may even be better for UP.
Reviewed by: alc, luo
Go back to the old (icu.s rev.1.7 1993) way of keeping the AST-pending bit separate from ipending, since this is simpler and/or necessary for SMP and may even be better for UP.
Reviewed by: alc, luoqi, tegge
show more ...
|
Revision tags: release/3.2.0 |
|
#
0666dbe1 |
| 23-Apr-1999 |
Dmitrij Tejblum <dt@FreeBSD.org> |
Moved cpu_set_fork_handler's prototype from <machine/cpu.h> to <sys/proc.h>.
Suggested by: bde
|
Revision tags: release/3.1.0 |
|
#
79a25012 |
| 02-Feb-1999 |
Bruce Evans <bde@FreeBSD.org> |
Added a hopefully-machine-independent macro for determining if a reschedule is pending.
|
#
3cfc69e6 |
| 29-Jan-1999 |
Matthew Dillon <dillon@FreeBSD.org> |
More -Wall / -Wcast-qual cleanup. Also, EXEC_SET can't use C_DECLARE_MODULE due to the linker_file_sysinit() function making modifications to the data.
|
Revision tags: release/3.0.0, release/2.2.8 |
|
#
582e5286 |
| 31-Aug-1998 |
KATO Takenori <kato@FreeBSD.org> |
- hw.machine_arch returns cpu architecture type. - moved definition of MACHINE_ARCH from cpu.h to parm.h as alpha. - Added definitions of _MACHINE and _MACHINE_ARCH. - Added hw.ispc98. The hw.ispc98
- hw.machine_arch returns cpu architecture type. - moved definition of MACHINE_ARCH from cpu.h to parm.h as alpha. - Added definitions of _MACHINE and _MACHINE_ARCH. - Added hw.ispc98. The hw.ispc98 is 1 in PC98 kernel and is 0 in IBM-PC kernel.
Discussed with: John Birrell <jb@FreeBSD.ORG>
show more ...
|
Revision tags: release/2.2.7, release/2.2.6 |
|
#
7f47cf2f |
| 28-Oct-1997 |
Bruce Evans <bde@FreeBSD.org> |
Don't include <machine/cputypes.h> or declare cputype/class interfaces in <machine/cpu.h>. Moved the declarations to <machine/cputypes.h>. Fixed style bugs in the moved code. Fixed everything that
Don't include <machine/cputypes.h> or declare cputype/class interfaces in <machine/cpu.h>. Moved the declarations to <machine/cputypes.h>. Fixed style bugs in the moved code. Fixed everything that depended on the nested include. Don't include <machine/cpu.h> (in the changed files) unless something in it is used directly.
show more ...
|
#
4090154b |
| 27-Oct-1997 |
Bruce Evans <bde@FreeBSD.org> |
Moved declaration of etext from <machine/md_var.h> to <machine/cpu.h> and fixed everything that dependended on it being declared in the old place. It is used in "machine-independent" code in subr_pr
Moved declaration of etext from <machine/md_var.h> to <machine/cpu.h> and fixed everything that dependended on it being declared in the old place. It is used in "machine-independent" code in subr_prof.c.
Moved declaration of btext from subr_prof.c to <machine/cpu.h>. It is machine-dependent.
show more ...
|
Revision tags: release/2.2.5_cvs |
|
#
662f9a69 |
| 30-Aug-1997 |
KATO Takenori <kato@FreeBSD.org> |
Move MACHINE_ARCH definition from <machine/param.h> to <machine/cpu.h>.
Submitted by: Bruce Evans <bde@zeta.org.au>
|
#
40d50994 |
| 21-Aug-1997 |
Philippe Charnier <charnier@FreeBSD.org> |
Revert my previous commit about using CS_SECURE macro. Requested by: Bruce.
|
#
15f35491 |
| 18-Aug-1997 |
Philippe Charnier <charnier@FreeBSD.org> |
Use CS_SECURE macro. Reviewed by: John Dyson
|
#
48a09cf2 |
| 09-Aug-1997 |
John Dyson <dyson@FreeBSD.org> |
VM86 kernel support. Work done by BSDI, Jonathan Lemon <jlemon@americantv.com>, Mike Smith <msmith@gsoft.com.au>, Sean Eric Fagan <sef@kithrup.com>, and probably alot of others. Submitted by: Jnat
VM86 kernel support. Work done by BSDI, Jonathan Lemon <jlemon@americantv.com>, Mike Smith <msmith@gsoft.com.au>, Sean Eric Fagan <sef@kithrup.com>, and probably alot of others. Submitted by: Jnathan Lemon <jlemon@americantv.com>
show more ...
|
Revision tags: release/2.2.2_cvs |
|
#
a2a1c95c |
| 07-Apr-1997 |
Peter Wemm <peter@FreeBSD.org> |
The biggie: Get rid of the UPAGES from the top of the per-process address space. (!)
Have each process use the kernel stack and pcb in the kvm space. Since the stacks are at a different address, we
The biggie: Get rid of the UPAGES from the top of the per-process address space. (!)
Have each process use the kernel stack and pcb in the kvm space. Since the stacks are at a different address, we cannot copy the stack at fork() and allow the child to return up through the function call tree to return to user mode - create a new execution context and have the new process begin executing from cpu_switch() and go to user mode directly. In theory this should speed up fork a bit.
Context switch the tss_esp0 pointer in the common tss. This is a lot simpler since than swithching the gdt[GPROC0_SEL].sd.sd_base pointer to each process's tss since the esp0 pointer is a 32 bit pointer, and the sd_base setting is split into three different bit sections at non-aligned boundaries and requires a lot of twiddling to reset.
The 8K of memory at the top of the process space is now empty, and unmapped (and unmappable, it's higher than VM_MAXUSER_ADDRESS).
Simplity the pmap code to manage process contexts, we no longer have to double map the UPAGES, this simplifies and should measuably speed up fork().
The following parts came from John Dyson:
Set PG_G on the UPAGES that are now in kernel context, and invalidate them when swapping them out.
Move the upages object (upobj) from the vmspace to the proc structure.
Now that the UPAGES (pcb and kernel stack) are out of user space, make rfork(..RFMEM..) do what was intended by sharing the vmspace entirely via reference counting rather than simply inheriting the mappings.
show more ...
|
Revision tags: release/2.2.1_cvs, release/2.2.0, release/2.1.7_cvs |
|
#
6875d254 |
| 22-Feb-1997 |
Peter Wemm <peter@FreeBSD.org> |
Back out part 1 of the MCFH that changed $Id$ to $FreeBSD$. We are not ready for it yet.
|
Revision tags: release/2.1.6_cvs, release/2.1.6.1 |
|
#
d5605f2a |
| 02-Feb-1997 |
KATO Takenori <kato@FreeBSD.org> |
Deleted i386_cpus[]. i386_cpus[] is a static variable in identcpu.c.
Found-by: lint
|
#
1130b656 |
| 14-Jan-1997 |
Jordan K. Hubbard <jkh@FreeBSD.org> |
Make the long-awaited change from $Id$ to $FreeBSD$
This will make a number of things easier in the future, as well as (finally!) avoiding the Id-smashing problem which has plagued developers for so
Make the long-awaited change from $Id$ to $FreeBSD$
This will make a number of things easier in the future, as well as (finally!) avoiding the Id-smashing problem which has plagued developers for so long.
Boy, I'm glad we're not using sup anymore. This update would have been insane otherwise.
show more ...
|
Revision tags: release/2.1.5_cvs |
|
#
79df6d85 |
| 25-Jun-1996 |
Bruce Evans <bde@FreeBSD.org> |
trap.c: Fixed profiling of system times. It was pre-4.4Lite and didn't support statclocks. System times were too small by a factor of 8.
Handle deferred profiling ticks the 4.4Lite way: use addupc
trap.c: Fixed profiling of system times. It was pre-4.4Lite and didn't support statclocks. System times were too small by a factor of 8.
Handle deferred profiling ticks the 4.4Lite way: use addupc_task() instead of addupc(). Call addupc_task() directly instead of using the ADDUPC() macro.
Removed vestigial support for PROFTIMER.
switch.s: Removed addupc().
resourcevar.h: Removed ADDUPC() and declarations of addupc().
cpu.h: Updated a comment. i386's never were tahoe's, and the deferred profiling tick became (possibly) multiple ticks in 4.4Lite.
Obtained from: mostly from NetBSD
show more ...
|
#
73dc05d6 |
| 07-Apr-1996 |
Bruce Evans <bde@FreeBSD.org> |
Moved declaration of bootverbose to a better place. It isn't machine-dependent.
Moved declaration of cpu_fork() to a better place. Only its implementation is machine-dependent.
|
#
fe0d5f43 |
| 05-Apr-1996 |
Andrey A. Chernov <ache@FreeBSD.org> |
Add wall_cmos_clock sysctl variable, needed to manage adjkerntz even for UTC cmos clocks (needed for Local Timezone FSes)
|
#
78966e20 |
| 29-Mar-1996 |
Bruce Evans <bde@FreeBSD.org> |
Parenthesized macros.
Fixed munged tabs.
|