From patchwork Thu Sep 29 18:43:15 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Simon Ser X-Patchwork-Id: 12994566 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6584CC433F5 for ; Thu, 29 Sep 2022 18:43:35 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 70A8710EC05; Thu, 29 Sep 2022 18:43:30 +0000 (UTC) Received: from mail-4018.proton.ch (mail-4018.proton.ch [185.70.40.18]) by gabe.freedesktop.org (Postfix) with ESMTPS id 0C2F310E081 for ; Thu, 29 Sep 2022 18:43:25 +0000 (UTC) Date: Thu, 29 Sep 2022 18:43:15 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=emersion.fr; s=protonmail3; t=1664477002; x=1664736202; bh=HyhgaGbgtpd/9ok7r5Ipc6M4qVjFa1CtXzLlLcW2INk=; h=Date:To:From:Cc:Subject:Message-ID:Feedback-ID:From:To:Cc:Date: Subject:Reply-To:Feedback-ID:Message-ID; b=mwAZj239shO3XD/u6vSLPk+B3Thkn7br6y19Mp8ak3N+TqGHEYhyqrrPBXckgw0WJ 7Mlrz+TQXiGA9LcHuyI3iku+BiTIt2iyQOXNFTkNRBx6Xeq9JGScK+q2xp8nL5Dbr2 GnV//l6sz7azA85zma89DBtgeFf1g+v4vcuKIRlvyVqXwI035SUFEXZpaCBmbOhiVB 0T5seqR9/qJ5pZbYg1+gU3icFfKwPgEHZRJSrnljjaGXk+IvLU41oTmfFD6+1jKqTT HNM57mU9saz7eK335YDZhvgASkAOFc2MxhEkCBmzN37beoQaaCIqwyQU3yfsCZPgXR 6sZITYEVwwP4A== To: dri-devel@lists.freedesktop.org, amd-gfx@lists.freedesktop.org, wayland-devel@lists.freedesktop.org From: Simon Ser Subject: [PATCH v3 0/6] Add support for atomic async page-flips Message-ID: <20220929184307.258331-1-contact@emersion.fr> Feedback-ID: 1358184:user:proton MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: andrealmeid@igalia.com, daniel.vetter@ffwll.ch, mwen@igalia.com, alexander.deucher@amd.com, hwentlan@amd.com, nicholas.kazlauskas@amd.com, joshua@froggi.es Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" This series adds support for DRM_MODE_PAGE_FLIP_ASYNC for atomic commits, aka. "immediate flip" (which might result in tearing). The feature was only available via the legacy uAPI, however for gaming use-cases it may be desirable to enable it via the atomic uAPI too. - Patchwork: https://patchwork.freedesktop.org/series/107683/ - User-space patch: https://github.com/Plagman/gamescope/pull/595 - IGT patch: https://patchwork.freedesktop.org/series/107681/ Main changes in v2: add docs, fail atomic commit if async flip isn't possible. Changes in v3: add a note in the documentation about Intel hardware, add R-b tags. Tested on an AMD Picasso iGPU (Simon) and an AMD Vangogh GPU (André). Simon Ser (6): drm: document DRM_MODE_PAGE_FLIP_ASYNC amd/display: only accept async flips for fast updates drm: introduce drm_mode_config.atomic_async_page_flip_not_supported drm: allow DRM_MODE_PAGE_FLIP_ASYNC for atomic commits drm: introduce DRM_CAP_ATOMIC_ASYNC_PAGE_FLIP amd/display: indicate support for atomic async page-flips on DC .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 8 ++++++ .../amd/display/amdgpu_dm/amdgpu_dm_crtc.c | 10 +++++++ drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c | 1 + drivers/gpu/drm/drm_atomic_uapi.c | 28 +++++++++++++++++-- drivers/gpu/drm/drm_ioctl.c | 5 ++++ drivers/gpu/drm/i915/display/intel_display.c | 1 + drivers/gpu/drm/nouveau/nouveau_display.c | 1 + drivers/gpu/drm/vc4/vc4_kms.c | 1 + include/drm/drm_mode_config.h | 11 ++++++++ include/uapi/drm/drm.h | 10 ++++++- include/uapi/drm/drm_mode.h | 16 +++++++++++ 11 files changed, 88 insertions(+), 4 deletions(-) Reviewed-by: Harry Wentland Signed-off-by: André Almeida