All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gerd Hoffmann <kraxel@redhat.com>
To: dri-devel@lists.freedesktop.org, David Airlie <airlied@redhat.com>
Cc: andr2000@gmail.com, open list <linux-kernel@vger.kernel.org>,
	"open list:DRM DRIVER FOR BOCHS VIRTUAL GPU"
	<virtualization@lists.linux-foundation.org>,
	David Airlie <airlied@linux.ie>,
	noralf@tronnes.org
Subject: [PATCH v4 10/16] drm/bochs: remove old bochs_crtc_* functions
Date: Fri, 11 Jan 2019 06:37:46 +0100	[thread overview]
Message-ID: <20190111053752.4004-11-kraxel__34905.3917489529$1547692882$gmane$org@redhat.com> (raw)
In-Reply-To: <20190111053752.4004-1-kraxel@redhat.com>

Remove the old, now unused crtc callbacks.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Oleksandr Andrushchenko <oleksandr_andrushchenko@epam.com>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
 drivers/gpu/drm/bochs/bochs_kms.c | 81 ---------------------------------------
 1 file changed, 81 deletions(-)

diff --git a/drivers/gpu/drm/bochs/bochs_kms.c b/drivers/gpu/drm/bochs/bochs_kms.c
index 67c3674609..5b7e1a7c6b 100644
--- a/drivers/gpu/drm/bochs/bochs_kms.c
+++ b/drivers/gpu/drm/bochs/bochs_kms.c
@@ -20,74 +20,6 @@ MODULE_PARM_DESC(defy, "default y resolution");
 
 /* ---------------------------------------------------------------------- */
 
-static void bochs_crtc_dpms(struct drm_crtc *crtc, int mode)
-{
-	switch (mode) {
-	case DRM_MODE_DPMS_ON:
-	case DRM_MODE_DPMS_STANDBY:
-	case DRM_MODE_DPMS_SUSPEND:
-	case DRM_MODE_DPMS_OFF:
-	default:
-		return;
-	}
-}
-
-static int bochs_crtc_mode_set_base(struct drm_crtc *crtc, int x, int y,
-				    struct drm_framebuffer *old_fb)
-{
-	struct bochs_device *bochs =
-		container_of(crtc, struct bochs_device, crtc);
-	struct bochs_bo *bo;
-	u64 gpu_addr = 0;
-	int ret;
-
-	if (old_fb) {
-		bo = gem_to_bochs_bo(old_fb->obj[0]);
-		ret = ttm_bo_reserve(&bo->bo, true, false, NULL);
-		if (ret) {
-			DRM_ERROR("failed to reserve old_fb bo\n");
-		} else {
-			bochs_bo_unpin(bo);
-			ttm_bo_unreserve(&bo->bo);
-		}
-	}
-
-	if (WARN_ON(crtc->primary->fb == NULL))
-		return -EINVAL;
-
-	bo = gem_to_bochs_bo(crtc->primary->fb->obj[0]);
-	ret = ttm_bo_reserve(&bo->bo, true, false, NULL);
-	if (ret)
-		return ret;
-
-	ret = bochs_bo_pin(bo, TTM_PL_FLAG_VRAM, &gpu_addr);
-	if (ret) {
-		ttm_bo_unreserve(&bo->bo);
-		return ret;
-	}
-
-	ttm_bo_unreserve(&bo->bo);
-	bochs_hw_setbase(bochs, x, y, gpu_addr);
-	return 0;
-}
-
-static int bochs_crtc_mode_set(struct drm_crtc *crtc,
-			       struct drm_display_mode *mode,
-			       struct drm_display_mode *adjusted_mode,
-			       int x, int y, struct drm_framebuffer *old_fb)
-{
-	struct bochs_device *bochs =
-		container_of(crtc, struct bochs_device, crtc);
-
-	if (WARN_ON(crtc->primary->fb == NULL))
-		return -EINVAL;
-
-	bochs_hw_setmode(bochs, mode);
-	bochs_hw_setformat(bochs, crtc->primary->fb->format);
-	bochs_crtc_mode_set_base(crtc, x, y, old_fb);
-	return 0;
-}
-
 static void bochs_crtc_mode_set_nofb(struct drm_crtc *crtc)
 {
 	struct bochs_device *bochs =
@@ -96,14 +28,6 @@ static void bochs_crtc_mode_set_nofb(struct drm_crtc *crtc)
 	bochs_hw_setmode(bochs, &crtc->mode);
 }
 
-static void bochs_crtc_prepare(struct drm_crtc *crtc)
-{
-}
-
-static void bochs_crtc_commit(struct drm_crtc *crtc)
-{
-}
-
 static void bochs_crtc_atomic_enable(struct drm_crtc *crtc,
 				     struct drm_crtc_state *old_crtc_state)
 {
@@ -138,12 +62,7 @@ static const struct drm_crtc_funcs bochs_crtc_funcs = {
 };
 
 static const struct drm_crtc_helper_funcs bochs_helper_funcs = {
-	.dpms = bochs_crtc_dpms,
-	.mode_set = bochs_crtc_mode_set,
-	.mode_set_base = bochs_crtc_mode_set_base,
 	.mode_set_nofb = bochs_crtc_mode_set_nofb,
-	.prepare = bochs_crtc_prepare,
-	.commit = bochs_crtc_commit,
 	.atomic_enable = bochs_crtc_atomic_enable,
 	.atomic_flush = bochs_crtc_atomic_flush,
 };
-- 
2.9.3

  parent reply	other threads:[~2019-01-11  5:37 UTC|newest]

Thread overview: 51+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-11  5:37 [PATCH v4 00/16] drm/bochs: cleanups, atomic modesetting, generic fbdev Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 01/16] drm/bochs: encoder cleanup Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 02/16] drm/bochs: split bochs_hw_setmode Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 03/16] drm/bochs: atomic: add atomic_flush+atomic_enable callbacks Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 04/16] drm/bochs: atomic: add mode_set_nofb callback Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 05/16] drm/bochs: atomic: switch planes to atomic, wire up helpers Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 06/16] drm/bochs: atomic: use atomic set_config helper Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 07/16] drm/bochs: atomic: use atomic page_flip helper Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 08/16] drm/bochs: atomic: use suspend/resume helpers Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11 11:08   ` Oleksandr Andrushchenko
2019-01-11 11:08     ` Oleksandr Andrushchenko
2019-01-11  5:37 ` [PATCH v4 09/16] drm/bochs: atomic: set DRIVER_ATOMIC Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann [this message]
2019-01-11  5:37 ` [PATCH v4 10/16] drm/bochs: remove old bochs_crtc_* functions Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 11/16] drm/bochs: drop unused gpu_addr arg from bochs_bo_pin() Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 12/16] drm/bochs: move ttm_bo_(un)reserve calls into bochs_bo_{pin, unpin} Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 12/16] drm/bochs: move ttm_bo_(un)reserve calls into bochs_bo_{pin,unpin} Gerd Hoffmann
2019-01-11  5:37   ` [PATCH v4 12/16] drm/bochs: move ttm_bo_(un)reserve calls into bochs_bo_{pin, unpin} Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 13/16] drm/bochs: add basic prime support Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 14/16] drm/bochs: switch to generic drm fbdev emulation Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 15/16] drm/bochs: drop old fbdev emulation code Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann
2019-01-11  5:37 ` [PATCH v4 16/16] drm/bochs: move remaining fb bits to kms Gerd Hoffmann
2019-01-11  5:37 ` Gerd Hoffmann
2019-01-11  5:37   ` Gerd Hoffmann

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='20190111053752.4004-11-kraxel__34905.3917489529$1547692882$gmane$org@redhat.com' \
    --to=kraxel@redhat.com \
    --cc=airlied@linux.ie \
    --cc=airlied@redhat.com \
    --cc=andr2000@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=noralf@tronnes.org \
    --cc=virtualization@lists.linux-foundation.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.