Re: [PATCH v2] x86/split_lock: Sanitize userspace and guest error output

2020-06-11 Thread Sean Christopherson
On Thu, Jun 11, 2020 at 01:37:19PM -0400, Prarit Bhargava wrote: > > > On 6/8/20 1:15 PM, Sean Christopherson wrote: > > On Mon, Jun 08, 2020 at 08:21:14AM -0400, Prarit Bhargava wrote: > >> diff --git a/arch/x86/kernel/cpu/intel.c b/arch/x86/kernel/cpu/intel.c > >> index 166d7c355896..e02ec81fe1

Re: [PATCH v2] x86/split_lock: Sanitize userspace and guest error output

2020-06-11 Thread Prarit Bhargava
On 6/8/20 1:15 PM, Sean Christopherson wrote: > On Mon, Jun 08, 2020 at 08:21:14AM -0400, Prarit Bhargava wrote: >> diff --git a/arch/x86/kernel/cpu/intel.c b/arch/x86/kernel/cpu/intel.c >> index 166d7c355896..e02ec81fe1eb 100644 >> --- a/arch/x86/kernel/cpu/intel.c >> +++ b/arch/x86/kernel/cpu/

Re: [PATCH v2] x86/split_lock: Sanitize userspace and guest error output

2020-06-11 Thread Prarit Bhargava
On 6/8/20 1:15 PM, Sean Christopherson wrote: > On Mon, Jun 08, 2020 at 08:21:14AM -0400, Prarit Bhargava wrote: >> diff --git a/arch/x86/kernel/cpu/intel.c b/arch/x86/kernel/cpu/intel.c >> index 166d7c355896..e02ec81fe1eb 100644 >> --- a/arch/x86/kernel/cpu/intel.c >> +++ b/arch/x86/kernel/cpu/

Re: [PATCH v2] x86/split_lock: Sanitize userspace and guest error output

2020-06-08 Thread Sean Christopherson
On Mon, Jun 08, 2020 at 08:21:14AM -0400, Prarit Bhargava wrote: > diff --git a/arch/x86/kernel/cpu/intel.c b/arch/x86/kernel/cpu/intel.c > index 166d7c355896..e02ec81fe1eb 100644 > --- a/arch/x86/kernel/cpu/intel.c > +++ b/arch/x86/kernel/cpu/intel.c > @@ -1074,10 +1074,17 @@ static void split_loc

[PATCH v2] x86/split_lock: Sanitize userspace and guest error output

2020-06-08 Thread Prarit Bhargava
There are two problems with kernel messages in fatal mode that were found during testing of guests and userspace programs. The first is that no kernel message is output when the split lock detector is triggered with a userspace program. As a result the userspace process dies from receiving SIGBUS