Re: [Xen-devel] [PATCH 06/12] xen: arm: correctly handle vtimer traps from userspace

2015-03-26 Thread Ian Campbell
On Wed, 2015-03-25 at 18:41 +, Julien Grall wrote: > Hi Ian, > > On 25/03/15 14:22, Ian Campbell wrote: > > -static void vtimer_cntp_tval(struct cpu_user_regs *regs, uint32_t *r, int > > read) > > +static int vtimer_cntp_tval(struct cpu_user_regs *regs, uint32_t *r, int > > read) > > { > >

Re: [Xen-devel] [PATCH 06/12] xen: arm: correctly handle vtimer traps from userspace

2015-03-25 Thread Julien Grall
Hi Ian, On 25/03/15 14:22, Ian Campbell wrote: > -static void vtimer_cntp_tval(struct cpu_user_regs *regs, uint32_t *r, int > read) > +static int vtimer_cntp_tval(struct cpu_user_regs *regs, uint32_t *r, int > read) > { > struct vcpu *v = current; > s_time_t now; > > +if ( psr_m

[Xen-devel] [PATCH 06/12] xen: arm: correctly handle vtimer traps from userspace

2015-03-25 Thread Ian Campbell
Previously 32-bit userspace on 32-bit kernel and 64-bit userspace on 64-bit kernel could access these registers irrespective of whether the kernel had configured them to be allowed to. To fix this: - Userspace access to CNTP_CTL_EL0 and CNTP_TVAL_EL0 should be gated on CNTKCTL_EL1.EL0PTEN. -