#
259065 |
|
07-Dec-2013 |
gjb |
- Copy stable/10 (r259064) to releng/10.0 as part of the 10.0-RELEASE cycle. - Update __FreeBSD_version [1] - Set branch name to -RC1
[1] 10.0-CURRENT __FreeBSD_version value ended at '55', so start releng/10.0 at '100' so the branch is started with a value ending in zero.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
#
256281 |
|
10-Oct-2013 |
gjb |
Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation
|
#
223485 |
|
23-Jun-2011 |
nwhitehorn |
Use the ABI-mandated thread pointer register (r2 for ppc32, r13 for ppc64) instead of a PCPU field for curthread. This averts a race on SMP systems with a high interrupt rate where the thread looking up the value of curthread could be preempted and migrated between obtaining the PCPU pointer and reading the value of pc_curthread, resulting in curthread being observed to be the current thread on the thread's original CPU. This played merry havoc with the system, in particular with mutexes. Many thanks to jhb for helping me work this one out.
Note that Book-E is in principle susceptible to the same problem, but has not been modified yet due to lack of Book-E hardware.
MFC after: 2 weeks
|
#
214749 |
|
03-Nov-2010 |
nwhitehorn |
Fix two mistakes on 32-bit systems. The slbmte code in syscall() is 64-bit only, and should be protected with an ifdef, and the no-execute bit in 32-bit set_user_sr() should be set before the comparison, not after, or it will never match.
|
#
214739 |
|
03-Nov-2010 |
nwhitehorn |
Clean up the user segment handling code a little more. Now that set_user_sr() itself caches the user segment VSID, there is no need for cpu_switch() to do it again. This change also unifies the 32 and 64-bit code paths for kernel faults on user pages and remaps the user SLB slot on 64-bit systems when taking a syscall to avoid some unnecessary segment exception traps.
|
#
214610 |
|
31-Oct-2010 |
nwhitehorn |
Add a security nit to recent copyin/out changes: map the user segment no-execute in case of exploitable kernel bugs.
MFC after: 1 week
|
#
214607 |
|
31-Oct-2010 |
nwhitehorn |
Next-to-leading-order perturbation of synchronization operations for switching the user segment register. All races should now be closed and a minimum of pipelines flushes be required to close them.
|
#
214574 |
|
30-Oct-2010 |
nwhitehorn |
Restructure the way the copyin/copyout segment is stored to prevent a concurrency bug. Since all SLB/SR entries were invalidated during an exception, a decrementer exception could cause the user segment to be invalidated during a copyin()/copyout() without a thread switch that would cause it to be restored from the PCB, potentially causing the operation to continue on invalid memory. This is now handled by explicit restoration of segment 12 from the PCB on 32-bit systems and a check in the Data Segment Exception handler on 64-bit.
While here, cause copyin()/copyout() to check whether the requested user segment is already installed, saving some pipeline flushes, and fix the synchronization primitives around the mtsr and slbmte instructions to prevent accessing stale segments.
MFC after: 2 weeks
|
#
212715 |
|
15-Sep-2010 |
nwhitehorn |
Replace the SLB backing store splay tree used on 64-bit PowerPC AIM hardware with a lockless sparse tree design. This marginally improves the performance of PMAP and allows copyin()/copyout() to run without acquiring locks when used on wired mappings.
Submitted by: mdf
|
#
209975 |
|
13-Jul-2010 |
nwhitehorn |
MFppc64:
Kernel sources for 64-bit PowerPC, along with build-system changes to keep 32-bit kernels compiling (build system changes for 64-bit kernels are coming later). Existing 32-bit PowerPC kernel configurations must be updated after this change to specify their architecture.
|
#
198724 |
|
31-Oct-2009 |
nwhitehorn |
Fix a race in casuword() exposed by csup. casuword() non-atomically read the current value of its argument before atomically replacing it, which could occasionally return the wrong value on an SMP system. This resulted in user mutex operations hanging when using threaded applications.
|
#
174599 |
|
14-Dec-2007 |
marcel |
Forced commit to record that this file was repocopied from src/sys/powerpc/powerpc and modified for its new location.
|
#
163488 |
|
18-Oct-2006 |
grehan |
Fix remaining compile error.
|
#
163472 |
|
18-Oct-2006 |
davidxu |
Attempt to fix compiling problem.
Noticed by: tinderbox
|
#
163449 |
|
17-Oct-2006 |
davidxu |
o Add keyword volatile for user mutex owner field. o Fix type consistent problem by using type long for old umtx and wait channel. o Rename casuptr to casuword.
|
#
161675 |
|
28-Aug-2006 |
davidxu |
Implement casuword32, compare and set user integer, thank Marcel Moolenarr who wrote the IA64 version of casuword32.
|
#
139825 |
|
07-Jan-2005 |
imp |
/* -> /*- for license, minor formatting changes
|
#
126474 |
|
02-Mar-2004 |
grehan |
Kernel changes for libthr (and probably libpthread).
include/ucontext.h - remove trapframe and switch over to 'generic' description of machine state. Include version field to help with future modifications. Include floating point and altivec state, and hopefully align correctly
powerpc/copyinout.c - fill out casuptr() sync primitive, required by kern_umtx.c
powerpc/machdep.c - shifted proc0/thread0/pcpu setup to before cninit, since syscons -> make_dev -> devlock requires a valid curthread - implemented get_mcontext/set_mcontext - recast sendsig/sigreturn to use get/set_mcontext and new ucontext struct. floating point now saved - TODO: save/restore altivec state
powerpc/vm_machdep.c - implemented cpu_thread_setup/cpu_set_upcall/cpu_set_upcall_kse - eliminated trailing whitespace
Submitted by: Suleiman Souhlal <refugee@segfaulted.com>, ucontext by grehan
|
#
125687 |
|
11-Feb-2004 |
grehan |
Cleaned up param.h:
- culled long-dead #define's - segment register defs moved to sr.h - NPMAPS moved to pmap.h - KERNBASE moved to vmparam.h - removed include of <machine/cpu.h> and fixed src files that relied on this.
Modifying segment register code no longer causes gcc rebuilds :-)
|
#
113038 |
|
03-Apr-2003 |
obrien |
Use __FBSDID rather than rcsid[].
|
#
108942 |
|
08-Jan-2003 |
grehan |
Fix incorrect error returns and sign-extension.
Approved by: benno
|
#
98480 |
|
20-Jun-2002 |
peter |
Deorbit suibyte(). It was only used for split address space systems for supporting UIO_USERISPACE (ie: it wasn't used).
|
#
97342 |
|
27-May-2002 |
benno |
Use correct types in [sf]uword32.
|
#
97307 |
|
26-May-2002 |
dfr |
Add declarations of suword32 and suword64. Add implementations of one or the other (or both) to all the platforms. Similar for fuword32 and fuword64.
|
#
96251 |
|
09-May-2002 |
benno |
- Add a prototype for the setfault() function. - Remove some stray printf()s.
|
#
95714 |
|
29-Apr-2002 |
benno |
- Add back calls to setfault that were removed when these functions were moved.
|
#
92916 |
|
21-Mar-2002 |
benno |
Collect all functions for copying to and from userspace into the one file.
This allows me to reimplement [sf]u{byte,word} as separate functions and not as calls to copy{in,out}.
|