From: Oleksandr Andrushchenko <andr2000@gmail.com>
To: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org
Cc: daniel.vetter@intel.com, gustavo@padovan.org, airlied@linux.ie,
seanpaul@chromium.org,
Oleksandr Andrushchenko <oleksandr_andrushchenko@epam.com>,
Linus Walleij <linus.walleij@linaro.org>
Subject: [PATCH 3/4] drm/tve200: Do not use deprecated drm_driver.{enable|disable)_vblank
Date: Mon, 12 Feb 2018 10:52:53 +0200 [thread overview]
Message-ID: <1518425574-32671-4-git-send-email-andr2000@gmail.com> (raw)
In-Reply-To: <1518425574-32671-1-git-send-email-andr2000@gmail.com>
From: Oleksandr Andrushchenko <oleksandr_andrushchenko@epam.com>
Do not use deprecated drm_driver.{enable|disable)_vblank callbacks,
but use drm_simple_kms_helpe's pipe callbacks instead.
Signed-off-by: Oleksandr Andrushchenko <oleksandr_andrushchenko@epam.com>
Cc: Linus Walleij <linus.walleij@linaro.org>
---
drivers/gpu/drm/tve200/tve200_display.c | 10 ++++++++--
drivers/gpu/drm/tve200/tve200_drm.h | 2 --
drivers/gpu/drm/tve200/tve200_drv.c | 3 ---
3 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/drivers/gpu/drm/tve200/tve200_display.c b/drivers/gpu/drm/tve200/tve200_display.c
index 2c668bd6d997..db397fcb345a 100644
--- a/drivers/gpu/drm/tve200/tve200_display.c
+++ b/drivers/gpu/drm/tve200/tve200_display.c
@@ -273,16 +273,20 @@ static void tve200_display_update(struct drm_simple_display_pipe *pipe,
}
}
-int tve200_enable_vblank(struct drm_device *drm, unsigned int crtc)
+static int tve200_display_enable_vblank(struct drm_simple_display_pipe *pipe)
{
+ struct drm_crtc *crtc = &pipe->crtc;
+ struct drm_device *drm = crtc->dev;
struct tve200_drm_dev_private *priv = drm->dev_private;
writel(TVE200_INT_V_STATUS, priv->regs + TVE200_INT_EN);
return 0;
}
-void tve200_disable_vblank(struct drm_device *drm, unsigned int crtc)
+static void tve200_display_disable_vblank(struct drm_simple_display_pipe *pipe)
{
+ struct drm_crtc *crtc = &pipe->crtc;
+ struct drm_device *drm = crtc->dev;
struct tve200_drm_dev_private *priv = drm->dev_private;
writel(0, priv->regs + TVE200_INT_EN);
@@ -300,6 +304,8 @@ static const struct drm_simple_display_pipe_funcs tve200_display_funcs = {
.disable = tve200_display_disable,
.update = tve200_display_update,
.prepare_fb = tve200_display_prepare_fb,
+ .enable_vblank = tve200_display_enable_vblank,
+ .disable_vblank = tve200_display_disable_vblank,
};
int tve200_display_init(struct drm_device *drm)
diff --git a/drivers/gpu/drm/tve200/tve200_drm.h b/drivers/gpu/drm/tve200/tve200_drm.h
index 5c270055bd58..1ba4380f489b 100644
--- a/drivers/gpu/drm/tve200/tve200_drm.h
+++ b/drivers/gpu/drm/tve200/tve200_drm.h
@@ -113,8 +113,6 @@ struct tve200_drm_dev_private {
container_of(x, struct tve200_drm_connector, connector)
int tve200_display_init(struct drm_device *dev);
-int tve200_enable_vblank(struct drm_device *drm, unsigned int crtc);
-void tve200_disable_vblank(struct drm_device *drm, unsigned int crtc);
irqreturn_t tve200_irq(int irq, void *data);
int tve200_connector_init(struct drm_device *dev);
int tve200_encoder_init(struct drm_device *dev);
diff --git a/drivers/gpu/drm/tve200/tve200_drv.c b/drivers/gpu/drm/tve200/tve200_drv.c
index 44911d921864..ac344ddb23bc 100644
--- a/drivers/gpu/drm/tve200/tve200_drv.c
+++ b/drivers/gpu/drm/tve200/tve200_drv.c
@@ -162,9 +162,6 @@ static struct drm_driver tve200_drm_driver = {
.gem_free_object_unlocked = drm_gem_cma_free_object,
.gem_vm_ops = &drm_gem_cma_vm_ops,
- .enable_vblank = tve200_enable_vblank,
- .disable_vblank = tve200_disable_vblank,
-
.prime_handle_to_fd = drm_gem_prime_handle_to_fd,
.prime_fd_to_handle = drm_gem_prime_fd_to_handle,
.gem_prime_import = drm_gem_prime_import,
--
2.7.4
next prev parent reply other threads:[~2018-02-12 8:54 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-12 8:52 [PATCH 0/4] drm/simple_kms_helper: Add {enable|disable}_vblank callback support Oleksandr Andrushchenko
2018-02-12 8:52 ` [PATCH 1/4] " Oleksandr Andrushchenko
2018-02-19 9:11 ` Oleksandr Andrushchenko
2018-02-22 16:59 ` Daniel Vetter
2018-02-22 17:15 ` Oleksandr Andrushchenko
2018-02-12 8:52 ` [PATCH 2/4] drm/mxsfb: Do not use deprecated drm_driver.{enable|disable)_vblank Oleksandr Andrushchenko
2018-02-12 9:26 ` Marek Vasut
2018-02-12 8:52 ` Oleksandr Andrushchenko [this message]
2018-02-13 13:51 ` [PATCH 3/4] drm/tve200: " Linus Walleij
2018-02-13 13:54 ` Oleksandr Andrushchenko
2018-02-12 8:52 ` [PATCH 4/4] drm/pl111: " Oleksandr Andrushchenko
2018-02-21 22:44 ` Eric Anholt
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=1518425574-32671-4-git-send-email-andr2000@gmail.com \
--to=andr2000@gmail.com \
--cc=airlied@linux.ie \
--cc=daniel.vetter@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=gustavo@padovan.org \
--cc=linus.walleij@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=oleksandr_andrushchenko@epam.com \
--cc=seanpaul@chromium.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
Powered by JetHome