Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 23798
b: refs/heads/master
c: 45948d7
h: refs/heads/master
v: v3
  • Loading branch information
Jan Beulich authored and Linus Torvalds committed Mar 25, 2006
1 parent fb6a09a commit a8bcd10
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 2b514e74f4e59e3b8e54891580fef2c9ff6c7bd0
refs/heads/master: 45948d7720e8bd0104696087c6305fdd90e3b298
7 changes: 4 additions & 3 deletions trunk/arch/x86_64/kernel/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -527,8 +527,6 @@ __switch_to(struct task_struct *prev_p, struct task_struct *next_p)
int cpu = smp_processor_id();
struct tss_struct *tss = &per_cpu(init_tss, cpu);

unlazy_fpu(prev_p);

/*
* Reload esp0, LDT and the page table pointer:
*/
Expand Down Expand Up @@ -586,11 +584,14 @@ __switch_to(struct task_struct *prev_p, struct task_struct *next_p)
}

/*
* Switch the PDA context.
* Switch the PDA and FPU contexts.
*/
prev->userrsp = read_pda(oldrsp);
write_pda(oldrsp, next->userrsp);
write_pda(pcurrent, next_p);
/* This must be here to ensure both math_state_restore() and
kernel_fpu_begin() work consistently. */
unlazy_fpu(prev_p);
write_pda(kernelstack,
task_stack_page(next_p) + THREAD_SIZE - PDA_STACKOFFSET);

Expand Down

0 comments on commit a8bcd10

Please sign in to comment.