* [PATCH] drm/tegra: sor: Remove usage of drm_simple_encoder_init()
@ 2026-05-23 1:26 Jacob McLemore
2026-05-28 13:27 ` Thierry Reding
0 siblings, 1 reply; 2+ messages in thread
From: Jacob McLemore @ 2026-05-23 1:26 UTC (permalink / raw)
To: jmclemore.lkml
Cc: tzimmermann, Thierry Reding, Mikko Perttunen, David Airlie,
Simona Vetter, Jonathan Hunter, dri-devel, linux-tegra,
linux-kernel
Remove the deprecated trivial helper drm_simple_encoder_init(). Inline
the call to drm_encoder_init and add instance of
drm_encoder_funcs.
Signed-off-by: Jacob McLemore <jmclemore.lkml@gmail.com>
---
Saw this was a good first task in Documentation/gpu/todo.rst.
This is my first patch, so apologies if I've set up anything wrong
in either my email client or gitconfig and the patch ends up invalid.
---
drivers/gpu/drm/tegra/sor.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/tegra/sor.c b/drivers/gpu/drm/tegra/sor.c
index de8b2dfc4984..4ac23aedb682 100644
--- a/drivers/gpu/drm/tegra/sor.c
+++ b/drivers/gpu/drm/tegra/sor.c
@@ -25,7 +25,6 @@
#include <drm/drm_file.h>
#include <drm/drm_panel.h>
#include <drm/drm_print.h>
-#include <drm/drm_simple_kms_helper.h>
#include "dc.h"
#include "dp.h"
@@ -3038,6 +3037,10 @@ static const struct tegra_sor_ops tegra_sor_dp_ops = {
.probe = tegra_sor_dp_probe,
};
+static const struct drm_encoder_funcs tegra_sor_encoder_funcs_cleanup = {
+ .destroy = drm_encoder_cleanup,
+};
+
static int tegra_sor_init(struct host1x_client *client)
{
struct drm_device *drm = dev_get_drvdata(client->host);
@@ -3081,7 +3084,7 @@ static int tegra_sor_init(struct host1x_client *client)
&tegra_sor_connector_helper_funcs);
sor->output.connector.dpms = DRM_MODE_DPMS_OFF;
- drm_simple_encoder_init(drm, &sor->output.encoder, encoder);
+ drm_encoder_init(drm, &sor->output.encoder, &tegra_sor_encoder_funcs_cleanup, encoder, NULL);
drm_encoder_helper_add(&sor->output.encoder, helpers);
drm_connector_attach_encoder(&sor->output.connector,
base-commit: 79bd2dded182b1d458b18e62684b7f82ffc682e5
--
2.43.0
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] drm/tegra: sor: Remove usage of drm_simple_encoder_init()
2026-05-23 1:26 [PATCH] drm/tegra: sor: Remove usage of drm_simple_encoder_init() Jacob McLemore
@ 2026-05-28 13:27 ` Thierry Reding
0 siblings, 0 replies; 2+ messages in thread
From: Thierry Reding @ 2026-05-28 13:27 UTC (permalink / raw)
To: Jacob McLemore
Cc: tzimmermann, Mikko Perttunen, David Airlie, Simona Vetter,
Jonathan Hunter, dri-devel, linux-tegra, linux-kernel
[-- Attachment #1: Type: text/plain, Size: 811 bytes --]
On Fri, May 22, 2026 at 08:26:24PM -0500, Jacob McLemore wrote:
> Remove the deprecated trivial helper drm_simple_encoder_init(). Inline
> the call to drm_encoder_init and add instance of
> drm_encoder_funcs.
>
> Signed-off-by: Jacob McLemore <jmclemore.lkml@gmail.com>
> ---
> Saw this was a good first task in Documentation/gpu/todo.rst.
> This is my first patch, so apologies if I've set up anything wrong
> in either my email client or gitconfig and the patch ends up invalid.
> ---
> drivers/gpu/drm/tegra/sor.c | 7 +++++--
> 1 file changed, 5 insertions(+), 2 deletions(-)
Applied, though I had to fix a few checkpatch warnings. Make sure to
always run that fix anything that it flags (though sometimes it can go a
bit overboard, so apply some common sense, too).
Thanks,
Thierry
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-05-28 13:27 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-23 1:26 [PATCH] drm/tegra: sor: Remove usage of drm_simple_encoder_init() Jacob McLemore
2026-05-28 13:27 ` Thierry Reding
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox