Hi, On Mon, May 24, 2021 at 1:22 PM Laurent Pinchart <laurent.pinchart@xxxxxxxxxxxxxxxx> wrote: > > Hi Doug, > > Thank you for the patch. > > On Mon, May 17, 2021 at 01:08:58PM -0700, Douglas Anderson wrote: > > The PM Runtime docs specifically call out the need to call > > pm_runtime_dont_use_autosuspend() in the remove() callback if > > pm_runtime_use_autosuspend() was called in probe(): > > > > > Drivers in ->remove() callback should undo the runtime PM changes done > > > in ->probe(). Usually this means calling pm_runtime_disable(), > > > pm_runtime_dont_use_autosuspend() etc. > > ~/src/kernel/linux $ git grep pm_runtime_use_autosuspend -- drivers | wc -l > 209 > ~/src/kernel/linux $ git grep pm_runtime_dont_use_autosuspend -- drivers | wc -l > 80 > > Seems like a lost battle :-( > > The fix is right, but I wonder if this shouldn't be handled > automatically by the runtime PM core. The runtime PM API is notoriously > difficult to use correctly. No kidding. > > We should do this. This fixes a warning splat that I saw when I was > > testing out the panel-simple's remove(). > > > > Fixes: 3235b0f20a0a ("drm/panel: panel-simple: Use runtime pm to avoid excessive unprepare / prepare") > > Signed-off-by: Douglas Anderson <dianders@xxxxxxxxxxxx> > > Reviewed-by: Laurent Pinchart <laurent.pinchart@xxxxxxxxxxxxxxxx> Thanks! I have pushed just this patch for now. -Doug