Thank you for your contribution! Sashiko AI review found 2 potential issue(s) 
to consider:
- [Low] Removing drm_simple_encoder_init() breaks the build for the gma500 
driver, which still has unconverted callers.
- [Low] The task to remove `drm_simple_encoder_init()` is still listed in the 
GPU TODO list, leaving the documentation stale.
--

--- Patch [14]: [PATCH v2 14/15] drm/drm_simple: remove deprecated 
drm_simple_encoder_init function ---
commit 017140dd8a05d473cb61f897db90d827140d76fc
Author: Diogo Silva <[email protected]>

drm/drm_simple: remove deprecated drm_simple_encoder_init function

The simple KMS helpers are deprecated because they only add an
intermediate layer between drivers and atomic modesetting.

All driver users of drm_simple_encoder_init() have been converted to
drm_encoder_init(). Drop the helper and open-code its remaining internal
use in drm_simple_display_pipe_init() to prevent new users.

> diff --git a/drivers/gpu/drm/drm_simple_kms_helper.c 
> b/drivers/gpu/drm/drm_simple_kms_helper.c
> index 8e1d07b9f1e30..7878b9d7d5248 100644
> --- a/drivers/gpu/drm/drm_simple_kms_helper.c
> +++ b/drivers/gpu/drm/drm_simple_kms_helper.c
> @@ -20,16 +20,6 @@ static const struct drm_encoder_funcs 
> drm_simple_encoder_funcs_cleanup = {
>       .destroy = drm_encoder_cleanup,
>  };
>  
> -int drm_simple_encoder_init(struct drm_device *dev,
> -                         struct drm_encoder *encoder,
> -                         int encoder_type)
> -{
> -     return drm_encoder_init(dev, encoder,
> -                             &drm_simple_encoder_funcs_cleanup,
> -                             encoder_type, NULL);
> -}
> -EXPORT_SYMBOL(drm_simple_encoder_init);

[Severity: Low]
Does removing this helper break the build for the gma500 driver?

The commit message states that all driver users have been converted, but
it looks like the gma500 driver still has unconverted callers.

For example, in drivers/gpu/drm/gma500/cdv_intel_crt.c:cdv_intel_crt_init():

    ret = drm_simple_encoder_init(dev, encoder, DRM_MODE_ENCODER_DAC);

and in drivers/gpu/drm/gma500/cdv_intel_dp.c:cdv_intel_dp_init():

    drm_simple_encoder_init(dev, encoder, DRM_MODE_ENCODER_TMDS);

Removing the definition and declaration here causes implicit function
declaration and undefined reference errors when building with
CONFIG_DRM_GMA500 enabled.

Also, this isn't a bug, but should the task to remove
drm_simple_encoder_init() be removed from Documentation/gpu/todo.rst
as well, since this patch completes that task?

-- 
Sashiko AI review ยท 
https://sashiko.dev/#/patchset/[email protected]?part=14

Reply via email to