Re: [PATCH v6 08/10] x86, mpx: add prctl commands PR_MPX_REGISTER, PR_MPX_UNREGISTER

2014-06-23 Thread Dave Hansen
On 06/23/2014 05:01 PM, Andy Lutomirski wrote: > I suspect that the existence of the get operation matters more. What > if the checkpointed process has the cached copy out of sync with the > register copy? More realistically, what if the checkpointed process > doesn't want to use kernel MPX assis

Re: [PATCH v6 08/10] x86, mpx: add prctl commands PR_MPX_REGISTER, PR_MPX_UNREGISTER

2014-06-23 Thread Andy Lutomirski
On Mon, Jun 23, 2014 at 4:42 PM, Dave Hansen wrote: > On 06/23/2014 03:00 PM, Andy Lutomirski wrote: >> Hmm. How about PR_SET/GET_MPX_BOUNDS_TABLE, to update the kernel's >> copy. No fpu magic needed. >> >> This has an added benefit: CRIU will need updating for MPX, and >> they'll appreciate hav

Re: [PATCH v6 08/10] x86, mpx: add prctl commands PR_MPX_REGISTER, PR_MPX_UNREGISTER

2014-06-23 Thread Dave Hansen
On 06/23/2014 03:00 PM, Andy Lutomirski wrote: > Hmm. How about PR_SET/GET_MPX_BOUNDS_TABLE, to update the kernel's > copy. No fpu magic needed. > > This has an added benefit: CRIU will need updating for MPX, and > they'll appreciate having the required interface already exist. > (They'll want a

Re: [PATCH v6 08/10] x86, mpx: add prctl commands PR_MPX_REGISTER, PR_MPX_UNREGISTER

2014-06-23 Thread Andy Lutomirski
On Jun 23, 2014 1:09 PM, "Dave Hansen" wrote: > > On 06/23/2014 01:00 PM, Andy Lutomirski wrote: > > On 06/18/2014 02:44 AM, Qiaowei Ren wrote: > >> > This patch adds the PR_MPX_REGISTER and PR_MPX_UNREGISTER prctl() > >> > commands. These commands can be used to register and unregister MPX > >> >

Re: [PATCH v6 08/10] x86, mpx: add prctl commands PR_MPX_REGISTER, PR_MPX_UNREGISTER

2014-06-23 Thread Dave Hansen
On 06/23/2014 01:00 PM, Andy Lutomirski wrote: > On 06/18/2014 02:44 AM, Qiaowei Ren wrote: >> > This patch adds the PR_MPX_REGISTER and PR_MPX_UNREGISTER prctl() >> > commands. These commands can be used to register and unregister MPX >> > related resource on the x86 platform. >> > >> > The base

Re: [PATCH v6 08/10] x86, mpx: add prctl commands PR_MPX_REGISTER, PR_MPX_UNREGISTER

2014-06-23 Thread Andy Lutomirski
On 06/18/2014 02:44 AM, Qiaowei Ren wrote: > This patch adds the PR_MPX_REGISTER and PR_MPX_UNREGISTER prctl() > commands. These commands can be used to register and unregister MPX > related resource on the x86 platform. > > The base of the bounds directory is set into mm_struct during > PR_MPX_RE

Re: [PATCH v6 08/10] x86, mpx: add prctl commands PR_MPX_REGISTER, PR_MPX_UNREGISTER

2014-06-19 Thread Dave Hansen
On 06/18/2014 02:44 AM, Qiaowei Ren wrote: > +static __user void *task_get_bounds_dir(struct task_struct *tsk) > +{ > + struct xsave_struct *xsave_buf; > + > + fpu_xsave(&tsk->thread.fpu); > + xsave_buf = &(tsk->thread.fpu.state->xsave); > + if (!(xsave_buf->bndcsr.cfg_reg_u & MPX_B

[PATCH v6 08/10] x86, mpx: add prctl commands PR_MPX_REGISTER, PR_MPX_UNREGISTER

2014-06-18 Thread Qiaowei Ren
This patch adds the PR_MPX_REGISTER and PR_MPX_UNREGISTER prctl() commands. These commands can be used to register and unregister MPX related resource on the x86 platform. The base of the bounds directory is set into mm_struct during PR_MPX_REGISTER command execution. This member can be used to ch