mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Nicolas Dufresne <nicolas@ndufresne.ca>
To: Diederik de Haas <diederik@cknow-tech.com>,
	Dafna Hirschfeld	 <dafna@fastmail.com>,
	Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
	Mauro Carvalho Chehab	 <mchehab@kernel.org>,
	Heiko Stuebner <heiko@sntech.de>,
	Detlev Casanova	 <detlev.casanova@collabora.com>,
	Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>,
	 Jacob Chen <jacob-chen@iotwrt.com>
Cc: linux-media@vger.kernel.org, linux-rockchip@lists.infradead.org,
	 linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/3] media: rockchip: rga: Switch to modern PM_OPS
Date: Fri, 02 Oct 2026 15:56:23 -0400	[thread overview]
Message-ID: <a153b350bdfd614b4da5a15da29079eec7fc4dd4.camel@ndufresne.ca> (raw)
In-Reply-To: <20261001173610.158931-3-diederik@cknow-tech.com>

[-- Attachment #1: Type: text/plain, Size: 2134 bytes --]

Le jeudi 01 octobre 2026 à 19:34 +0200, Diederik de Haas a écrit :
> A new set of modern PM_OPS macros got defined in commit
> 1a3c7bb08826 ("PM: core: Add new *_PM_OPS macros, deprecate old ones")
> 
> Switch to those new macros so that the PM callbacks are always seen by the
> compiler, but discarded if not used. This lets us drop the __maybe_unused
> annotation from the callback functions.
> 
> Signed-off-by: Diederik de Haas <diederik@cknow-tech.com>

Reviewed-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>

> ---
>  drivers/media/platform/rockchip/rga/rga.c | 9 ++++-----
>  1 file changed, 4 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/media/platform/rockchip/rga/rga.c b/drivers/media/platform/rockchip/rga/rga.c
> index b3cb6bf8eb86..f28c93d63760 100644
> --- a/drivers/media/platform/rockchip/rga/rga.c
> +++ b/drivers/media/platform/rockchip/rga/rga.c
> @@ -883,7 +883,7 @@ static void rga_remove(struct platform_device *pdev)
>  	pm_runtime_disable(rga->dev);
>  }
>  
> -static int __maybe_unused rga_runtime_suspend(struct device *dev)
> +static int rga_runtime_suspend(struct device *dev)
>  {
>  	struct rockchip_rga *rga = dev_get_drvdata(dev);
>  
> @@ -892,7 +892,7 @@ static int __maybe_unused rga_runtime_suspend(struct device *dev)
>  	return 0;
>  }
>  
> -static int __maybe_unused rga_runtime_resume(struct device *dev)
> +static int rga_runtime_resume(struct device *dev)
>  {
>  	struct rockchip_rga *rga = dev_get_drvdata(dev);
>  
> @@ -900,8 +900,7 @@ static int __maybe_unused rga_runtime_resume(struct device *dev)
>  }
>  
>  static const struct dev_pm_ops rga_pm = {
> -	SET_RUNTIME_PM_OPS(rga_runtime_suspend,
> -			   rga_runtime_resume, NULL)
> +	RUNTIME_PM_OPS(rga_runtime_suspend, rga_runtime_resume, NULL)
>  };
>  
>  static const struct of_device_id rockchip_rga_match[] = {
> @@ -927,7 +926,7 @@ static struct platform_driver rga_pdrv = {
>  	.remove = rga_remove,
>  	.driver = {
>  		.name = RGA_NAME,
> -		.pm = &rga_pm,
> +		.pm = pm_ptr(&rga_pm),
>  		.of_match_table = rockchip_rga_match,
>  	},
>  };

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

  reply	other threads:[~2026-10-02 19:56 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-01 17:34 [PATCH 0/3] media: rockchip: Modernize PM_OPS Diederik de Haas
2026-10-01 17:34 ` [PATCH 1/3] media: rkvdec: Switch to modern PM_OPS Diederik de Haas
2026-10-02 19:55   ` Nicolas Dufresne
2026-10-01 17:34 ` [PATCH 2/3] media: rockchip: rga: " Diederik de Haas
2026-10-02 19:56   ` Nicolas Dufresne [this message]
2026-10-01 17:34 ` [PATCH 3/3] media: rkisp1: " Diederik de Haas
2026-10-02  1:46   ` Laurent Pinchart
2026-10-02 19:57 ` [PATCH 0/3] media: rockchip: Modernize PM_OPS Nicolas Dufresne

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a153b350bdfd614b4da5a15da29079eec7fc4dd4.camel@ndufresne.ca \
    --to=nicolas@ndufresne.ca \
    --cc=dafna@fastmail.com \
    --cc=detlev.casanova@collabora.com \
    --cc=diederik@cknow-tech.com \
    --cc=ezequiel@vanguardiasur.com.ar \
    --cc=heiko@sntech.de \
    --cc=jacob-chen@iotwrt.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=linux-rockchip@lists.infradead.org \
    --cc=mchehab@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®