From patchwork Wed Oct 16 20:55:49 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Daniel Vetter X-Patchwork-Id: 3057641 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 A87ECBF924 for ; Wed, 16 Oct 2013 21:47:18 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E242E2037B for ; Wed, 16 Oct 2013 21:47:17 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 12305202E6 for ; Wed, 16 Oct 2013 21:47:17 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 14922E6DD3 for ; Wed, 16 Oct 2013 14:47:17 -0700 (PDT) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mail-ee0-f46.google.com (mail-ee0-f46.google.com [74.125.83.46]) by gabe.freedesktop.org (Postfix) with ESMTP id 7D220E6CF7 for ; Wed, 16 Oct 2013 14:00:04 -0700 (PDT) Received: by mail-ee0-f46.google.com with SMTP id c13so639189eek.5 for ; Wed, 16 Oct 2013 14:00:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ffwll.ch; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-type:content-transfer-encoding; bh=4kRd3GbRgKvMaZLsjMaLAxS1mDeJ8Iimrzgry55sulQ=; b=YgNTEIm9pqyz1N1dr14noaSwB6GNw8fDZ+ybAnSeWwrXn2clGZoj0jaR0CrEe7G11K +7g9rpRBi5551ItCqtfLKmqhBGKd0/rtv9RmZ3XUXaiYj7zQQkT4qI3fTD7fx7pTVs9w mbEboGlOYzYxS6SdNRa4Z0KuYLpp4Dan3VfjQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-type:content-transfer-encoding; bh=4kRd3GbRgKvMaZLsjMaLAxS1mDeJ8Iimrzgry55sulQ=; b=RcepHn198pVdYzGmtSfcF04soKTNq6ahZauzcay81EfW59o6pjW/zTDWggGIfLAtw4 OVFm1D3r83SthBDlYQwRSiFqynPsKzYZLQc7B3RVYeQdcTvIW5Igo2sXlWItmshxWFhK fMnIs7+ZfHeREpS66XGD11+937egLdVjEYxikX3B1YMzruEx758BOEJ0MFh7rQwN2u7H 3v1YJ13nHjXQY7GuohArCRso3hnKS44dVmhb9NRfkyU3UN6an7FXvmOZy5nCzKq8qDYs YPQxWN0dFt9+SBJ1SPhUqyLeDK/Ss3tEkFWDz5n04Ts0nRNuVzeoXrjUmNvuH3aQPnCJ ZI+w== X-Gm-Message-State: ALoCoQlW3gZnA7WStA6nN4Py3vrWgevayqeZvazaWsl/ssYkMvhKAKEZyOTjLCdIk1OQGC225qLH X-Received: by 10.14.102.66 with SMTP id c42mr7629618eeg.47.1381957203524; Wed, 16 Oct 2013 14:00:03 -0700 (PDT) Received: from gina.ffwll.local (178-83-130-250.dynamic.hispeed.ch. [178.83.130.250]) by mx.google.com with ESMTPSA id s3sm20656632eeo.3.1969.12.31.16.00.00 (version=TLSv1.2 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 16 Oct 2013 14:00:02 -0700 (PDT) From: Daniel Vetter To: Intel Graphics Development Date: Wed, 16 Oct 2013 22:55:49 +0200 Message-Id: <1381956961-16875-5-git-send-email-daniel.vetter@ffwll.ch> X-Mailer: git-send-email 1.8.4.rc3 In-Reply-To: <1381956961-16875-1-git-send-email-daniel.vetter@ffwll.ch> References: <1381956961-16875-1-git-send-email-daniel.vetter@ffwll.ch> MIME-Version: 1.0 Cc: Daniel Vetter Subject: [Intel-gfx] [PATCH 04/16] drm/i915: use ->get_vblank_counter for the crc frame counter X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces+patchwork-intel-gfx=patchwork.kernel.org@lists.freedesktop.org Errors-To: intel-gfx-bounces+patchwork-intel-gfx=patchwork.kernel.org@lists.freedesktop.org X-Spam-Status: No, score=-4.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,RP_MATCHES_RCVD,T_DKIM_INVALID,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 Suggested by Ville. Cc: Ville Syrjälä Signed-off-by: Daniel Vetter --- drivers/gpu/drm/i915/i915_irq.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c index 36465ef..eaf1268 100644 --- a/drivers/gpu/drm/i915/i915_irq.c +++ b/drivers/gpu/drm/i915/i915_irq.c @@ -1193,7 +1193,7 @@ static void dp_aux_irq_handler(struct drm_device *dev) static void display_pipe_crc_update(struct drm_device *dev, enum pipe pipe, uint32_t crc0, uint32_t crc1, uint32_t crc2, uint32_t crc3, - uint32_t crc4, uint32_t frame) + uint32_t crc4) { struct drm_i915_private *dev_priv = dev->dev_private; struct intel_pipe_crc *pipe_crc = &dev_priv->pipe_crc[pipe]; @@ -1215,7 +1215,7 @@ static void display_pipe_crc_update(struct drm_device *dev, enum pipe pipe, entry = &pipe_crc->entries[head]; - entry->frame = frame; + entry->frame = dev->driver->get_vblank_counter(dev, pipe); entry->crc[0] = crc0; entry->crc[1] = crc1; entry->crc[2] = crc2; @@ -1237,8 +1237,7 @@ static void ivb_pipe_crc_update(struct drm_device *dev, enum pipe pipe) I915_READ(PIPE_CRC_RES_2_IVB(pipe)), I915_READ(PIPE_CRC_RES_3_IVB(pipe)), I915_READ(PIPE_CRC_RES_4_IVB(pipe)), - I915_READ(PIPE_CRC_RES_5_IVB(pipe)), - I915_READ(PIPEFRAME(pipe))); + I915_READ(PIPE_CRC_RES_5_IVB(pipe))); } static void ilk_pipe_crc_update(struct drm_device *dev, enum pipe pipe) @@ -1250,8 +1249,7 @@ static void ilk_pipe_crc_update(struct drm_device *dev, enum pipe pipe) I915_READ(PIPE_CRC_RES_GREEN_ILK(pipe)), I915_READ(PIPE_CRC_RES_BLUE_ILK(pipe)), I915_READ(PIPE_CRC_RES_RES1_ILK(pipe)), - I915_READ(PIPE_CRC_RES_RES2_ILK(pipe)), - I915_READ(PIPEFRAME(pipe))); + I915_READ(PIPE_CRC_RES_RES2_ILK(pipe))); } #else static inline void ivb_pipe_crc_update(struct drm_device *dev, int pipe) {}