lkml.org 
[lkml]   [2018]   [May]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH RFC] suspend: Prevent might sleep splats
On 2018-05-24 17:07:16 [+0200], Rafael J. Wysocki wrote:
> On Thu, May 24, 2018 at 4:24 PM, Sebastian Andrzej Siewior
> <bigeasy@linutronix.de> wrote:
> > From: Thomas Gleixner <tglx@linutronix.de>
> >
> > timekeeping suspend/resume calls read_persistent_clock() which takes
> > rtc_lock. That results in might sleep warnings because at that point
> > we run with interrupts disabled.
> >
> > We cannot convert rtc_lock to a raw spinlock as that would trigger
> > other might sleep warnings.
> >
> > As a workaround we disable the might sleep warnings by setting
> > system_state to SYSTEM_SUSPEND before calling sysdev_suspend() and
> > restoring it to SYSTEM_RUNNING afer sysdev_resume().
> >
> > Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> > Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
>
> Hmm. Don't we also need to cover suspend-to-idle?

Well, if you agree with the approach then I would look into it.

Sebastian

\
 
 \ /
  Last update: 2018-05-24 17:45    [W:0.050 / U:0.464 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site