Re: WARNING in syscall_exit_to_user_mode

From: Thomas Gleixner
Date: Mon Sep 14 2020 - 16:24:34 EST


On Mon, Sep 14 2020 at 13:06, Kees Cook wrote:
> On Sun, Sep 13, 2020 at 09:54:34PM +0200, Thomas Gleixner wrote:
>> On Sat, Sep 12 2020 at 10:52, Kees Cook wrote:
>> >> ------------[ cut here ]------------
>> >> syscall 56 left IRQs disabled
>> >
>> > This WARN appears reachable. :)
>>
>> The above is hardly a problem of the new entry code. It's just detecting
>> the wreckage...
>
> Oh, well that's actually even better! :)

Of course I can't reproduce here ...

>> > I also see on the dashboard these other problems with the new entry
>> > code:
>>
>> > https://syzkaller.appspot.com/bug?extid=d4336c84ed0099fdbe47
>>
>> This one is also just the messenger. That's the
>>
>> lockdep_assert_irqs_disabled();
>>
>> in irqentry_exit() if I'm reading the reports correctly. That's a #PF
>> returning with interrupts enabled for whatever weird reason. Let me
>> stare at that...
>
> Cool; thanks.

No idea so far.

>> > https://syzkaller.appspot.com/bug?extid=c4af95386364bc59b13e
>>
>> This one is not a new entry code problem either:
>> [...]
>> The new entry code is just in the stack trace because that task was
>> preempted after a timer interrupt.
>
> This seems a bit like the first issue: it's just getting noticed now?

IIRC, I've seen such reports on older kernels as well, but not with the
new entry code in the traces.

Thanks,

tglx