From patchwork Sat Apr 21 22:50:22 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Schake X-Patchwork-Id: 10354375 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 93463604D3 for ; Sat, 21 Apr 2018 22:51:13 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8CB812891A for ; Sat, 21 Apr 2018 22:51:13 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 815E328924; Sat, 21 Apr 2018 22:51:13 +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=-5.1 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED, T_DKIM_INVALID 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 4033C2891A for ; Sat, 21 Apr 2018 22:51:13 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0F1796E125; Sat, 21 Apr 2018 22:51:12 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wr0-x241.google.com (mail-wr0-x241.google.com [IPv6:2a00:1450:400c:c0c::241]) by gabe.freedesktop.org (Postfix) with ESMTPS id C94706E0A0 for ; Sat, 21 Apr 2018 22:51:01 +0000 (UTC) Received: by mail-wr0-x241.google.com with SMTP id v15-v6so13418048wrm.10 for ; Sat, 21 Apr 2018 15:51:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=veFx4vsw1KEoxj6K0q6nO6fM+L6L94pFaZ8cXJZ8mGw=; b=g/wL0i0rtNcoOsIcCBm5SLYvsC8fEkcd+gdr5/8+W6AV8vYtzpQ6CWStbLAFg6GtNz pBpofGWlFA4Hz3hZsMIN+rncnZ0xScpPttAkkOgRQu2eYqBRNXWmgubL2dt9Nuvb/dfo XABORUgjro+H9AbJEK+71NisGPFM57ZOP12LKbGwryIPtAGLcdd677aqwPiRWtCWPPNs CVGdZ6u1ggBcvNnsDCpzrGZH4YPJTUHC1iPe61hJyKwug3iS3GQA6PtvI0lfyp4jILkj bPG9mbKnGe4eB5D08BRGrHgHEZ+Ikxmao85plHnm/lD3bGX3CUaWQRdpbHw/Md41cFsh uANA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=veFx4vsw1KEoxj6K0q6nO6fM+L6L94pFaZ8cXJZ8mGw=; b=aSkktvCcny57iNW1fnLkY/LGsp1o3Q95ZxevnZMLFDTGtjAkBd4KhwlyR8dxpBp6VC AiUO/++a2xMFZpD79LeU94wqF8oGfVtQjJcZZWJu+pmqTVhiGCuBpGJIuay/Ts20kd2U Df7wwyCd7LM7zAc/Bi8L3EPJyiP9QR5HLNtr60SCqCdQ4UExbILliBsSBGwxy2CstsWR 1zCnRgViTwTnTxjPel661f4jtAWJ6Vj0owpIGvkpXphxT7I92jPdv7gLy9PCdUGAtTyx eE54DBFvOskyT8rxEmbSWofCGDWjKpYNVofziy7npa5v9r/mHa/AW/ygO5ErhNKrFgXd Q/1Q== X-Gm-Message-State: ALQs6tCjA1KMvezLVtI7GnLT/TPoKfl0tkpn5jK+P26J4EBVCcciAs1J sRP2u8b7WniXsKnWNBKzdl7hVm10 X-Google-Smtp-Source: AIpwx4+uFFO/vrDWz6BP6mE/ytx0jzPCS4/KKeXNVZ5apNIs38EI7sAeKm55DGDzLR1ZhqB6W8zrOw== X-Received: by 2002:adf:988e:: with SMTP id w14-v6mr12577581wrb.210.1524351060283; Sat, 21 Apr 2018 15:51:00 -0700 (PDT) Received: from localhost.localdomain (ip-88-153-118-32.hsi04.unitymediagroup.de. [88.153.118.32]) by smtp.gmail.com with ESMTPSA id 55-v6sm18528098wrw.52.2018.04.21.15.50.58 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 21 Apr 2018 15:50:59 -0700 (PDT) From: Stefan Schake To: eric@anholt.net Subject: [PATCH 4/4] drm/vc4: Add parameter for syncobj support Date: Sat, 21 Apr 2018 15:50:22 -0700 Message-Id: <20180421225022.7592-5-stschake@gmail.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20180421225022.7592-1-stschake@gmail.com> References: <20180421225022.7592-1-stschake@gmail.com> X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: airlied@linux.ie, linux-rpi-kernel@lists.infradead.org, dri-devel@lists.freedesktop.org, Stefan Schake MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP This allows runtime detection of syncobj submission support. Signed-off-by: Stefan Schake --- drivers/gpu/drm/vc4/vc4_drv.c | 1 + include/uapi/drm/vc4_drm.h | 1 + 2 files changed, 2 insertions(+) diff --git a/drivers/gpu/drm/vc4/vc4_drv.c b/drivers/gpu/drm/vc4/vc4_drv.c index 806c8004b793..4e2ae2a9a164 100644 --- a/drivers/gpu/drm/vc4/vc4_drv.c +++ b/drivers/gpu/drm/vc4/vc4_drv.c @@ -102,6 +102,7 @@ static int vc4_get_param_ioctl(struct drm_device *dev, void *data, case DRM_VC4_PARAM_SUPPORTS_FIXED_RCL_ORDER: case DRM_VC4_PARAM_SUPPORTS_MADVISE: case DRM_VC4_PARAM_SUPPORTS_PERFMON: + case DRM_VC4_PARAM_SUPPORTS_SYNCOBJ: args->value = true; break; default: diff --git a/include/uapi/drm/vc4_drm.h b/include/uapi/drm/vc4_drm.h index 3a2ef9b5b60b..6f81cf05f7a3 100644 --- a/include/uapi/drm/vc4_drm.h +++ b/include/uapi/drm/vc4_drm.h @@ -338,6 +338,7 @@ struct drm_vc4_get_hang_state { #define DRM_VC4_PARAM_SUPPORTS_FIXED_RCL_ORDER 6 #define DRM_VC4_PARAM_SUPPORTS_MADVISE 7 #define DRM_VC4_PARAM_SUPPORTS_PERFMON 8 +#define DRM_VC4_PARAM_SUPPORTS_SYNCOBJ 9 struct drm_vc4_get_param { __u32 param;