From patchwork Mon Oct 8 19:50:41 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rob Clark X-Patchwork-Id: 12046 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 8450223FB3 for ; Mon, 8 Oct 2012 19:51:20 +0000 (UTC) Received: from mail-da0-f52.google.com (mail-da0-f52.google.com [209.85.210.52]) by fiordland.canonical.com (Postfix) with ESMTP id 2B2A4A18BE1 for ; Mon, 8 Oct 2012 19:51:20 +0000 (UTC) Received: by mail-da0-f52.google.com with SMTP id f10so2134510dak.11 for ; Mon, 08 Oct 2012 12:51:19 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf :dkim-signature:sender:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references:x-gm-message-state; bh=TbMntboC9B4ujk/I1NnHUh05ZKcbh8g0m+hE48kYa20=; b=DW6NRcyV0JAmJ7svmkT5NUnIbUmSFAexeReHfbGodB+f+ZBWE4fdq56Gy6HzStNGbz IESvuvEsLgHPieGQQQZo7KrSzh3cq+RXOL7JHploP9Jh2eICY4FQ2XwksQkuPQrRfWi3 +Xld98piLBsAWu3+e3zDsnfLW11rX1CjMx+9jsQ/vojbhTfppAz8Q2fKsSaqP/CF4xJx esUzALmBSu5Wtkh799jpDB4Yn1kCrlfdCZsy4SfHQlw6WzrPQLs8Kh1I50zzpGhBXAWs IdDAR+a8BAh4XnGM8MSjGkGNb2QiCBXNjKkcsQhr/cN+W44roeKSfBlfGvv9msAHr1cF jyrw== Received: by 10.68.197.70 with SMTP id is6mr44001730pbc.64.1349725879851; Mon, 08 Oct 2012 12:51:19 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.68.34.137 with SMTP id z9csp314486pbi; Mon, 8 Oct 2012 12:51:19 -0700 (PDT) Received: by 10.182.78.228 with SMTP id e4mr1020280obx.77.1349725879204; Mon, 08 Oct 2012 12:51:19 -0700 (PDT) Received: from mail-oa0-f50.google.com (mail-oa0-f50.google.com [209.85.219.50]) by mx.google.com with ESMTPS id ym2si20201401obb.141.2012.10.08.12.51.18 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 08 Oct 2012 12:51:19 -0700 (PDT) Received-SPF: pass (google.com: domain of robdclark@gmail.com designates 209.85.219.50 as permitted sender) client-ip=209.85.219.50; Authentication-Results: mx.google.com; spf=pass (google.com: domain of robdclark@gmail.com designates 209.85.219.50 as permitted sender) smtp.mail=robdclark@gmail.com; dkim=pass header.i=@gmail.com Received: by mail-oa0-f50.google.com with SMTP id n16so611275oag.37 for ; Mon, 08 Oct 2012 12:51:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references; bh=TbMntboC9B4ujk/I1NnHUh05ZKcbh8g0m+hE48kYa20=; b=HLlq7wJbYCwH2hlCfLh9rUDC6oZJMVZLjgWGm+an2oRzNQQ/+e6scOHQ2l70o+Pr5M ixLcaHToIVlh6/VvH3ug1UbzTNkKmY8joQkLcH9mJnBawupEgtNMpPEMUO0IFJZ23l/6 KNRzOWiNRXxT1mFrWUV8LWdNsL6LcqGK4zRRprBomkRvF68C2Y+YiS0VCro15StCSYp0 WiJvh+Yx8b2fi1AwSbsWTn1OzG7Kke/v8bDjdQH7tquSaZ7yn3CZrrXNBbEmIzgSpcPQ bl5yNCgeoY+9Q9IlM/hetLl6UUe6+sM5R2rnT4e6BQlgsecHl0kUik16hkFuBQ/+AYtc jBbA== Received: by 10.182.10.71 with SMTP id g7mr1008993obb.84.1349725878937; Mon, 08 Oct 2012 12:51:18 -0700 (PDT) Received: from localhost (dragon.ti.com. [192.94.94.33]) by mx.google.com with ESMTPS id k7sm14933802oek.6.2012.10.08.12.51.17 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 08 Oct 2012 12:51:17 -0700 (PDT) Sender: Rob Clark From: Rob Clark To: dri-devel@lists.freedesktop.org Cc: patches@linaro.org, airlied@linux.ie, daniel.vetter@ffwll.ch, bskeggs@redhat.com, inki.dae@samsung.com, laurent.pinchart@ideasonboard.com, s.hauer@pengutronix.de, gregkh@linuxfoundation.org, Rob Clark Subject: [PATCH 03/11] drm/nouveau: use drm_send_vblank_event() helper Date: Mon, 8 Oct 2012 14:50:41 -0500 Message-Id: <1349725849-22433-4-git-send-email-rob.clark@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1349725849-22433-1-git-send-email-rob.clark@linaro.org> References: <1349725849-22433-1-git-send-email-rob.clark@linaro.org> X-Gm-Message-State: ALoCoQl71rigFfjriUCNoq1yhunEmDkAjKpiXwR9HfVNB87pZEq+1BmjdKqqj4/OmlVLTf/LlHnj From: Rob Clark Signed-off-by: Rob Clark --- drivers/gpu/drm/nouveau/nouveau_display.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/drivers/gpu/drm/nouveau/nouveau_display.c b/drivers/gpu/drm/nouveau/nouveau_display.c index 7e16dc5..b1a32b9 100644 --- a/drivers/gpu/drm/nouveau/nouveau_display.c +++ b/drivers/gpu/drm/nouveau/nouveau_display.c @@ -566,17 +566,8 @@ nouveau_finish_page_flip(struct nouveau_channel *chan, } s = list_first_entry(&swch->flip, struct nouveau_page_flip_state, head); - if (s->event) { - struct drm_pending_vblank_event *e = s->event; - struct timeval now; - - do_gettimeofday(&now); - e->event.sequence = 0; - e->event.tv_sec = now.tv_sec; - e->event.tv_usec = now.tv_usec; - list_add_tail(&e->base.link, &e->base.file_priv->event_list); - wake_up_interruptible(&e->base.file_priv->event_wait); - } + if (s->event) + drm_send_vblank_event(dev, -1, s->event); list_del(&s->head); if (ps)