public inbox for drm-ai-reviews@public-inbox.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH] drm/msm/hdmi: make 'msm_hdmi_pm_ops' static
@ 2026-03-10 13:25 Ben Dooks
  2026-03-10 13:33 ` Dmitry Baryshkov
  2026-03-10 15:17 ` Konrad Dybcio
  0 siblings, 2 replies; 5+ messages in thread
From: Ben Dooks @ 2026-03-10 13:25 UTC (permalink / raw)
  To: freedreno, dri-devel, linux-arm-msm, simona, airlied
  Cc: marijn.suijten, sean, jesszhan0024, abhinav.kumar, linux-kernel,
	Ben Dooks

The struct 'msm_hdmi_pm_ops' is not used outside of the
file it is defined in, so make it static.

Fixes the following sparse warning:
drivers/gpu/drm/msm/hdmi/hdmi.c:432:1: warning: symbol 'msm_hdmi_pm_ops' was not declared. Should it be static?

Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
---
 drivers/gpu/drm/msm/hdmi/hdmi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/msm/hdmi/hdmi.c b/drivers/gpu/drm/msm/hdmi/hdmi.c
index 5afac09c0d33..64a0bc7118d5 100644
--- a/drivers/gpu/drm/msm/hdmi/hdmi.c
+++ b/drivers/gpu/drm/msm/hdmi/hdmi.c
@@ -429,7 +429,7 @@ static int msm_hdmi_runtime_resume(struct device *dev)
 	return ret;
 }
 
-DEFINE_RUNTIME_DEV_PM_OPS(msm_hdmi_pm_ops, msm_hdmi_runtime_suspend, msm_hdmi_runtime_resume, NULL);
+static DEFINE_RUNTIME_DEV_PM_OPS(msm_hdmi_pm_ops, msm_hdmi_runtime_suspend, msm_hdmi_runtime_resume, NULL);
 
 static const struct of_device_id msm_hdmi_dt_match[] = {
 	{ .compatible = "qcom,hdmi-tx-8998", .data = &hdmi_tx_8974_config },
-- 
2.37.2.352.g3c44437643


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] drm/msm/hdmi: make 'msm_hdmi_pm_ops' static
  2026-03-10 13:25 [PATCH] drm/msm/hdmi: make 'msm_hdmi_pm_ops' static Ben Dooks
@ 2026-03-10 13:33 ` Dmitry Baryshkov
  2026-03-11  3:14   ` Claude review: " Claude Code Review Bot
  2026-03-11  3:14   ` Claude Code Review Bot
  2026-03-10 15:17 ` Konrad Dybcio
  1 sibling, 2 replies; 5+ messages in thread
From: Dmitry Baryshkov @ 2026-03-10 13:33 UTC (permalink / raw)
  To: Ben Dooks
  Cc: freedreno, dri-devel, linux-arm-msm, simona, airlied,
	marijn.suijten, sean, jesszhan0024, abhinav.kumar, linux-kernel

On Tue, Mar 10, 2026 at 01:25:01PM +0000, Ben Dooks wrote:
> The struct 'msm_hdmi_pm_ops' is not used outside of the
> file it is defined in, so make it static.
> 
> Fixes the following sparse warning:
> drivers/gpu/drm/msm/hdmi/hdmi.c:432:1: warning: symbol 'msm_hdmi_pm_ops' was not declared. Should it be static?
> 
> Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
> ---
>  drivers/gpu/drm/msm/hdmi/hdmi.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>


-- 
With best wishes
Dmitry

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] drm/msm/hdmi: make 'msm_hdmi_pm_ops' static
  2026-03-10 13:25 [PATCH] drm/msm/hdmi: make 'msm_hdmi_pm_ops' static Ben Dooks
  2026-03-10 13:33 ` Dmitry Baryshkov
@ 2026-03-10 15:17 ` Konrad Dybcio
  1 sibling, 0 replies; 5+ messages in thread
From: Konrad Dybcio @ 2026-03-10 15:17 UTC (permalink / raw)
  To: Ben Dooks, freedreno, dri-devel, linux-arm-msm, simona, airlied
  Cc: marijn.suijten, sean, jesszhan0024, abhinav.kumar, linux-kernel

On 3/10/26 2:25 PM, Ben Dooks wrote:
> The struct 'msm_hdmi_pm_ops' is not used outside of the
> file it is defined in, so make it static.
> 
> Fixes the following sparse warning:
> drivers/gpu/drm/msm/hdmi/hdmi.c:432:1: warning: symbol 'msm_hdmi_pm_ops' was not declared. Should it be static?
> 
> Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
> ---

Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>

Konrad

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Claude review: Re: [PATCH] drm/msm/hdmi: make 'msm_hdmi_pm_ops' static
  2026-03-10 13:33 ` Dmitry Baryshkov
@ 2026-03-11  3:14   ` Claude Code Review Bot
  2026-03-11  3:14   ` Claude Code Review Bot
  1 sibling, 0 replies; 5+ messages in thread
From: Claude Code Review Bot @ 2026-03-11  3:14 UTC (permalink / raw)
  To: dri-devel-reviews

Overall Series Review

Subject: Re: [PATCH] drm/msm/hdmi: make 'msm_hdmi_pm_ops' static
Author: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Patches: 3
Reviewed: 2026-03-11T13:14:08.280883

---

This is a single, trivial cleanup patch that adds `static` to a file-local `DEFINE_RUNTIME_DEV_PM_OPS()` declaration to fix a sparse warning. The change is correct and straightforward.

---
Generated by Claude Code Patch Reviewer

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Claude review: Re: [PATCH] drm/msm/hdmi: make 'msm_hdmi_pm_ops' static
  2026-03-10 13:33 ` Dmitry Baryshkov
  2026-03-11  3:14   ` Claude review: " Claude Code Review Bot
@ 2026-03-11  3:14   ` Claude Code Review Bot
  1 sibling, 0 replies; 5+ messages in thread
From: Claude Code Review Bot @ 2026-03-11  3:14 UTC (permalink / raw)
  To: dri-devel-reviews

Patch Review

**Verdict: Correct and ready to apply.**

The `DEFINE_RUNTIME_DEV_PM_OPS()` macro expands (via `_DEFINE_DEV_PM_OPS` in `include/linux/pm.h:374`) to:

```c
const struct dev_pm_ops msm_hdmi_pm_ops = { ... }
```

Adding `static` in front is the standard way to limit its scope. The symbol is only referenced within the same file at line 451:

```c
.pm = &msm_hdmi_pm_ops,
```

So making it `static` is correct and silences the sparse warning without any behavioral change.

**Minor nit:** The commit message quotes the sparse warning at line 432:1, which points to the macro invocation. This is fine — sparse reports the expansion site.

No issues found with this patch.

---
Generated by Claude Code Patch Reviewer

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-03-11  3:14 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-10 13:25 [PATCH] drm/msm/hdmi: make 'msm_hdmi_pm_ops' static Ben Dooks
2026-03-10 13:33 ` Dmitry Baryshkov
2026-03-11  3:14   ` Claude review: " Claude Code Review Bot
2026-03-11  3:14   ` Claude Code Review Bot
2026-03-10 15:17 ` Konrad Dybcio

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox