[Devel] Re: [PATCH] c/r: tolerate X86_EFLAGS_RF on restart

Serge E. Hallyn serue at us.ibm.com
Thu Oct 29 07:31:25 PDT 2009


Quoting Oren Laadan (orenl at librato.com):
> 
> After reading the code a bit more, and seeing that:
> 
> 1) ptrace uses the debugreg of a process so may be interested in
> that particular flag, and
> 
> 2) even without ptrace userspace can set that flag (by suitably
> setting the restore context from a signal handler)
> 
> I now think that we should instead:
> 
> 1) Keep the X86_EFLAGS_RF from the time of checkpoint *as is*
> 
> 2) If the restarting task already has this flag set prior to
> restoring eflags from the saved value, then preserve the existing
> flag even if at the time of checkpoint it wasn't set.
> 
> Unless someones yells, I'll commit this soon.

As it stands (looking at arch/x86/kernel/ptrace.c) it looks like
userspace with no privilege can set the bit right?  I think your
proposal sounds best.

-serge
_______________________________________________
Containers mailing list
Containers at lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/containers




More information about the Devel mailing list