From: Thomas Zimmermann <tzimmermann@suse.de>
To: Tian Tao <tiantao6@hisilicon.com>,
airlied@linux.ie, daniel@ffwll.ch, kraxel@redhat.com,
alexander.deucher@amd.com, tglx@linutronix.de,
dri-devel@lists.freedesktop.org, xinliang.liu@linaro.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] drm/hisilicon: Use simple encoder
Date: Mon, 4 Jan 2021 13:06:25 +0100 [thread overview]
Message-ID: <b17c2bfc-44b1-991c-9d85-0d4b76e44409@suse.de> (raw)
In-Reply-To: <1609140936-57002-1-git-send-email-tiantao6@hisilicon.com>
[-- Attachment #1.1: Type: text/plain, Size: 1924 bytes --]
Hi
Am 28.12.20 um 08:35 schrieb Tian Tao:
> The hibmc driver uses empty implementations for its encoders. Replace
> the code with the generic simple encoder.
>
> Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de>
Thanks for the patch.
> ---
> drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_vdac.c | 8 ++------
> 1 file changed, 2 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_vdac.c b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_vdac.c
> index d35548d..c76f996 100644
> --- a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_vdac.c
> +++ b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_vdac.c
> @@ -14,6 +14,7 @@
> #include <drm/drm_atomic_helper.h>
> #include <drm/drm_probe_helper.h>
> #include <drm/drm_print.h>
> +#include <drm/drm_simple_kms_helper.h>
>
> #include "hibmc_drm_drv.h"
> #include "hibmc_drm_regs.h"
> @@ -90,10 +91,6 @@ static const struct drm_encoder_helper_funcs hibmc_encoder_helper_funcs = {
> .mode_set = hibmc_encoder_mode_set,
> };
>
> -static const struct drm_encoder_funcs hibmc_encoder_funcs = {
> - .destroy = drm_encoder_cleanup,
> -};
> -
> int hibmc_vdac_init(struct hibmc_drm_private *priv)
> {
> struct drm_device *dev = &priv->dev;
> @@ -109,8 +106,7 @@ int hibmc_vdac_init(struct hibmc_drm_private *priv)
> }
>
> encoder->possible_crtcs = 0x1;
> - ret = drm_encoder_init(dev, encoder, &hibmc_encoder_funcs,
> - DRM_MODE_ENCODER_DAC, NULL);
> + ret = drm_simple_encoder_init(dev, encoder, DRM_MODE_ENCODER_DAC);
> if (ret) {
> drm_err(dev, "failed to init encoder: %d\n", ret);
> return ret;
>
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Maxfeldstr. 5, 90409 Nürnberg, Germany
(HRB 36809, AG Nürnberg)
Geschäftsführer: Felix Imendörffer
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 840 bytes --]
prev parent reply other threads:[~2021-01-04 12:07 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-28 7:35 Tian Tao
2021-01-04 12:06 ` Thomas Zimmermann [this message]
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=b17c2bfc-44b1-991c-9d85-0d4b76e44409@suse.de \
--to=tzimmermann@suse.de \
--cc=airlied@linux.ie \
--cc=alexander.deucher@amd.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=kraxel@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=tiantao6@hisilicon.com \
--cc=xinliang.liu@linaro.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®