Re: [PATCH] x86, vm86: fix preemption bug for int3 breakpointhandlers.

From: Thomas Gleixner
Date: Mon May 25 2009 - 06:39:30 EST


Bart,

On Sun, 24 May 2009, Bart Oldeman wrote:
> diff --git a/arch/x86/kernel/vm86_32.c b/arch/x86/kernel/vm86_32.c
> index b8035a0..17c7734 100644
> --- a/arch/x86/kernel/vm86_32.c
> +++ b/arch/x86/kernel/vm86_32.c
> @@ -551,8 +551,12 @@ cannot_handle:
> int handle_vm86_trap(struct kernel_vm86_regs *regs, long error_code, int
> trapno)
> {
> if (VMPI.is_vm86pus) {
> - if ((trapno == 3) || (trapno == 1))
> + if ((trapno == 3) || (trapno == 1)) {
> + /* re-enable preemption: return_to_32bit()
> + jumps straight to entry_32.S */
> + dec_preempt_count();

This will break other callers of handle_vm86_trap().

Thanks,

tglx


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/