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

From: Sean Christopherson
Date: Mon Jun 15 2020 - 21:51:41 EST


On Mon, Jun 15, 2020 at 07:39:00AM -0400, Prarit Bhargava wrote:
> 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 with no indication to the user of what caused
> the process to die.
>
> The second problem is that only the first triggering guest causes a kernel
> message to be output because the message is output with pr_warn_once().
> This also results in a loss of information to the user.
>
> While fixing these I noticed that the same message was being output
> three times so I'm cleaning that up too.
>
> Fix fatal mode output, and use consistent messages for fatal and
> warn modes for both userspace and guests.
>
> Signed-off-by: Prarit Bhargava <prarit@xxxxxxxxxx>
> Signed-off-by: Sean Christopherson <sean.j.christopherson@xxxxxxxxx>

This needs a Co-developed-by for me, and your SOB should come last, e.g.

Co-developed-by: Sean Christopherson <sean.j.christopherson@xxxxxxxxx>
Signed-off-by: Sean Christopherson <sean.j.christopherson@xxxxxxxxx>
Signed-off-by: Prarit Bhargava <prarit@xxxxxxxxxx>

See "12) When to use Acked-by:, Cc:, and Co-developed-by:" in
Documentation/process/submitting-patches.rst for more details.