lkml.org 
[lkml]   [2021]   [Dec]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] omapdrm: dss: mark runtime PM functions __maybe_unused
From
Date
On 06/12/2021 13:14, Laurent Pinchart wrote:
> Hi Arnd,
>
> Thank you for the patch.
>
> On Sun, Dec 05, 2021 at 02:15:56PM +0100, Arnd Bergmann wrote:
>> From: Arnd Bergmann <arnd@arndb.de>
>>
>> Using the SET_RUNTIME_PM_OPS() macro causes a warning about the
>> referenced functions when they are marked static but not __maybe_unused:
>>
>> drivers/gpu/drm/omapdrm/dss/dss.c:1572:12: error: unused function 'dss_runtime_suspend' [-Werror,-Wunused-function]
>> drivers/gpu/drm/omapdrm/dss/dss.c:1584:12: error: unused function 'dss_runtime_resume' [-Werror,-Wunused-function]
>> drivers/gpu/drm/omapdrm/dss/dispc.c:4845:12: error: unused function 'dispc_runtime_suspend' [-Werror,-Wunused-function]
>> drivers/gpu/drm/omapdrm/dss/dispc.c:4860:12: error: unused function 'dispc_runtime_resume' [-Werror,-Wunused-function]
>>
>> Fixes: b92f7ea556f8 ("drm/omap: dss: Make use of the helper macro SET_RUNTIME_PM_OPS()")
>
> I wonder how well drivers are tested with !CONFIG_PM. We may be going
> through hoops and loops to support this when it actually won't work in
> most drivers. That's a separate issue though :-)

It won't work, but can be fixed. I did that for tidss, some years back.
The problem is that the driver depends on runtime_suspend/resume to be
called, and the fix is to call them manually when !CONFIG_PM.

> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
>
> Tomi, could you apply this ?

Yes, I'll push to drm-misc-next. Thanks!

Tomi

\
 
 \ /
  Last update: 2021-12-08 09:09    [W:0.045 / U:1.192 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site