All of lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Jan Niedziolka" <j.niedziolka@samsung.com>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 2/3] gpu/drm: Remove unused 'drm device *dev' parameter from drm_mode_create()
Date: Mon, 06 Jul 2026 13:57:43 +0000	[thread overview]
Message-ID: <20260706135744.120061F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260706134515.3369960-3-j.niedziolka@samsung.com>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] Build failure due to referencing non-existent members in struct exynos_dp_device and unused static functions.
--

commit aa4d752f4408535e5aa104d5d47b153a65ec83e2
Author: Jan Niedziolka <j.niedziolka@samsung.com>

gpu/drm: Remove unused 'drm device *dev' parameter from drm_mode_create()
    
This commit removes the unused struct drm_device *dev parameter from the
drm_mode_create() prototype and definition. It also updates all calls to
drm_mode_create() to reflect this change.

> diff --git a/drivers/gpu/drm/exynos/exynos_dp.c b/drivers/gpu/drm/exynos/exynos_dp.c
> index b805403281504..78183809b4fb3 100644
> --- a/drivers/gpu/drm/exynos/exynos_dp.c
> +++ b/drivers/gpu/drm/exynos/exynos_dp.c
> @@ -68,6 +68,53 @@ static int exynos_dp_poweroff(struct analogix_dp_plat_data *plat_data)
>  	return exynos_dp_crtc_clock_enable(plat_data, false);
>  }
>  
> +static int exynos_dp_get_modes(struct analogix_dp_plat_data *plat_data,
> +			       struct drm_connector *connector)
> +{
> +	struct exynos_dp_device *dp = to_dp(plat_data);
> +	struct drm_display_mode *mode;
> +
> +	if (dp->plat_data.panel)
> +		return 0;
> +
> +	mode = drm_mode_create();
> +	if (!mode) {
> +		DRM_DEV_ERROR(dp->dev,
> +			      "failed to create a new display mode.\n");
> +		return 0;
> +	}
> +
> +	drm_display_mode_from_videomode(&dp->vm, mode);

[Severity: Low]
Does this code compile successfully? Looking at the definition of
struct exynos_dp_device, it doesn't appear to have a vm member. This might
cause a build failure.

> +	connector->display_info.width_mm = mode->width_mm;
> +	connector->display_info.height_mm = mode->height_mm;
> +
> +	mode->type = DRM_MODE_TYPE_DRIVER | DRM_MODE_TYPE_PREFERRED;
> +	drm_mode_set_name(mode);
> +	drm_mode_probed_add(connector, mode);
> +
> +	return 1;
> +}
> +
> +static int exynos_dp_bridge_attach(struct analogix_dp_plat_data *plat_data,
> +				   struct drm_bridge *bridge,
> +				   struct drm_connector *connector)
> +{
> +	struct exynos_dp_device *dp = to_dp(plat_data);
> +	int ret;
> +
> +	dp->connector = connector;

[Severity: Low]
Similarly here, is connector a valid member of struct exynos_dp_device?

> +
> +	/* Pre-empt DP connector creation if there's a bridge */
> +	if (dp->ptn_bridge) {

[Severity: Low]
And here, does struct exynos_dp_device have a ptn_bridge member? It looks
like these functions might have been accidentally pasted from another driver
during a rebase, as they don't seem to match the struct definition and don't
appear to be referenced anywhere in this file.

> +		ret = drm_bridge_attach(&dp->encoder, dp->ptn_bridge, bridge,
> +					0);
> +		if (ret)
> +			return ret;
> +	}
> +
> +	return 0;
> +}

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260706134515.3369960-1-j.niedziolka@samsung.com?part=2

  reply	other threads:[~2026-07-06 13:57 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20260706134549eucas1p20eedf2d3287d95687eaaa8a201679083@eucas1p2.samsung.com>
2026-07-06 13:34 ` [PATCH 0/3] drm: Remove unused *drm parameter Jan Niedziolka
2026-07-06 13:34   ` [PATCH 1/3] gpu/drm: Remove unused *dev parameter from drm_mode_destroy function Jan Niedziolka
2026-07-06 13:55     ` sashiko-bot
2026-07-06 13:34   ` [PATCH 2/3] gpu/drm: Remove unused 'drm device *dev' parameter from drm_mode_create() Jan Niedziolka
2026-07-06 13:57     ` sashiko-bot [this message]
2026-07-06 13:34   ` [PATCH 3/3] gpu/drm: Add drm_notice logging when drm_mode_create fails Jan Niedziolka
2026-07-06 13:58     ` sashiko-bot

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=20260706135744.120061F000E9@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=j.niedziolka@samsung.com \
    --cc=sashiko-reviews@lists.linux.dev \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.