summaryrefslogtreecommitdiffstats
path: root/sys/alpha
Commit message (Collapse)AuthorAgeFilesLines
* Clean up some junk. The bogus trapframe on the stack was removed from thepeter2001-06-161-7/+0
| | | | MI code in August 2000 elsewhere.
* I'm a dunce. Clean up some warnings by axeing some unused variables fromjhb2001-06-151-2/+0
| | | | the previous commit.
* Updates and tweaks to the new trace functionality:jhb2001-06-151-37/+44
| | | | | | | | | | | | | - Use db_printf() instead of printf(). - Clean up decode_syscall() to use regular if-then-else rather than goto's. - Use the same method of parsing PID's for per-process traces as the x86 code does: that is, if the address passed in is not a valid kernel address, treat it is a decimal pid. - If the pid of the current process is specified, fall back to using the "default" parameters for the trace as curproc's pcb is not valid at this point. MFC after: 1 week
* oops. prepare_usermode() died in August 2000 in the MI and x86 code.peter2001-06-151-8/+0
| | | | Issue raised by: scottl
* If we're not going to use am7990_shutdown, comment it all out.mjacob2001-06-141-0/+4
| | | | MFC after: 2 weeks
* Fix Assembler buglet: Warning: .end directive names different symbol than .entmjacob2001-06-141-1/+1
| | | | MFC after: 2 weeks
* As per comments in sys/linker_set.h:peter2001-06-141-313/+0
| | | | | | BANG! BANG! BANG! BANG! BANG! BANG! CLICK! CLICK! CLICK! CLICK! CLICK! <reload> BANG! BANG! BANG! BANG! BANG! BANG! CLICK! CLICK! CLICK! CLICK! CLICK!
* initialize mp_ncpus in cpu_mp_probe() so that if the probe fails andgallatin2001-06-131-2/+2
| | | | | | cpu_mp_start() is never called, mp_ncpus will have a non-zero value. This prevents systat from dying with an arithmatic exception caused by a divide-by-zero error on UP alphas running a GENERIC kernel.
* With this commit, I hereby pronounce gensetdefs past its use-by date.peter2001-06-132-8/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace the a.out emulation of 'struct linker_set' with something a little more flexible. <sys/linker_set.h> now provides macros for accessing elements and completely hides the implementation. The linker_set.h macros have been on the back burner in various forms since 1998 and has ideas and code from Mike Smith (SET_FOREACH()), John Polstra (ELF clue) and myself (cleaned up API and the conversion of the rest of the kernel to use it). The macros declare a strongly typed set. They return elements with the type that you declare the set with, rather than a generic void *. For ELF, we use the magic ld symbols (__start_<setname> and __stop_<setname>). Thanks to Richard Henderson <rth@redhat.com> for the trick about how to force ld to provide them for kld's. For a.out, we use the old linker_set struct. NOTE: the item lists are no longer null terminated. This is why the code impact is high in certain areas. The runtime linker has a new method to find the linker set boundaries depending on which backend format is in use. linker sets are still module/kld unfriendly and should never be used for anything that may be modular one day. Reviewed by: eivind
* Use struct device * rather than device_t for (*pci_intr_route args), sogallatin2001-06-111-1/+1
| | | | as to match other prototypes in the file.
* Supply the intpin to the platform.pci_intr_map() function. It turnsgallatin2001-06-103-0/+6
| | | | | | | out nearly every platform but the one I tested on requires the intpin to swizzle out the correct intline. tested by: Martijn Pronk <mpkisbkl@xs4all.nl> (lca_pci)
* Fix style of defines.obrien2001-06-091-25/+25
|
* Sync up to v 1.9 of NetBSD's db_trace.c to get access to thegallatin2001-06-083-72/+328
| | | | | | | | | | | greatly improved traceback code from Ross Harvey. This code requires the use of more traceback friendly temporary labels at kernel entry points, hence the changes to exception.s and asm.h Reviewed by: jhb, dfr Obtained from: NetBSD MFC after: 1 week
* hold the vm_mtx around vm_map_lookup_entry() and vm_map_findspace()gallatin2001-06-061-1/+4
|
* Apparently, the vm_mtx must be held around vm_map_find(). I'm assuminggallatin2001-06-061-0/+3
| | | | | | | that it needn't be held around vm_mmap() since vm_mmap() itself aquires it. Sleuthing by: obrien
* Nuke the various poorly maintained copies of ioctl_fd.h. The file isjoerg2001-06-061-142/+0
| | | | | not machine-dependant, thus it has been moved out (repo-copied) into <sys/fdcio.h>.
* Don't hold sched_lock across addupc_task().jhb2001-06-061-1/+1
| | | | | Reported by: David Taylor <davidt@yadt.co.uk> Submitted by: bde
* Use correct flag in test whether this interrupt handler is fast or not.mjacob2001-06-041-1/+1
| | | | | PR: 27866 Submitted by: Peter Jeremy <peter.jeremy@alcatel.com.au>
* Properly wrap mtx_intr_enable() macro in "do $bla while (0)"phk2001-06-021-1/+1
|
* Resurrect platform.pci_intr_map() and essentially undo the effects ofgallatin2001-06-0115-213/+206
| | | | | | | | | | | | | | | | | the interface conversion to platform.pci_intr_route(). I've left the platform.pci_intr_route() function pointer in place, as well as alpha_pci_route_interrupt(), but no platform currently implements it. To work around the removal of alpha_platform_assign_pciintr(cfg); from the pci probe code, I've hooked in calls to platform.pci_intr_map() in pcib_read_config (similar to the x86 APIC_IO ifdef in pci_cfgregread) for every chipset that has a platform which needs it. While here, I've removed the interupt mapping/routing code from the AS2x00 platform because its not required (it has never been present in -stable). Tested on: UP1000, Miata(GL), XP1000, AS2100, AS500
* Clean up the code exporting interrupt statistics via sysctl a bit:tmm2001-06-011-8/+0
| | | | | | | | | | | | | - move the sysctl code to kern_intr.c - do not use INTRCNT_COUNT, but rather eintrcnt - intrcnt to determine the length of the intrcnt array - move the declarations of intrnames, eintrnames, intrcnt and eintrcnt from machine-dependent include files to sys/interrupt.h - remove the hw.nintr sysctl, it is not needed. - fix various style bugs Requested by: bde Reviewed by: bde (some time ago)
* remove unneeded #include <vm/vm_map.h>gallatin2001-05-312-2/+0
|
* Backout previous revision. While it fixed many platforms, it brokegallatin2001-05-311-7/+2
| | | | | | | all alphas with devices behind ppb's. I'm working on a better solution now. Note that all alphas that use per-platform interrupt mapping are broken again (as they have been for several months)
* move wx to be part of miibus requiring chipsetsmjacob2001-05-302-2/+2
|
* GC #if 0'd calls to releasing and acquiring the old style giant kerneljhb2001-05-291-6/+0
| | | | lock.
* Remove MFS options from all example kernel configs.phk2001-05-292-2/+0
|
* One needs to introduce things with a `.file' directive before trying toobrien2001-05-283-2/+13
| | | | | do a .loc on it. BTW, the .loc needs to be in a .text section. gas 2.11.0 catches these oversights where previous versions did not.
* finally fix intr routing on alphas such as the as500 after months ofgallatin2001-05-271-2/+7
| | | | | | | | | | | | | | | | | | | breakage: - call PCIB_ROUTE_INTERRUPT() regardless of how valid the intline looks. Some alphas leave garbage in the intline and leave the intr mapping to OS platform support routines that map slots/buses to intlines - Down in the alpha pci code, first try platform.pci_intr_route() and if it doesn't exist or returns garbage, just read the intline out of config space. tested on AS500 (garbage in intline) and UP1000 (PC-like, intline is valid) Note that a nice little hack like the APIC_IO section of pci_cfgregread() is not workable. This is because the calling interface for alpha_pci_route_interrupt() requires us to figure out the bus/slot/etc from a device_t. At pci_read_device() time, we don't have a device_t for the bus/slot/func in question.
* catch up to i386: Don't acquire Giant just to print the trap and panicgallatin2001-05-251-2/+0
|
* make this compile.gallatin2001-05-251-1/+1
|
* track the One True Architecture (i386)mjacob2001-05-251-4/+4
|
* JHB would prefer the KTR examples not be in here.obrien2001-05-252-8/+0
|
* o Merge contents of struct pcred into struct ucred. Specifically, add therwatson2001-05-251-17/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | real uid, saved uid, real gid, and saved gid to ucred, as well as the pcred->pc_uidinfo, which was associated with the real uid, only rename it to cr_ruidinfo so as not to conflict with cr_uidinfo, which corresponds to the effective uid. o Remove p_cred from struct proc; add p_ucred to struct proc, replacing original macro that pointed. p->p_ucred to p->p_cred->pc_ucred. o Universally update code so that it makes use of ucred instead of pcred, p->p_ucred instead of p->p_pcred, cr_ruidinfo instead of p_uidinfo, cr_{r,sv}{u,g}id instead of p_*, etc. o Remove pcred0 and its initialization from init_main.c; initialize cr_ruidinfo there. o Restruction many credential modification chunks to always crdup while we figure out locking and optimizations; generally speaking, this means moving to a structure like this: newcred = crdup(oldcred); ... p->p_ucred = newcred; crfree(oldcred); It's not race-free, but better than nothing. There are also races in sys_process.c, all inter-process authorization, fork, exec, and exit. o Remove sigio->sio_ruid since sigio->sio_ucred now contains the ruid; remove comments indicating that the old arrangement was a problem. o Restructure exec1() a little to use newcred/oldcred arrangement, and use improved uid management primitives. o Clean up exit1() so as to do less work in credential cleanup due to pcred removal. o Clean up fork1() so as to do less work in credential cleanup and allocation. o Clean up ktrcanset() to take into account changes, and move to using suser_xxx() instead of performing a direct uid==0 comparision. o Improve commenting in various kern_prot.c credential modification calls to better document current behavior. In a couple of places, current behavior is a little questionable and we need to check POSIX.1 to make sure it's "right". More commenting work still remains to be done. o Update credential management calls, such as crfree(), to take into account new ruidinfo reference. o Modify or add the following uid and gid helper routines: change_euid() change_egid() change_ruid() change_rgid() change_svuid() change_svgid() In each case, the call now acts on a credential not a process, and as such no longer requires more complicated process locking/etc. They now assume the caller will do any necessary allocation of an exclusive credential reference. Each is commented to document its reference requirements. o CANSIGIO() is simplified to require only credentials, not processes and pcreds. o Remove lots of (p_pcred==NULL) checks. o Add an XXX to authorization code in nfs_lock.c, since it's questionable, and needs to be considered carefully. o Simplify posix4 authorization code to require only credentials, not processes and pcreds. Note that this authorization, as well as CANSIGIO(), needs to be updated to use the p_cansignal() and p_cansched() centralized authorization routines, as they currently do not take into account some desirable restrictions that are handled by the centralized routines, as well as being inconsistent with other similar authorization instances. o Update libkvm to take these changes into account. Obtained from: TrustedBSD Project Reviewed by: green, bde, jhb, freebsd-arch, freebsd-audit
* + Turn on SMP support by default (yes an Alpha SMP kernel works onobrien2001-05-252-0/+14
| | | | | uniprocessor systems, aren't Alpha's neat :-)) + Add example KTR (debugging) options.
* Make sure that all resource allocation is handled in the pcib device, notdfr2001-05-2312-119/+90
| | | | | | | | the chipset. This is already how the multi-hose systems handle resource allocation and it fixes a bug where dense and bwx memory allocations were not handled properly. Reviewed by: gallatin
* catch up to i386:gallatin2001-05-231-7/+24
| | | | | | | - remove Giant for vm related traps - don't hold Giant for MP safe syscalls Reviewed-by: jhb
* - FDESC, FIFO, NULL, PORTAL, PROC, UMAP and UNION fileru2001-05-233-3/+3
| | | | | | | | | | | | | | | systems were repo-copied from sys/miscfs to sys/fs. - Renamed the following file systems and their modules: fdesc -> fdescfs, portal -> portalfs, union -> unionfs. - Renamed corresponding kernel options: FDESC -> FDESCFS, PORTAL -> PORTALFS, UNION -> UNIONFS. - Install header files for the above file systems. - Removed bogus -I${.CURDIR}/../../sys CFLAGS from userland Makefiles.
* grab the vm mtx around exec_new_vmspace()gallatin2001-05-221-0/+2
|
* Change pmap_emulate_reference() so that it only touches the vm_pagegallatin2001-05-211-1/+9
| | | | | | | | | flags if it is safe to do so, otherwise it will just alter the pmap state (eg, clear the appropriate PG_FOx bits). This gets alpha booting in the face of the vm_mtx introduction. Reviewed by: dfr
* catch these files up to their i386 neighbors to make alpha bootgallatin2001-05-213-8/+28
| | | | prior to the vm_mtx
* fix vm_mtx related compiler warninggallatin2001-05-201-0/+1
|
* fix alpha-MD compile errors after the vm_mtx commitgallatin2001-05-2011-0/+11
|
* Style changes -- revert ordering to mostly two revs ago.obrien2001-05-181-65/+65
| | | | | | Embellish some comments, fix tab'ing. Requested by: bde
* - Move the setting of bootverbose to a MI SI_SUB_TUNABLES SYSINIT.jhb2001-05-171-5/+1
| | | | | | | | - Attach a writable sysctl to bootverbose (debug.bootverbose) so it can be toggled after boot. - Move the printf of the version string to a SI_SUB_COPYRIGHT SYSINIT just afer the display of the copyright message instead of doing it by hand in three MD places.
* Consistently define the rune types.obrien2001-05-161-4/+17
| | | | Follow NetBSD's lead and add a _BSD_MBSTATE_T_ type.
* Move the int typedefs to the top so they can be used in defining other types.obrien2001-05-161-24/+24
| | | | | | Ensure every platform has __offsetof. Make multiple inclusion detection consistent with other <platform>/include/*.h files.
* Lock the procfs functions for doing a single step and reading/writingjhb2001-05-161-28/+16
| | | | | | registers better. Hold sched_lock not only for checking the flag but also while performing the actual operation to ensure the process doesn't get swapped out by another CPU while we the operation is being performed.
* "Sir, the deorbit burn completed succesfully."jhb2001-05-151-33/+0
| | | | RIP {sys/machine}/ipl.h.
* Remove unneeded includes of sys/ipl.h and machine/ipl.h.jhb2001-05-153-3/+0
|
* Implement a few more floppy ioctl commands and IO options, namely:joerg2001-05-141-2/+18
| | | | | | | | | | | | | | | | | | | | | . FD_CLRERR clears the error counter, thus re-enables kernel error printf()s, . FD_GSTAT obtains the last FDC operation state, if any, . FDOPT_NOERRLOG (temporarily) turns off kernel printf() floppy error logging, . FDOPT_NOERROR makes the kernel ignore an FDC error, thus can enable the transfer of an erroneous sector to the user application All options are being cleared on (last) close. Prime consumer of the last features will be fdread(1), to be committed shortly. (FD_CLRERR should be wired into fdcontrol(8), but then fdcontrol(8) needs a major rewrite anyway.)
OpenPOWER on IntegriCloud