Re: [PATCH] x86, traps: Fix ist_enter from userspace

Sasha Levin
2015-01-31T15:10:23Z

On 01/31/2015 08:01 AM, Andy Lutomirski wrote:
> context_tracking_user_exit() has no effect if in_interrupt() returns true,
> so ist_enter() didn't work. Fix it by calling exception_enter(), and thus
> context_tracking_user_exit(), before incrementing the preempt count.
>
> This also adds an assertion that will catch the problem reliably if
> CONFIG_PROVE_RCU=y to help prevent the bug from being reintroduced.
>
> Fixes: 959274753857 x86, traps: Track entry into and exit from IST context
> Reported-by: Sasha Levin <sasha.levin@oracle.com>
> Signed-off-by: Andy Lutomirski <luto@amacapital.net>

I was running something like that overnight, looks like it fixes the problem.

Tested-by: Sasha Levin <sasha.levin@oracle.com>

Thanks,
Sasha