From patchwork Tue Sep 9 19:34:38 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Gustavo Padovan X-Patchwork-Id: 4872681 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 650D5C033A for ; Tue, 9 Sep 2014 19:34:52 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 7912220115 for ; Tue, 9 Sep 2014 19:34:51 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id A23E620123 for ; Tue, 9 Sep 2014 19:34:49 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id F1A0589FF7; Tue, 9 Sep 2014 12:34:47 -0700 (PDT) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mail-qa0-f43.google.com (mail-qa0-f43.google.com [209.85.216.43]) by gabe.freedesktop.org (Postfix) with ESMTP id 0C00389FEA; Tue, 9 Sep 2014 12:34:45 -0700 (PDT) Received: by mail-qa0-f43.google.com with SMTP id cm18so15965287qab.2 for ; Tue, 09 Sep 2014 12:34:45 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=from:to:cc:subject:date:message-id:mime-version:content-type :content-transfer-encoding; bh=hrw5Z4VXq5pVDmfZRgs/BVwdrBtH/pBYqu/boeRIYss=; b=I6iTy6IULDLReEBAhiHhYxOVJ3zc2QSn/rWPawwrBSy0nap+u3sv7LsbFT33Rycc/v vzI50HRy+o9C+eoTO8tZOniC0Z6R+Tx5NQyPvtNRRXHdBBtVKEAltU9HT7GIf0mSja5r RluKfYK0ZzzEK/CbgoAw+BmT/gC7/rteBtTXmmD+L5YPU+ZU9kag4KscLVHYmeu2BAZj sgUO89qJyNI7I4F1+x6xFeqPYDelbdK87tjqxpMfta2fJI1iivlUw3KM/7EtNA0T91dY GtdQgL9j+ug4HT8BHbYBxcKgdylwQOG6AsAI97wN6IwUjQpf5+YfJKlMvKktVSpxLGWK Aiug== X-Received: by 10.224.47.67 with SMTP id m3mr8280731qaf.28.1410291285420; Tue, 09 Sep 2014 12:34:45 -0700 (PDT) Received: from localhost.localdomain ([179.110.36.38]) by mx.google.com with ESMTPSA id r7sm3678868qai.15.2014.09.09.12.34.43 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 09 Sep 2014 12:34:44 -0700 (PDT) From: Gustavo Padovan To: intel-gfx@lists.freedesktop.org Date: Tue, 9 Sep 2014 16:34:38 -0300 Message-Id: <1410291280-19495-1-git-send-email-gustavo@padovan.org> X-Mailer: git-send-email 1.9.3 MIME-Version: 1.0 Cc: Gustavo Padovan , dri-devel@lists.freedesktop.org Subject: [Intel-gfx] [PATCH 1/3] drm/i915: remove !enabled handling from commit primary plane step X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-6.7 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Gustavo Padovan The !crtc->enabled case will now be handled by the !visible code, since the handling is basically the same. Signed-off-by: Gustavo Padovan Reviewed-by: Ville Syrjälä --- drivers/gpu/drm/i915/intel_display.c | 26 -------------------------- 1 file changed, 26 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 5279b99..2ccf7c0 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -11837,32 +11837,6 @@ intel_commit_primary_plane(struct drm_plane *plane, struct drm_rect *src = &state->src; int ret; - /* - * If the CRTC isn't enabled, we're just pinning the framebuffer, - * updating the fb pointer, and returning without touching the - * hardware. This allows us to later do a drmModeSetCrtc with fb=-1 to - * turn on the display with all planes setup as desired. - */ - if (!crtc->enabled) { - mutex_lock(&dev->struct_mutex); - - /* - * If we already called setplane while the crtc was disabled, - * we may have an fb pinned; unpin it. - */ - if (plane->fb) - intel_unpin_fb_obj(old_obj); - - i915_gem_track_fb(old_obj, obj, - INTEL_FRONTBUFFER_PRIMARY(intel_crtc->pipe)); - - /* Pin and return without programming hardware */ - ret = intel_pin_and_fence_fb_obj(dev, obj, NULL); - mutex_unlock(&dev->struct_mutex); - - return ret; - } - intel_crtc_wait_for_pending_flips(crtc); /*