From patchwork Tue Sep 26 06:24:44 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robert Foss X-Patchwork-Id: 9971057 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 2D220602D8 for ; Tue, 26 Sep 2017 06:25:55 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1775928EC3 for ; Tue, 26 Sep 2017 06:25:55 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0C4AB28EC6; Tue, 26 Sep 2017 06:25:55 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id CA5A928EC3 for ; Tue, 26 Sep 2017 06:25:53 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 1E3D66E3EB; Tue, 26 Sep 2017 06:25:17 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from bhuna.collabora.co.uk (bhuna.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e3e3]) by gabe.freedesktop.org (Postfix) with ESMTPS id AB19D6E3DB for ; Tue, 26 Sep 2017 06:25:02 +0000 (UTC) Received: from localhost.localdomain (unknown [IPv6:2a02:8109:9a3f:ee3b:c7ab:3df6:4b82:1a62]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: robertfoss) by bhuna.collabora.co.uk (Postfix) with ESMTPSA id 3D10A26C28B; Tue, 26 Sep 2017 07:25:01 +0100 (BST) From: Robert Foss To: dri-devel@lists.freedesktop.org, Sean Paul Subject: [PATCH hwc v1 4/6] drm_hwcomposer: Add FENCE_OUT_PTR property to DrmCrtc Date: Tue, 26 Sep 2017 08:24:44 +0200 Message-Id: <20170926062446.6412-5-robert.foss@collabora.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170926062446.6412-1-robert.foss@collabora.com> References: <20170926062446.6412-1-robert.foss@collabora.com> Cc: Robert Foss X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Add support for handling the FENCE_OUT_PTR property to DrmCrtc Signed-off-by: Robert Foss --- drmcrtc.cpp | 10 ++++++++++ drmcrtc.h | 2 ++ 2 files changed, 12 insertions(+) diff --git a/drmcrtc.cpp b/drmcrtc.cpp index 1fbdc12..c139869 100644 --- a/drmcrtc.cpp +++ b/drmcrtc.cpp @@ -51,6 +51,12 @@ int DrmCrtc::Init() { ALOGE("Failed to get MODE_ID property"); return ret; } + + ret = drm_->GetCrtcProperty(*this, "OUT_FENCE_PTR", &out_fence_ptr_property_); + if (ret) { + ALOGE("Failed to get OUT_FENCE_PTR property"); + return ret; + } return 0; } @@ -81,4 +87,8 @@ const DrmProperty &DrmCrtc::active_property() const { const DrmProperty &DrmCrtc::mode_property() const { return mode_property_; } + +const DrmProperty &DrmCrtc::out_fence_ptr_property() const { + return out_fence_ptr_property_; +} } diff --git a/drmcrtc.h b/drmcrtc.h index ad95352..2e8c811 100644 --- a/drmcrtc.h +++ b/drmcrtc.h @@ -45,6 +45,7 @@ class DrmCrtc { const DrmProperty &active_property() const; const DrmProperty &mode_property() const; + const DrmProperty &out_fence_ptr_property() const; private: DrmResources *drm_; @@ -63,6 +64,7 @@ class DrmCrtc { DrmProperty active_property_; DrmProperty mode_property_; + DrmProperty out_fence_ptr_property_; }; }