#
331722 |
|
29-Mar-2018 |
eadler |
Revert r330897:
This was intended to be a non-functional change. It wasn't. The commit message was thus wrong. In addition it broke arm, and merged crypto related code.
Revert with prejudice.
This revert skips files touched in r316370 since that commit was since MFCed. This revert also skips files that require $FreeBSD$ property changes.
Thank you to those who helped me get out of this mess including but not limited to gonzo, kevans, rgrimes.
Requested by: gjb (re)
|
#
330897 |
|
14-Mar-2018 |
eadler |
Partial merge of the SPDX changes
These changes are incomplete but are making it difficult to determine what other changes can/should be merged.
No objections from: pfg
|
#
302408 |
|
07-Jul-2016 |
gjb |
Copy head@r302406 to stable/11 as part of the 11.0-RELEASE cycle. Prune svn:mergeinfo from the new branch, as nothing has been merged here.
Additional commits post-branch will follow.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
#
286288 |
|
04-Aug-2015 |
kib |
Give large kernel stack to the initial thread . Otherwise, ZFS overflows the stack during root mount in some configurations.
Tested by: Fabian Keil <freebsd-listen@fabiankeil.de> (previous version) Sponsored by: The FreeBSD Foundation MFC after: 2 weeks
|
#
285041 |
|
02-Jul-2015 |
kib |
Use single instance of the identical INKERNEL() and PMC_IN_KERNEL() macros on amd64 and i386. Move the definition to machine/param.h. kgdb defines INKERNEL() too, the conflict is resolved by renaming kgdb version to PINKERNEL().
On i386, correct the lowest kernel address. After the shared page was introduced, USRSTACK no longer points to the last user address + 1 [*]
Submitted by: Oliver Pinter [*] Sponsored by: The FreeBSD Foundation MFC after: 1 week
|
#
281495 |
|
13-Apr-2015 |
kib |
Add config option PAE_TABLES for the i386 kernel. It switches pmap to use PAE format for the page tables, but does not incur other consequences of the full PAE config. In particular, vm_paddr_t and bus_addr_t are left 32bit, and max supported memory is still limited by 4GB.
The option allows to have nx permissions for memory mappings on i386 kernel, while keeping the usual i386 KBI and avoiding the kernel data sizing problems typical for the PAE config.
Intel documented that the PAE format for page tables is available starting with the Pentium Pro, but it is possible that the plain Pentium CPUs have the required support (Appendix H). The goal is to enable the option and non-exec mappings on i386 for the GENERIC kernel. Anybody wanting a useful system on 486, have to reconfigure the modern i386 kernel anyway.
Discussed with: alc, jhb Sponsored by: The FreeBSD Foundation MFC after: 2 weeks
|
#
250338 |
|
07-May-2013 |
attilio |
Rename VM_NDOMAIN into MAXMEMDOM and move it into machine/param.h in order to match the MAXCPU concept. The change should also be useful for consolidation and consistency.
Sponsored by: EMC / Isilon storage division Obtained from: jeff Reviewed by: alc
|
#
249722 |
|
21-Apr-2013 |
tijl |
Remove redundant definitions of _ALIGN and _ALIGNBYTES.
|
#
248789 |
|
27-Mar-2013 |
kib |
Fix the VM_BCACHE_SIZE_MAX definition on i386 to match the maximal buffer map size, auto-tuned on the 4GB machine. Having the maxbcache bigger than the buffer map causes the transient bio map sizing logic to assume that there is enough KVA to use approximately 90MB (buffer map is sized to 110MB, and maxbcache is 200MB). The increase in the KVA usage caused other big KVA consumers, like nvidia.ko, to fail the initialization.
Change the definition for both PAE and non-PAE cases, since PAE is even more KVA-starved.
Reported and tested by: David Wolfskill Discussed with: alc Sponsored by: The FreeBSD Foundation
|
#
239730 |
|
27-Aug-2012 |
des |
Parly revert r239255: reinstate a default maxswzone on i386, where KVA is scarce, but set it slightly higher so we can handle 8 GB of swap.
|
#
239255 |
|
14-Aug-2012 |
des |
As discussed on -current, remove the hardcoded default maxswzone.
MFC after: 3 weeks
|
#
224207 |
|
18-Jul-2011 |
attilio |
Add the possibility to specify from kernel configs MAXCPU value. This patch is going to help in cases like mips flavours where you want a more granular support on MAXCPU.
No MFC is previewed for this patch.
Tested by: pluknet Approved by: re (kib)
|
#
223440 |
|
22-Jun-2011 |
jhb |
Move {amd64,i386}/pci/pci_bus.c and {amd64,i386}/include/pci_cfgreg.h to the x86 tree. The $PIR code is still only enabled on i386 and not amd64. While here, make the qpi(4) driver on conditional on 'device pci'.
|
#
197316 |
|
18-Sep-2009 |
alc |
Add a new sysctl for reporting all of the supported page sizes.
Reviewed by: jhb MFC after: 3 weeks
|
#
196994 |
|
08-Sep-2009 |
phk |
Get rid of the _NO_NAMESPACE_POLLUTION kludge by creating an architecture specific include file containing the _ALIGN* stuff which <sys/socket.h> needs.
|
#
195376 |
|
05-Jul-2009 |
sam |
Cleanup ALIGNED_POINTER: o add to platforms where it was missing (arm, i386, powerpc, sparc64, sun4v) o define as "1" on amd64 and i386 where there is no restriction o make the type returned consistent with ALIGN o remove _ALIGNED_POINTER o make associated comments consistent
Reviewed by: bde, imp, marcel Approved by: re (kensmith)
|
#
192331 |
|
18-May-2009 |
jhb |
Bump CACHE_LINE_SIZE to 128 for x86. Intel's manuals explicitly recommend using 128 byte alignment for locks. (See IA-32 SDM Vol 3A 7.11.6.7)
|
#
191309 |
|
20-Apr-2009 |
rwatson |
Don't conditionally define CACHE_LINE_SHIFT, as we anticipate sizing a fair number of static data structures, making this an unlikely option to try to change without also changing source code. [1]
Change default cache line size on ia64, sparc64, and sun4v to 128 bytes, as this was what rtld-elf was already using on those platforms. [2]
Suggested by: bde [1], jhb [2] MFC after: 2 weeks
|
#
191278 |
|
19-Apr-2009 |
rwatson |
Add description and cautionary note regarding CACHE_LINE_SIZE.
MFC after: 2 weeks Suggested by: alc
|
#
191276 |
|
19-Apr-2009 |
rwatson |
For each architecture, define CACHE_LINE_SHIFT and a derived CACHE_LINE_SIZE constant. These constants are intended to over-estimate the cache line size, and be used at compile-time when a run-time tuning alternative isn't appropriate or available.
Defaults for all architectures are 64 bytes, except powerpc where it is 128 bytes (used on G5 systems).
MFC after: 2 weeks Discussed on: arch@
|
#
183525 |
|
01-Oct-2008 |
jhb |
Bump MAXCPU to 32 now that 32 CPU x86 systems exist.
Tested by: rwatson, mdtansca Approved by: peter
|
#
183343 |
|
25-Sep-2008 |
kmacy |
add NPGPTD_SHIFT for the nkpt calculation
MFC after: 1 month
|
#
177661 |
|
27-Mar-2008 |
jb |
When building a kernel module, define MAXCPU the same as SMP so that modules work with and without SMP.
|
#
154128 |
|
09-Jan-2006 |
imp |
By popular demand, move __HAVE_ACPI and __PCI_REROUTE_INTERRUPT into param.h. Per request, I've placed these just after the _NO_NAMESPACE_POLLUTION ifndef. I've not renamed anything yet, but may since we don't need the __.
Submitted by: bde, jhb, scottl, many others.
|
#
153168 |
|
06-Dec-2005 |
ru |
Drop _MACHINE_ARCH and _MACHINE defines (not to be confused with MACHINE_ARCH and MACHINE). Their purpose was to be able to test in cpp(1), but cpp(1) only understands integer type expressions. Using such unsupported expressions introduced a number of subtle bugs, which were discovered by compiling with -Wundef.
|
#
137914 |
|
20-Nov-2004 |
das |
Remove UAREA_PAGES.
Reviewed by: arch@
|
#
134649 |
|
02-Sep-2004 |
scottl |
Turn PREEMPTION into a kernel option. Make sure that it's defined if FULL_PREEMPTION is defined. Add a runtime warning to ULE if PREEMPTION is enabled (code inspired by the PREEMPTION warning in kern_switch.c). This is a possible MT5 candidate.
|
#
134616 |
|
01-Sep-2004 |
julian |
Give up trying to make preemption dependent on SCHED_4BSD the list of breakages was getting too long
|
#
134610 |
|
01-Sep-2004 |
julian |
Don't ask for this for modules. no modules need to know about preemption at the moment
|
#
134599 |
|
01-Sep-2004 |
scottl |
Protect the PREEMPTION logic with #ifdef _KERNEL to fix the build.
|
#
134598 |
|
01-Sep-2004 |
julian |
Only turn preemption for 4bsd. it's still poison for ULE.
|
#
134591 |
|
01-Sep-2004 |
julian |
Give the 4bsd scheduler the ability to wake up idle processors when there is new work to be done.
MFC after: 5 days
|
#
132961 |
|
01-Aug-2004 |
scottl |
Turn off PREEMPTION by default while it gets debugged. It's been causing 4 weeks of problems including deadlocks and instant panics. Note that the real bugs are likely in the scheduler.
|
#
131481 |
|
02-Jul-2004 |
jhb |
Implement preemption of kernel threads natively in the scheduler rather than as one-off hacks in various other parts of the kernel: - Add a function maybe_preempt() that is called from sched_add() to determine if a thread about to be added to a run queue should be preempted to directly. If it is not safe to preempt or if the new thread does not have a high enough priority, then the function returns false and sched_add() adds the thread to the run queue. If the thread should be preempted to but the current thread is in a nested critical section, then the flag TDF_OWEPREEMPT is set and the thread is added to the run queue. Otherwise, mi_switch() is called immediately and the thread is never added to the run queue since it is switch to directly. When exiting an outermost critical section, if TDF_OWEPREEMPT is set, then clear it and call mi_switch() to perform the deferred preemption. - Remove explicit preemption from ithread_schedule() as calling setrunqueue() now does all the correct work. This also removes the do_switch argument from ithread_schedule(). - Do not use the manual preemption code in mtx_unlock if the architecture supports native preemption. - Don't call mi_switch() in a loop during shutdown to give ithreads a chance to run if the architecture supports native preemption since the ithreads will just preempt DELAY(). - Don't call mi_switch() from the page zeroing idle thread for architectures that support native preemption as it is unnecessary. - Native preemption is enabled on the same archs that supported ithread preemption, namely alpha, i386, and amd64.
This change should largely be a NOP for the default case as committed except that we will do fewer context switches in a few cases and will avoid the run queues completely when preempting.
Approved by: scottl (with his re@ hat)
|
#
128019 |
|
07-Apr-2004 |
imp |
Remove advertising clause from University of California Regent's license, per letter dated July 22, 1999 and email from Peter Wemm, Alan Cox and Robert Watson.
Approved by: core, peter, alc, rwatson
|
#
116355 |
|
14-Jun-2003 |
alc |
Migrate the thread stack management functions from the machine-dependent to the machine-independent parts of the VM. At the same time, this introduces vm object locking for the non-i386 platforms.
Two details:
1. KSTACK_GUARD has been removed in favor of KSTACK_GUARD_PAGES. The different machine-dependent implementations used various combinations of KSTACK_GUARD and KSTACK_GUARD_PAGES. To disable guard page, set KSTACK_GUARD_PAGES to 0.
2. Remove the (unnecessary) clearing of PG_ZERO in vm_thread_new. In 5.x, (but not 4.x,) PG_ZERO can only be set if VM_ALLOC_ZERO is passed to vm_page_alloc() or vm_page_grab().
|
#
112841 |
|
30-Mar-2003 |
jake |
- Add support for PAE and more than 4 gigs of ram on x86, dependent on the kernel opition 'options PAE'. This will only work with device drivers which either use busdma, or are able to handle 64 bit physical addresses.
Thanks to Lanny Baron from FreeBSD Systems for the loan of a test machine with 6 gigs of ram.
Sponsored by: DARPA, Network Associates Laboratories, FreeBSD Systems
|
#
112569 |
|
24-Mar-2003 |
jake |
- Add vm_paddr_t, a physical address type. This is required for systems where physical addresses larger than virtual addresses, such as i386s with PAE. - Use this to represent physical addresses in the MI vm system and in the i386 pmap code. This also changes the paddr parameter to d_mmap_t. - Fix printf formats to handle physical addresses >4G in the i386 memory detection code, and due to kvtop returning vm_paddr_t instead of u_long.
Note that this is a name change only; vm_paddr_t is still the same as vm_offset_t on all currently supported platforms.
Sponsored by: DARPA, Network Associates Laboratories Discussed with: re, phk (cdevsw change)
|
#
111363 |
|
23-Feb-2003 |
jake |
- Added macros NPGPTD, NBPTD, and NPDEPTD, for dealing with the size of the page directory. - Use these instead of the magic constants 1 or PAGE_SIZE where appropriate. There are still numerous assumptions that the page directory is exactly 1 page.
Sponsored by: DARPA, Network Associates Laboratories
|
#
103436 |
|
16-Sep-2002 |
peter |
Initiate deorbit burn for the i386-only a.out related support. Moves are under way to move the remnants of the a.out toolchain to ports. As the comment in src/Makefile said, this stuff is deprecated and one should not expect this to remain beyond 4.0-REL. It has already lasted WAY beyond that.
Notable exceptions: gcc - I have not touched the a.out generation stuff there. ldd/ldconfig - still have some code to interface with a.out rtld. old as/ld/etc - I have not removed these yet, pending their move to ports. some includes - necessary for ldd/ldconfig for now.
Tested on: i386 (extensively), alpha
|
#
102738 |
|
31-Aug-2002 |
dillon |
Reduce the maximum KVA reserved for swap meta structures from 70 to 32 MB. Reduce the swap meta calculation by a factor of 2, it's still massive overkill.
X-MFC after: immediately
|
#
96606 |
|
14-May-2002 |
phk |
Move MI stuff out of MD param.h files.
It can all still be overridden in the MD files should need suddenly arise.
|
#
83366 |
|
12-Sep-2001 |
julian |
KSE Milestone 2 Note ALL MODULES MUST BE RECOMPILED make the kernel aware that there are smaller units of scheduling than the process. (but only allow one thread per process at this time). This is functionally equivalent to teh previousl -current except that there is a thread associated with each process.
Sorry john! (your next MFC will be a doosie!)
Reviewed by: peter@freebsd.org, dillon@freebsd.org
X-MFC after: ha ha ha ha
|
#
82309 |
|
25-Aug-2001 |
peter |
Optionize UPAGES for the i386. As part of this I split some of the low level implementation stuff out of machine/globaldata.h to avoid exposing UPAGES to lots more places. The end result is that we can double the kernel stack size with 'options UPAGES=4' etc.
This is mainly being done for the benefit of a MFC to RELENG_4 at some point. -current doesn't really need this so much since each interrupt runs on its own kstack.
|
#
81933 |
|
19-Aug-2001 |
dillon |
Limit the amount of KVM reserved for the buffer cache and for swap-meta information. The default limits only effect machines with > 1GB of ram and can be overriden with two new kernel conf variables VM_SWZONE_SIZE_MAX and VM_BCACHE_SIZE_MAX, or with loader variables kern.maxswzone and kern.maxbcache. This has the effect of leaving more KVM available for sizing NMBCLUSTERS and 'maxusers' and should avoid tripups where a sysad adds memory to a machine and then sees the kernel panic on boot due to running out of KVM.
Also change the default swap-meta auto-sizing calculation to allocate half of what it was previously allocating. The prior defaults were way too high. Note that we cannot afford to run out of swap-meta structures so we still stay somewhat conservative here.
|
#
68498 |
|
08-Nov-2000 |
asmodai |
Fix CMSG and ALIGN macro usage. Previously we had to include <machine/param.h> or <sys/param.h> bogusly due to the fact that <sys/socket.h> CMSG macros needed the ALIGN macro, which was defined in param.h. However, including param.h was a disaster for namespace pollution. This solution, as contributed by shin a while ago, fixes it elegantly by wrapping the definitions around some namespace pollution preventer definitions. This patch was long overdue. This should allow any network programmer to use <sys/socket.h> as before.
PR: 19971, 20530 Submitted by: Martin Kaeske <MartinKaeske@lausitz.net> Mark Andrews <Mark.Andrews@nominum.com> Patch submitted by: shin Reviewed by: bde
|
#
67247 |
|
17-Oct-2000 |
ps |
Implement write combining for crashdumps. This is useful when write caching is disabled on both SCSI and IDE disks where large memory dumps could take up to an hour to complete.
Taking an i386 scsi based system with 512MB of ram and timing (in seconds) how long it took to complete a dump, the following results were obtained:
Before: After: WCE TIME WCE TIME ------------------ ------------------ 1 141.820972 1 15.600111 0 797.265072 0 65.480465
Obtained from: Yahoo! Reviewed by: peter
|
#
66802 |
|
08-Oct-2000 |
bmilekic |
Cleanup comment in machine/param.h regarding mbuf-related sizes, and get rid of MCLOFSET, which does not appear to be used anywhere anymore, and if it is, it probably shouldn't be.
|
#
66296 |
|
23-Sep-2000 |
ps |
Move MAXCPU from machine/smp.h to machine/param.h to fix breakage with !SMP kernels. Also, replace NCPUS with MAXCPU since they are redundant.
|
#
58763 |
|
29-Mar-2000 |
jlemon |
Change the mbuf size from 128 -> 256. Increasing the mbuf header size caused some headers not to fit in MHLEN any more. This matches the current size on the alpha, so it shouldn't cause problems.
Problem observed by: Geoff Rehmet <geoff@is.co.za> Originally suggested by: shin
|
#
54425 |
|
11-Dec-1999 |
peter |
Reclaim UPAGES_HOLE (8k) that was chopped out of process address space. The UPAGES have not been there since Jan '96, but the hole was preserved for BSD/OS binary compatability. This has been fixed other ways (%ebx now has a pointer to PS_STRINGS), and the stack is nowhere near where it used to be so this hack isn't required anymore.
|
#
51532 |
|
22-Sep-1999 |
dillon |
Back out a portion of the last commit. DFLTPHYS and MAXPHYS cannot be set by a kernel conf option due to the struct buf structural dependancy (sizing of b_pages[]) creating a conflict with modules (which are not compiled with kernel config options overrides).
We'll be able to sysctl these two later on when the buffer subsystem is revamped.
|
#
51528 |
|
22-Sep-1999 |
dillon |
Change default block size for user VBLK device access from 2K to PAGE_SIZE (4K on an i386, 8K on an alpha).
Make BLKDEV_IOSIZE, DFLTPHYS, and MAXPHYS kernel-configurable.
|
#
50477 |
|
27-Aug-1999 |
peter |
$Id$ -> $FreeBSD$
|
#
44364 |
|
01-Mar-1999 |
imp |
Don't define MACHINE, MACHINE_ARCH, _MACHINE or _MACHINE_ARCH if already defined. This allows for cross building to work because we need to lie to make to tell it to use the target names rather than the host names.
This should have no effect on either architecture. I've confirmed that the intel build by make buildworld's for the past 3 months.
|
#
44157 |
|
19-Feb-1999 |
luoqi |
Introduce machine-dependent macro pgtok() to convert page count to number of kilobytes. Its definition for each architecture could be optimized to avoid potential numerical overflows.
|
#
42367 |
|
07-Jan-1999 |
peter |
OBJFORMAT_DEFAULT = elf now. (this is where /usr/bin/objformat and libc/gen/getobjformat.c get their default from)
|
#
40286 |
|
13-Oct-1998 |
dg |
Fixed two potentially serious classes of bugs:
1) The vnode pager wasn't properly tracking the file size due to "size" being page rounded in some cases and not in others. This sometimes resulted in corrupted files. First noticed by Terry Lambert. Fixed by changing the "size" pager_alloc parameter to be a 64bit byte value (as opposed to a 32bit page index) and changing the pagers and their callers to deal with this properly. 2) Fixed a bogus type cast in round_page() and trunc_page() that caused some 64bit offsets and sizes to be scrambled. Removing the cast required adding casts at a few dozen callers. There may be problems with other bogus casts in close-by macros. A quick check seemed to indicate that those were okay, however.
|
#
38960 |
|
08-Sep-1998 |
jdp |
Add a new library function getobjformat(). It checks all the standard places ("/etc/objformat", ${OBJFORMAT}, argv) for an indication of the user's preferred object file format. This consolidates some code that was starting to be duplicated in more and more places.
Use the new function in ldconfig.
Note: I don't think that gcc should use getobjformat(), even though it could. The compiler should limit itself to functions that are widespread, to ease porting and cross-compilation.
|
#
38673 |
|
31-Aug-1998 |
kato |
- 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>
|
#
36996 |
|
15-Jun-1998 |
bde |
Oops, uoff_t can't be used here yet.
|
#
36977 |
|
14-Jun-1998 |
bde |
Removed LOCORE ifdef. This header isn't used for locore stuff.
Use uoff_t instead of `unsigned long long' for unsigned offsets.
Fixed some style bugs.
|
#
32724 |
|
24-Jan-1998 |
dyson |
Add better support for larger I/O clusters, including larger physical I/O. The support is not mature yet, and some of the underlying implementation needs help. However, support does exist for IDE devices now.
|
#
28921 |
|
30-Aug-1997 |
fsmp |
Another round of lock pushdown. Add a simplelock to deal with disable_intr()/enable_intr() as used in UP kernel. UP kernel expects that this is enough to guarantee exclusive access to regions of code bracketed by these 2 functions. Add a simplelock to bracket clock accesses in clock.c: clock_lock.
Help from: Bruce Evans <bde@zeta.org.au>
|
#
28918 |
|
30-Aug-1997 |
kato |
Move MACHINE_ARCH definition from <machine/param.h> to <machine/cpu.h>.
Submitted by: Bruce Evans <bde@zeta.org.au>
|
#
28889 |
|
29-Aug-1997 |
kato |
Fix typo in the comment introduced by me.
|
#
28885 |
|
29-Aug-1997 |
kato |
Added a sysctl arg, hw.machine_arch. The hw.machine_arch is "ibm-pc" on IBM-PC box and is "pc-98" on NEC PC-98 box. Userland program can distinguish architecture on which the program runs.
|
#
28641 |
|
23-Aug-1997 |
fsmp |
The last of the encapsolation of cpl/spl/ipending things into a critical region protected by the simplelock 'cpl_lock'.
Notes:
- this code is currently controlled on a section by section basis with defines in machine/param.h. All sections are currently enabled.
- this code is not as clean as I would like, but that can wait till later.
- the "giant lock" still surrounds most instances of this "cpl region". I still have to do the code that arbitrates setting cpl between the top and bottom halves of the kernel.
- the possibility of deadlock exists, I am committing the code at this point so as to exercise it and detect any such cases B4 the "giant lock" is removed.
|
#
28491 |
|
21-Aug-1997 |
fsmp |
Moved the COM_LOCK and COM_UNLOCK macros to machine/param.h.
|
#
28487 |
|
21-Aug-1997 |
fsmp |
Made PEND_INTS default. Made NEW_STRATEGY default. Removed misc. old cruft.
Centralized simple locks into mp_machdep.c Centralized simple lock macros into param.h
More cleanup in the direction of making splxx()/cpl MP-safe.
|
#
28354 |
|
18-Aug-1997 |
fsmp |
Turn on the lockmanager by default for SMP.
Reviewed by: "John S. Dyson" <toor@dyson.iquest.net>
|
#
27993 |
|
08-Aug-1997 |
dyson |
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>
|
#
27950 |
|
07-Aug-1997 |
dyson |
Fix the DDB breakpoint code when using the 4MB page support.
|
#
27896 |
|
04-Aug-1997 |
fsmp |
pushed down "volatility" of simplelock to actual int inside the struct.
Submitted by: bde@zeta.org.a
|
#
27663 |
|
24-Jul-1997 |
fsmp |
param.h: Macros to convert the Lite2 lock manager primitives to the names used in the kernel proper. This allows us to hide them from the lock manager till they can be turned on. smp.h: declarations for the new simplelock functions.
|
#
27633 |
|
23-Jul-1997 |
fsmp |
Forced 32bit alignment of struct simple_lock in param.h.
Added declarations of new simple_lock data and functions to smp.h.
|
#
27617 |
|
22-Jul-1997 |
fsmp |
Added a missing semicolon, compile failed when I turned on simple_lock(). Evidently this has never been compiled before, NOT a good sign...
|
#
24695 |
|
07-Apr-1997 |
peter |
Define UPAGES_HOLE at 2 (same as current UPAGES) in case UPAGES changes later. This is used to calculate the top of user address space.
|
#
22975 |
|
22-Feb-1997 |
peter |
Back out part 1 of the MCFH that changed $Id$ to $FreeBSD$. We are not ready for it yet.
|
#
22521 |
|
10-Feb-1997 |
dyson |
This is the kernel Lite/2 commit. There are some requisite userland changes, so don't expect to be able to run the kernel as-is (very well) without the appropriate Lite/2 userland changes.
The system boots and can mount UFS filesystems.
Untested: ext2fs, msdosfs, NFS Known problems: Incorrect Berkeley ID strings in some files. Mount_std mounts will not work until the getfsent library routine is changed.
Reviewed by: various people Submitted by: Jeffery Hsu <hsu@freebsd.org>
|
#
21673 |
|
14-Jan-1997 |
jkh |
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.
|
#
18770 |
|
06-Oct-1996 |
bde |
Improved the btodb() and dbtob() macros. I made them give unsigned [long long] results when I last worked on them, but they are normally used together with to daddr_t's and off_t's which are signed, so the unsigned results did little except cause warnings.
|
#
15583 |
|
03-May-1996 |
phk |
Another sweep over the pmap/vm macros, this time with more focus on the usage. I'm not satisfied with the naming, but now at least there is less bogus stuff around.
|
#
15565 |
|
02-May-1996 |
phk |
Move atdevbase out of locore.s and into machdep.c Macroize locore.s' page table setup even more, now it's almost readable. Rename PG_U to PG_A (so that I can...) Rename PG_u to PG_U. "PG_u" was just too ugly... Remove some unused vars in pmap.c Remove PG_KR and PG_KW Remove SSIZE Remove SINCR Remove BTOPKERNBASE
This concludes my spring cleaning, modulus any bug fixes for messes I have made on the way.
(Funny to be back here in pmap.c, that's where my first significant contribution to 386BSD was... :-)
|
#
15543 |
|
02-May-1996 |
phk |
removed: CLBYTES PD_SHIFT PGSHIFT NBPG PGOFSET CLSIZELOG2 CLSIZE pdei() ptei() kvtopte() ptetov() ispt() ptetoav() &c &c new: NPDEPG
Major macro cleanup.
|
#
8748 |
|
25-May-1995 |
dg |
Made "NMBCLUSTERS" calculation dynamic and fixed bogus use of "NMBCLUSTERS" in machdep.c (it should use the global nmbclusters). Moved the calculation of nmbclusters into conf/param.c (same place where nmbclusters has always been assigned), and made the calculation include an extra amount based on "maxusers". NMBCLUSTERS can still be overrided in the kernel config file as always, but this change will make that generally unnecessary. This fixes the "bug" reports from people who have misconfigured kernels seeing the network hang when the mbuf cluster pool runs out.
Reviewed by: John Dyson
|
#
6558 |
|
19-Feb-1995 |
gpalmer |
Bruces fixes for large filesystems
Submitted by: Bruce Evans <bde@zeta.org.au>
|
#
5809 |
|
23-Jan-1995 |
dg |
Decrease MCLBYTES from 4k back to 2k. It isn't likely that we'll be doing page flipping anytime soon and 4k just wastes memory. Performance via the looback interface will decrease slightly by this change. Idealy, we need buffers that can have variable sizes, but this requires a rewrite of far too much code at the moment.
|
#
2867 |
|
18-Sep-1994 |
bde |
Replace `unsigned' by `u_int' so that it is not necessary to include <sys/types.h> before including this header. This header is now idempotent.
Uniformize idempotency #ifdef.
|
#
1549 |
|
25-May-1994 |
rgrimes |
The big 4.4BSD Lite to FreeBSD 2.0.0 (Development) patch.
Reviewed by: Rodney W. Grimes Submitted by: John Dyson and David Greenman
|
#
1246 |
|
07-Mar-1994 |
dg |
1) "Pre-faulting" in of pages into process address space Eliminates vm_fault overhead on process startup and mmap referenced data for in-memory pages.
(process startup time using in-memory segments *much* faster)
2) Even more efficient pmap code. Code partially cleaned up. More comments yet to follow.
(generally more efficient pte management)
3) Pageout clustering ( in addition to the FreeBSD V1.1 pagein clustering.)
(much faster paging performance on non-write behind disk subsystems, slightly faster performance on other systems.)
4) Slightly changed vm_pageout code for more efficiency and better statistics. Also, resist swapout a little more.
(less likely to pageout a recently used page)
5) Slight improvement to the page table page trap efficiency.
(generally faster system VM fault performance)
6) Defer creation of unnamed anonymous regions pager until needed.
(speeds up shared memory bss creation)
7) Remove possible deadlock from swap_pager initialization.
8) Enhanced procfs to provide "vminfo" about vm objects and user pmaps.
9) Increased MCLSHIFT/MCLBYTES from 2K to 4K to improve net & socket performance and to prepare for things to come.
John Dyson dyson@implode.root.com David Greenman davidg@root.com
|
#
1045 |
|
31-Jan-1994 |
dg |
VM system performance improvements from John Dyson and myself. The following is a summary:
1) increased object cache back up to a more reasonable value. 2) removed old & bogus cruft from machdep.c (clearseg, copyseg, physcopyseg, etc). 3) inlined many functions in pmap.c 4) changed "load_cr3(rcr3())" into tlbflush() and made tlbflush inline assembly. 5) changed the way that modified pages are tracked - now vm_page struct is kept updated directly - no more scanning page tables. 6) removed lots of unnecessary spl's 7) removed old unused functions from pmap.c 8) removed all use of page_size, page_shift, page_mask variables - replaced with PAGE_ constants. 9) moved trunc/round_page, atop, ptoa, out of vm_param.h and into i386/ include/param.h, and optimized them. 10) numerous changes to sys/vm/ swap_pager, vnode_pager, pageout, fault code to improve performance. LRU algorithm modified to be more effective, read ahead/behind values tuned for better performance, etc, etc...
|
#
974 |
|
14-Jan-1994 |
dg |
"New" VM system from John Dyson & myself. For a run-down of the major changes, see the log of any effected file in the sys/vm directory (swap_pager.c for instance).
|
#
879 |
|
18-Dec-1993 |
wollman |
Make everything compile with -Wtraditional. Make it easier to distribute a binary link-kit. Make all non-optional options (pagers, procfs) standard, and update LINT to reflect new symtab requirements.
NB: -Wtraditional will henceforth be forgotten. This editing pass was primarily intended to detect any constructions where the old code might have been relying on traditional C semantics or syntax. These were all fixed, and the result of fixing some of them means that -Wall is now a realistic possibility within a few weeks.
|
#
785 |
|
18-Nov-1993 |
rgrimes |
New version of scsi code from Julian
|
#
757 |
|
13-Nov-1993 |
dg |
First steps in rewriting locore.s, and making info useful when the machine panics.
i386/i386/locore.s: 1) got rid of most .set directives that were being used like #define's, and replaced them with appropriate #define's in the appropriate header files (accessed via genassym). 2) added comments to header inclusions and global definitions, and global variables 3) replaced some hardcoded constants with cpp defines (such as PDESIZE and others) 4) aligned all comments to the same column to make them easier to read 5) moved macro definitions for ENTRY, ALIGN, NOP, etc. to /sys/i386/include/asmacros.h 6) added #ifdef BDE_DEBUGGER around all of Bruce's debugger code 7) added new global '_KERNend' to store last location+1 of kernel 8) cleaned up zeroing of bss so that only bss is zeroed 9) fix zeroing of page tables so that it really does zero them all - not just if they follow the bss. 10) rewrote page table initialization code so that 1) works correctly and 2) write protects the kernel text by default 11) properly initialize the kernel page directory, upages, p0stack PT, and page tables. The previous scheme was more than a bit screwy. 12) change allocation of virtual area of IO hole so that it is fixed at KERNBASE + 0xa0000. The previous scheme put it right after the kernel page tables and then later expected it to be at KERNBASE +0xa0000 13) change multiple bogus settings of user read/write of various areas of kernel VM - including the IO hole; we should never be accessing the IO hole in user mode through the kernel page tables 14) split kernel support routines such as bcopy, bzero, copyin, copyout, etc. into a seperate file 'support.s' 15) split swtch and related routines into a seperate 'swtch.s' 16) split routines related to traps, syscalls, and interrupts into a seperate file 'exception.s' 17) remove some unused global variables from locore that got inserted by Garrett when he pulled them out of some .h files.
i386/isa/icu.s: 1) clean up global variable declarations 2) move in declaration of astpending and netisr
i386/i386/pmap.c: 1) fix calculation of virtual_avail. It previously was calculated to be right in the middle of the kernel page tables - not a good place to start allocating kernel VM. 2) properly allocate kernel page dir/tables etc out of kernel map - previously only took out 2 pages.
i386/i386/machdep.c: 1) modify boot() to print a warning that the system will reboot in PANIC_REBOOT_WAIT_TIME amount of seconds, and let the user abort with a key on the console. The machine will wait for ever if a key is typed before the reboot. The default is 15 seconds, but can be set to 0 to mean don't wait at all, -1 to mean wait forever, or any positive value to wait for that many seconds. 2) print "Rebooting..." just before doing it.
kern/subr_prf.c: 1) remove PANICWAIT as it is deprecated by the change to machdep.c
i386/i386/trap.c: 1) add table of trap type strings and use it to print a real trap/ panic message rather than just a number. Lot's of work to be done here, but this is the first step. Symbolic traceback is in the TODO.
i386/i386/Makefile.i386: 1) add support in to build support.s, exception.s and swtch.s
...and various changes to various header files to make all of the above happen.
|
#
719 |
|
07-Nov-1993 |
wollman |
Made all header files idempotent and moved incorrect common data from headers into a related source file. Added cons.h as first step towards moving i386/i386/cons.h to machine/cons.h where it belongs.
|
#
607 |
|
15-Oct-1993 |
rgrimes |
param.h:
Mark the fact that PGSHIFT and PDRSHIFT are really the same as PG_SHIFT and PD_SHIFT, these should be collapsed some day soon.
Document that KERNBASE should really be KPTDPTDI << PDRSHIFT, for now leave it as the constant 0xFE000000 until I make a seperate common header file for this stuff (vmaddresses.h?)
Remove NKMEMCLUSTERS define, it was only being used to define VM_KMEM_SIZE, so why have all the indirection. Besides who wants to work in CLBYTE sizes chuncks.
pmap.h:
Fix $Id$ and some other minor format clean ups.
Remove the XXX comment about NKPDE, since it now has the correct value of 7.
Remove unused LASTPTDI and move the APTD into the very end of memory to free up 4MB of kernel virtual address space. Remove unused RSVDPTDI and free up 12MB of kernel virtual address space.
vmparam.h
Fix $Id$.
Increase SHMMAXPGS to 512 (2MB) now that there is room for it to be bigger. The XXX comment stays until the kernel moves down in memory to free up enough space to use the proper default of 4MB.
VM_KMEM_SIZE is now a direct constant stating the size of the kernel malloc region. Increased the value from 3MB to 16MB.
|
#
586 |
|
12-Oct-1993 |
rgrimes |
Fixed PHYSTOKV, addition operator on pointers is the wrong thing to do here. This is really a crock, but it works.
|
#
584 |
|
12-Oct-1993 |
rgrimes |
Add PHYSTOKV used in scsi drivers with a correct definition based on KERNBASE.
Change #define<tab> to #define<space> on lines that had it wrong
|
#
552 |
|
08-Oct-1993 |
rgrimes |
Fix definitions to be in terms of a minimum number of constants by using the SHIFT value as the basis for the other values, for example instead of: #define NBPG 4096 #define PGSHIFT 12 use: #define PGSHIFT 12 #define NBPG (1 << PGSHIFT)
=================================================================== RCS file: /a/cvs/386BSD/src/sys/i386/include/param.h,v retrieving revision 1.3 diff -c -r1.3 param.h *** 1.3 1993/10/08 12:49:55 --- param.h 1993/10/08 12:53:19 *************** *** 52,76 **** #define ALIGNBYTES (sizeof(int) - 1) #define ALIGN(p) (((u_int)(p) + ALIGNBYTES) &~ ALIGNBYTES)
- #define NBPG 4096 /* bytes/page */ - #define PGOFSET (NBPG-1) /* byte offset into page */ #define PGSHIFT 12 /* LOG2(NBPG) */ #define NPTEPG (NBPG/(sizeof (struct pte)))
- #define NBPDR (1024*NBPG) /* bytes/page dir */ - #define PDROFSET (NBPDR-1) /* byte offset into page dir */ #define PDRSHIFT 22 /* LOG2(NBPDR) */
#define KERNBASE 0xFE000000 /* start of kernel virtual */ #define BTOPKERNBASE ((u_long)KERNBASE >> PGSHIFT)
! #define DEV_BSIZE 512 #define DEV_BSHIFT 9 /* log2(DEV_BSIZE) */ #define BLKDEV_IOSIZE 2048 #define MAXPHYS (64 * 1024) /* max raw I/O transfer size */
- #define CLSIZE 1 #define CLSIZELOG2 0
/* NOTE: SSIZE, SINCR and UPAGES must be multiples of CLSIZE */ #define SSIZE 1 /* initial stack size/NBPG */ --- 52,79 ---- #define ALIGNBYTES (sizeof(int) - 1) #define ALIGN(p) (((u_int)(p) + ALIGNBYTES) &~ ALIGNBYTES)
#define PGSHIFT 12 /* LOG2(NBPG) */ + #define NBPG (1 << PGSHIFT) /* bytes/page */ + #define PGOFSET (NBPG-1) /* byte offset into page */ #define NPTEPG (NBPG/(sizeof (struct pte)))
#define PDRSHIFT 22 /* LOG2(NBPDR) */ + #define NBPDR (1 << PDRSHIFT) /* bytes/page dir */ + #define PDROFSET (NBPDR-1) /* byte offset into page dir */
#define KERNBASE 0xFE000000 /* start of kernel virtual */ #define BTOPKERNBASE ((u_long)KERNBASE >> PGSHIFT)
! #define KERNSIZE 0x00C00000 /* size of kernel virtual */ ! #define DEV_BSHIFT 9 /* log2(DEV_BSIZE) */ + #define DEV_BSIZE (1 << DEV_BSHIFT) + #define BLKDEV_IOSIZE 2048 #define MAXPHYS (64 * 1024) /* max raw I/O transfer size */
#define CLSIZELOG2 0 + #define CLSIZE (1 << CLSIZELOG2)
/* NOTE: SSIZE, SINCR and UPAGES must be multiples of CLSIZE */ #define SSIZE 1 /* initial stack size/NBPG */ *************** *** 92,99 **** #ifndef MCLSHIFT #define MCLSHIFT 11 /* convert bytes to m_buf clusters */ #endif /* MCLSHIFT */ ! #define MCLBYTES (1 << MCLSHIFT) /* size of a m_buf cluster */ ! #define MCLOFSET (MCLBYTES - 1) /* offset within a m_buf cluster */
#ifndef NMBCLUSTERS #ifdef GATEWAY --- 95,102 ---- #ifndef MCLSHIFT #define MCLSHIFT 11 /* convert bytes to m_buf clusters */ #endif /* MCLSHIFT */ ! #define MCLBYTES (1 << MCLSHIFT) /* size of an m_buf cluster */ ! #define MCLOFSET (MCLBYTES - 1) /* offset within an m_buf cluster */
#ifndef NMBCLUSTERS #ifdef GATEWAY
|
#
551 |
|
08-Oct-1993 |
rgrimes |
Removed patch kit header. Cleaned up tabbing and removed extra blank lines to match NetBSD. Added $Id$. Added MID_MACHINE from NetBSD. Removed definition of DELAY() for non-kernel soures. Fixed some small english errors that had been corrected in NetBSD. File is now identical to NetBSD's, but will be changing soon for some of my clean up work.
|
#
203 |
|
27-Jul-1993 |
nate |
fts(3) integration patches
|
#
5 |
|
12-Jun-1993 |
rgrimes |
This commit was generated by cvs2svn to compensate for changes in r4, which included commits to RCS files with non-trunk default branches.
|
#
4 |
|
12-Jun-1993 |
rgrimes |
Initial import, 0.1 + pk 0.2.4-B1
|