Commit b28ad7de authored by Thomas Zimmermann's avatar Thomas Zimmermann

drm/tidss: Use simple encoder

The tidss driver uses an empty implementation for its encoder. Replace
the code with the generic simple encoder.
Signed-off-by: default avatarThomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Acked-by: default avatarJyri Sarha <jsarha@ti.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200305155950.2705-17-tzimmermann@suse.de
parent 4d0e95e0
...@@ -8,8 +8,9 @@ ...@@ -8,8 +8,9 @@
#include <drm/drm_crtc.h> #include <drm/drm_crtc.h>
#include <drm/drm_crtc_helper.h> #include <drm/drm_crtc_helper.h>
#include <drm/drm_panel.h>
#include <drm/drm_of.h> #include <drm/drm_of.h>
#include <drm/drm_panel.h>
#include <drm/drm_simple_kms_helper.h>
#include "tidss_crtc.h" #include "tidss_crtc.h"
#include "tidss_drv.h" #include "tidss_drv.h"
...@@ -59,10 +60,6 @@ static const struct drm_encoder_helper_funcs encoder_helper_funcs = { ...@@ -59,10 +60,6 @@ static const struct drm_encoder_helper_funcs encoder_helper_funcs = {
.atomic_check = tidss_encoder_atomic_check, .atomic_check = tidss_encoder_atomic_check,
}; };
static const struct drm_encoder_funcs encoder_funcs = {
.destroy = drm_encoder_cleanup,
};
struct drm_encoder *tidss_encoder_create(struct tidss_device *tidss, struct drm_encoder *tidss_encoder_create(struct tidss_device *tidss,
u32 encoder_type, u32 possible_crtcs) u32 encoder_type, u32 possible_crtcs)
{ {
...@@ -75,8 +72,7 @@ struct drm_encoder *tidss_encoder_create(struct tidss_device *tidss, ...@@ -75,8 +72,7 @@ struct drm_encoder *tidss_encoder_create(struct tidss_device *tidss,
enc->possible_crtcs = possible_crtcs; enc->possible_crtcs = possible_crtcs;
ret = drm_encoder_init(&tidss->ddev, enc, &encoder_funcs, ret = drm_simple_encoder_init(&tidss->ddev, enc, encoder_type);
encoder_type, NULL);
if (ret < 0) if (ret < 0)
return ERR_PTR(ret); return ERR_PTR(ret);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment