summaryrefslogtreecommitdiffstats
path: root/sys/powerpc
Commit message (Collapse)AuthorAgeFilesLines
* The kernel side of per-process unaligned access control (printing, fixing &gallatin2000-01-162-2/+2
| | | | | | | | | delivering SIGBUS). This will allow a non-superuser to control unaligned access behaviour on a per-process basis once a userland control program (uac) is written. Reviewed by: obrien Tested by: obrien
* Sync with i386marcel2000-01-081-2/+1
| | | | | | | | | | | | | | \begin{quote} Compile genassym.c with ordinary ${CFLAGS}. The (small) needs for ${GEN_CFLAGS} and -U_KERNEL became negative when all all the genassym.c's were converted to be cross-built. Makefile.*: - Cleanups associated with the old genassym. - Fixed deprecated spelling of ${.IMPSRC} as "$<". \end{quote} Submitted by: bde
* Use genassym(1).marcel2000-01-071-107/+92
|
* Revert back all the way to 1.11 - the problem was that Makefile.alpha waspeter2000-01-071-0/+3
| | | | out of sync.
* Don't include <sys/systm.h>. It doesn't do anything, and with recentmsmith2000-01-071-1/+0
| | | | changes it breaks building genassym.
* untangle some includes and clean up for compilation cleanliness.mjacob2000-01-031-3/+1
|
* Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL"peter1999-12-293-6/+6
| | | | | | 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.
* Make this compile again. (missing #include for RFPROC)peter1999-12-062-0/+2
|
* User ldt sharing.luoqi1999-12-062-2/+10
|
* Use %ll instead of %q as gcc moans bitterly about it.peter1999-11-221-1/+1
|
* Re-organise the code which manages the owner of the FP state (fpcurproc).dfr1999-11-102-24/+16
| | | | | | | | | | | | | | | The old code was spread out through the machdep code and was sloppy about enabling and disabling the FEN bit (which controls access to the FP register set). This caused a DIAGNOSTIC warning "DANGER WILL ROBINSON: FEN SET IN cpu_fork!" sometimes when operating under high loads and could conceivably lead to processes getting incorrect FP results. The new code is much more strict about the FEN bit and makes sure that *only* fpcurproc ever has it enabled. This also allows us to remove a section of code from the exception_return path which might improve performance marginally. Reviewed by: gallatin
* The core of this patch is to vm/vm_page.h. The effects are two-fold: (1) toalc1999-10-302-4/+4
| | | | | | | | | eliminate an extra (useless) level of indirection in half of the page queue accesses and (2) to use a single name for each queue throughout, instead of, e.g., "vm_page_queue_active" in some places and "vm_page_queues[PQ_ACTIVE]" in others. Reviewed by: dillon
* useracc() the prequel:phk1999-10-292-2/+0
| | | | | | | | | | | Merge the contents (less some trivial bordering the silly comments) of <vm/vm_prot.h> and <vm/vm_inherit.h> into <vm/vm.h>. This puts the #defines for the vm_inherit_t and vm_prot_t types next to their typedefs. This paves the road for the commit to follow shortly: change useracc() to use VM_PROT_{READ|WRITE} rather than B_{READ|WRITE} as argument.
* * Implement bus_set/get/delete_resource for pci.dfr1999-10-141-2/+1
| | | | | | | * Change the hack used on the alpha for mapping devices into DENSE or BWX memory spaces to a simpler one. Its still a hack and should be a seperate api to explicitly map the resource. * Add $FreeBSD$ as necessary.
* sigset_t change (part 3 of 5)marcel1999-09-291-0/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | ----------------------------- By introducing a new sigframe so that the signal handler operates on the new siginfo_t and on ucontext_t instead of sigcontext, we now need two version of sendsig and sigreturn. A flag in struct proc determines whether the process expects an old sigframe or a new sigframe. The signal trampoline handles which sigreturn to call. It does this by testing for a magic cookie in the frame. The alpha uses osigreturn to implement longjmp. This means that osigreturn is not only used for compatibility with existing binaries. To handle the new sigset_t, setjmp saves it in sc_reserved (see NOTE). the struct sigframe has been moved from frame.h to sigframe.h to handle the complex header dependencies that was caused by the new sigframe. NOTE: For the i386, the size of jmp_buf has been increased to hold the new sigset_t. On the alpha this has been prevented by using sc_reserved in sigcontext.
* Fix bug in pipe code relating to writes of mmap'd but illegal addressdillon1999-09-202-6/+10
| | | | | | | | | spaces which cross a segment boundry in the page table. pmap_kextract() is not designed for access to the user space portion of the page table and cannot handle the null-page-directory-entry case. The fix is to have vm_fault_quick() return a success or failure which is then used to avoid calling pmap_kextract().
* $Id$ -> $FreeBSD$peter1999-08-2811-11/+11
|
* Fix the child's return path from fork so that fork will return 0gallatin1999-08-272-8/+8
| | | | | | | | | in the child. This corrects a problem where linux/alpha binaries see the child's return value of fork as the parent's pid. This happens because linux/alpha binaries apparently check the return value directly, rather than looking for a non-zero value in a4, as *BSD & OSF/1 do. Reviewed by:dfr@nlsystems.com
* Fix a nasty kld bug where modules with objects of type GLOB_DAT which hadgallatin1999-08-201-1/+2
| | | | non-zero addends were being loaded incorrectly
* Update for MI switch code, and trim a heap of unused (I believe) entries.peter1999-08-191-44/+1
|
* Sync with alc's revision 1.125 of i386/i386/vm_machdep.c. Thisjdp1999-08-052-6/+6
| | | | fixes the kernel build breakage.
* Add support for SYS_RES_DENSE and SYS_RES_BWX resource types. These aredfr1999-07-281-4/+6
| | | | | | | | | equivalent to SYS_RES_MEMORY for x86 but for alpha, the rman_get_virtual() address of the resource is initialised to point into either dense-mapped or bwx-mapped space respectively, allowing direct memory pointers to be used to device memory. Reviewed by: Andrew Gallatin <gallatin@cs.duke.edu>
* Reduce the number of "magic constants" used for page coloringalc1999-07-222-4/+4
| | | | | by one: PQ_PRIME2 and PQ_PRIME3 are used to accomplish the same thing at different places in the kernel. Drop PQ_PRIME3.
* Handle R_ALPHA_NONE relocations in KLD.dfr1999-07-161-1/+4
|
* Add in dbregs stubs that a committer for changes on the i386 ought to have done.mjacob1999-07-091-1/+20
| | | | PR: 12579
* Implement support for hardware debug registers on the i386.jlemon1999-07-091-1/+3
| | | | Submitted by: Brian Dean <brdean@unx.sas.com>
* Add alpha_platform_setup_ide_intr() and alpha_platform_assign_pciintr()peter1999-07-011-1/+6
| | | | prototypes.
* Declare busdma_swi() like on i386 version.peter1999-07-011-1/+2
|
* Slight reorganization of kernel thread/process creation. Instead of usingpeter1999-07-012-6/+6
| | | | | | | | | | | | | | | SYSINIT_KT() etc (which is a static, compile-time procedure), use a NetBSD-style kthread_create() interface. kproc_start is still available as a SYSINIT() hook. This allowed simplification of chunks of the sysinit code in the process. This kthread_create() is our old kproc_start internals, with the SYSINIT_KT fork hooks grafted in and tweaked to work the same as the NetBSD one. One thing I'd like to do shortly is get rid of nfsiod as a user initiated process. It makes sense for the nfs client code to create them on the fly as needed up to a user settable limit. This means that nfsiod doesn't need to be in /sbin and is always "available". This is a fair bit easier to do outside of the SYSINIT_KT() framework.
* Revert back to not using -DKERNELpeter1999-06-281-1/+3
|
* Make genassym compile - the recent buf locking changes meant that morepeter1999-06-261-9/+2
| | | | things from #ifdef KERNEL were needed.
* Replace my previous fix of saving the FP state with a much simpler one: whendt1999-06-102-8/+4
| | | | | | we swap out fpcurproc, save its FP state. Suggested by: bde
* Keep fpcurproc locked in memory, so that we always can save the FP statedt1999-06-082-4/+8
| | | | | | | | correctly. This should fix the "pmap_changebit didn't" panic that some people see. Reviewed by: dfr
* Fixed style bugs in previous commit.bde1999-05-222-10/+10
|
* Set CHAR_{MIN,MAX} according to -funsigned-char flag given or notache1999-05-202-6/+18
| | | | | PR: 11627 Submitted by: Petr Lampa <lampa@fee.vutbr.cz>
* Fixed several (not all) warnings.dt1999-04-233-8/+6
|
* Added consts to cpu_set_fork_handler prototype. (Follow i386 version.)dt1999-04-202-6/+6
|
* unifdef -DVM_STACK - it's been on for a while for x86 and was checkedpeter1999-04-192-112/+2
| | | | and appeared to be working for the Alpha some time ago.
* Removed all traces of `p_switchtime'. The relevant timestamp is per-cpu,bde1999-02-281-2/+1
| | | | | | | | | | | | | not per-process. Keep it in `switchtime' consistently. It is now clear that the timestamp is always valid in fork_trampoline() except when the child is running on a previously idle cpu, which can only happen if there are multiple cpus, so don't check or set the timestamp in fork_trampoline except in the (i386) SMP case. Just remove the alpha code for setting it unconditionally, since there is no SMP case for alpha and the code had rotted. Parts reviewed by: dfr, phk
* Adjust idle zero-page fill hysteresis based on tests. Use 2/3 and 4/5dillon1999-02-082-8/+16
| | | | | | | zero-fill levels. Adjust comment for ozfod in vmmeter.h - this counter represents non-optimal ( on the fly ) zero fills, not prefills.
* Add hysteresis to alpha version of vm_page_zero_idle().dillon1999-02-082-28/+34
|
* Rip out PQ_ZERO queue. PQ_ZERO functionality is now combined in withdillon1999-02-082-12/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | PQ_FREE. There is little operational difference other then the kernel being a few kilobytes smaller and the code being more readable. * vm_page_select_free() has been *greatly* simplified. * The PQ_ZERO page queue and supporting structures have been removed * vm_page_zero_idle() revamped (see below) PG_ZERO setting and clearing has been migrated from vm_page_alloc() to vm_page_free[_zero]() and will eventually be guarenteed to remain tracked throughout a page's life ( if it isn't already ). When a page is freed, PG_ZERO pages are appended to the appropriate tailq in the PQ_FREE queue while non-PG_ZERO pages are prepended. When locating a new free page, PG_ZERO selection operates from within vm_page_list_find() ( get page from end of queue instead of beginning of queue ) and then only occurs in the nominal critical path case. If the nominal case misses, both normal and zero-page allocation devolves into the same _vm_page_list_find() select code without any specific zero-page optimizations. Additionally, vm_page_zero_idle() has been revamped. Hysteresis has been added and zero-page tracking adjusted to conform with the other changes. Currently hysteresis is set at 1/3 (lo) and 1/2 (hi) the number of free pages. We may wish to increase both parameters as time permits. The hysteresis is designed to avoid silly zeroing in borderline allocation/free situations.
* Mostly remove the VM_STACK OPTION.julian1999-01-262-2/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This changes the definitions of a few items so that structures are the same whether or not the option itself is enabled. This allows people to enable and disable the option without recompilng the world. As the author says: |I ran into a problem pulling out the VM_STACK option. I was aware of this |when I first did the work, but then forgot about it. The VM_STACK stuff |has some code changes in the i386 branch. There need to be corresponding |changes in the alpha branch before it can come out completely. what is done: | |1) Pull the VM_STACK option out of the header files it appears in. This |really shouldn't affect anything that executes with or without the rest |of the VM_STACK patches. The vm_map_entry will then always have one |extra element (avail_ssize). It just won't be used if the VM_STACK |option is not turned on. | |I've also pulled the option out of vm_map.c. This shouldn't harm anything, |since the routines that are enabled as a result are not called unless |the VM_STACK option is enabled elsewhere. | |2) Add what appears to be appropriate code the the alpha branch, still |protected behind the VM_STACK switch. I don't have an alpha machine, |so we would need to get some testers with alpha machines to try it out. | |Once there is some testing, we can consider making the change permanent |for both i386 and alpha. | [..] | |Once the alpha code is adequately tested, we can pull VM_STACK out |everywhere. | Submitted by: "Richard Seaman, Jr." <dick@tar.com>
* Various changes to support OSF1 emulation:dfr1998-12-302-10/+10
| | | | | | | | | | | * Move the user stack from VM_MAXUSER_ADDRESS to a place below the 32bit boundary (needed to support 32bit OSF programs). This should also save one pagetable per process. * Add cvtqlsv to the set of instructions handled by the floating point software completion code. * Disable all floating point exceptions by default. * A minor change to execve to allow the OSF1 image activator to support dynamic loading.
* Removed bogus casts of USRSTACK and/or the other operand in binarybde1998-12-162-8/+8
| | | | expressions involving USRSTACK.
* Implement 'software completion' for floating point arithmetic. On thedfr1998-12-042-2/+26
| | | | | | | | | | | | | | | | | | alpha, operations involving non-finite numbers or denormalised numbers or operations which should generate such numbers will cause an arithmetic exception. For programs which follow some strict code generation rules, the kernel trap handler can then 'complete' the operation by emulating the faulting instruction. To use software completion, a program must be compiled with the arguments '-mtrap-precision=i' and '-mfp-trap-mode=su' or '-mfp-trap-mode=sui'. Programs compiled in this way can use non-finite and denormalised numbers at the expense of slightly less efficient code generation of floating point instructions. Programs not compiled with these options will receive a SIGFPE signal when non-finite or denormalised numbers are used or generated. Reviewed by: John Polstra <jdp@polstra.com>
* * Add hooks to allow the X server to access I/O ports and memory.dfr1998-11-151-1/+7
| | | | | | | | | * Update drivers to the latest version of the bus interface. The ISA drivers' use of the new resource api is minimal. Garrett has some much cleaner drivers which should be more easily shared between i386 and alpha. This has only been tested on cia based machines. It should work on lca and apecs but I might have broken something.
* Add the ability to specify where on the at_shutdown queue a handler ismsmith1998-10-301-2/+1
| | | | | | | | | installed. Remove cpu_power_down, and replace it with an entry at the end of the SHUTDOWN_FINAL queue in the only place it's used (APM). Submitted by: Some ideas from Bruce Walter <walter@fortean.com>
* A small fragment of new ISA framework: manifest constants for the resourceswollman1998-10-291-0/+43
| | | | implemented by the i386 root nexus.
* R_ALPHA_RELATIVE relocations need to add the value to the existing memorydfr1998-10-181-3/+3
| | | | contents.
OpenPOWER on IntegriCloud