diff options
author | Renato Botelho <renato@netgate.com> | 2016-03-17 09:59:28 -0300 |
---|---|---|
committer | Renato Botelho <renato@netgate.com> | 2016-03-17 09:59:28 -0300 |
commit | 89ba6d490219156dc7e7779431d9de445220df9d (patch) | |
tree | 714514bba8b7b4581df0f7be45c61b01049b6b4f /sys/amd64 | |
parent | 56930d706911fdcf5e574a23ce39a1757907ee67 (diff) | |
parent | 3ea5fe04508eac3ddd7ebff9a4049f219d3037a6 (diff) | |
download | FreeBSD-src-89ba6d490219156dc7e7779431d9de445220df9d.zip FreeBSD-src-89ba6d490219156dc7e7779431d9de445220df9d.tar.gz |
Merge remote-tracking branch 'origin/releng/10.3' into RELENG_2_3
Diffstat (limited to 'sys/amd64')
-rw-r--r-- | sys/amd64/amd64/sys_machdep.c | 4 | ||||
-rw-r--r-- | sys/amd64/amd64/vm_machdep.c | 7 |
2 files changed, 6 insertions, 5 deletions
diff --git a/sys/amd64/amd64/sys_machdep.c b/sys/amd64/amd64/sys_machdep.c index 98d47b8..ff3bd3e 100644 --- a/sys/amd64/amd64/sys_machdep.c +++ b/sys/amd64/amd64/sys_machdep.c @@ -591,8 +591,8 @@ amd64_set_ldt(td, uap, descs) struct i386_ldt_args *uap; struct user_segment_descriptor *descs; { - int error = 0, i; - int largest_ld; + int error = 0; + unsigned int largest_ld, i; struct mdproc *mdp = &td->td_proc->p_md; struct proc_ldt *pldt; struct user_segment_descriptor *dp; diff --git a/sys/amd64/amd64/vm_machdep.c b/sys/amd64/amd64/vm_machdep.c index bcc68c0..aaa3741 100644 --- a/sys/amd64/amd64/vm_machdep.c +++ b/sys/amd64/amd64/vm_machdep.c @@ -100,8 +100,8 @@ get_pcb_user_save_td(struct thread *td) vm_offset_t p; p = td->td_kstack + td->td_kstack_pages * PAGE_SIZE - - cpu_max_ext_state_size; - KASSERT((p % 64) == 0, ("Unaligned pcb_user_save area")); + roundup2(cpu_max_ext_state_size, XSAVE_AREA_ALIGN); + KASSERT((p % XSAVE_AREA_ALIGN) == 0, ("Unaligned pcb_user_save area")); return ((struct savefpu *)p); } @@ -120,7 +120,8 @@ get_pcb_td(struct thread *td) vm_offset_t p; p = td->td_kstack + td->td_kstack_pages * PAGE_SIZE - - cpu_max_ext_state_size - sizeof(struct pcb); + roundup2(cpu_max_ext_state_size, XSAVE_AREA_ALIGN) - + sizeof(struct pcb); return ((struct pcb *)p); } |