From patchwork Mon May 6 18:52:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Juha-Pekka Heikkila X-Patchwork-Id: 13655897 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 6D0E9C25B4F for ; Mon, 6 May 2024 18:52:55 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A3EA311232A; Mon, 6 May 2024 18:52:54 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="BEMS34oE"; dkim-atps=neutral Received: from mail-lj1-f172.google.com (mail-lj1-f172.google.com [209.85.208.172]) by gabe.freedesktop.org (Postfix) with ESMTPS id 02EA010FB58; Mon, 6 May 2024 18:52:52 +0000 (UTC) Received: by mail-lj1-f172.google.com with SMTP id 38308e7fff4ca-2dac77cdf43so28856721fa.2; Mon, 06 May 2024 11:52:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1715021571; x=1715626371; darn=lists.freedesktop.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=f0QvNqI6ozGKzcwhVEd7jEpZyu1Beg9BVayqihqpcmk=; b=BEMS34oECqPTUuBwZfQXO+uQHFONyvikreDGcO0iR0uY51YWav0iPFggOizf+t0yvX b7Mi08lLV6lfHPeUiQMVGAjbp0hW0+1reghWDcVZsKL0waRGc3SLjLkdaBqSnH6Vjhns Q3Dlt3rIRemliSsz5DbxJQyHzKvJ/tZ1mB8Mp7pYixpTifs/iOlsGaDrDGJODWig9LSN E9RtAsIm63/izfAGA1d3Xn80KAiSAPXPzQV4wv8mTxuMeIbJuqmj+6CU3ooc52O1WSUE wUvuuIppJbTacgEN17CDA96dG4bE8VHQ0IPOKv6PRjFMayGcs5baIXh6bIyoVqKol4NL YNiQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715021571; x=1715626371; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=f0QvNqI6ozGKzcwhVEd7jEpZyu1Beg9BVayqihqpcmk=; b=sO843IXxUiUKyvbcvR99PmPh3tttILcHoIbIeoKMQSCnvCt2/QWZLY/igtKMOU4+oY YHBZTZ5BagGAWpV3E0WoOM5b/LZF+oGBcJdjqmcE8NF1dYis0UmzrYuT85cPTl8OQ3Id duzjoM2sQ2pmUeduZmLb/DwlJ0F6Scmuy13lGZxjQF48EBoHrlgxXQ/VGP8TBE9THhf5 BHmGa8AWBj2oiXDDv2jJIwO0wau1fzdakpugI9oBWLPFcphL9lhmj+UoVTDUy8uUHNaq hVLbD2b9mkwzj2EHOpJP6GNRcuxsarQdmtNrtclFsRazdOpZyW4fOiUlosscCSb1UfLR Ic7Q== X-Forwarded-Encrypted: i=1; AJvYcCX01VdYIRwp3F72OZCBJerEnYiCFC8cY+P1/c+6tIpIhHehFG9Ru3wwkwLXyxOPqpzdVRO/2qZZGO9ODnCG8hWXegLWqo5NEUUmmGDE8EWf X-Gm-Message-State: AOJu0YzzY1Cfq3fEhcaRbcXGViS14uFuSP219qMsgpNH73Jgb/CDI7UP MM2s2g7C5nZ+ZQcb/1KdYgjxpxb42EJ+FhuLZxW15Ur5T71ElHmmOW4P9uFaVsrDJQ== X-Google-Smtp-Source: AGHT+IEPKZZvKMLHEVDhmvhBnn8TQZCwLpInhMlCYT06mgEVgH3GBjrk2HA/PrrLWHtNztjSnxWbwQ== X-Received: by 2002:a2e:8e66:0:b0:2e1:a9a6:ad39 with SMTP id t6-20020a2e8e66000000b002e1a9a6ad39mr6566468ljk.49.1715021570540; Mon, 06 May 2024 11:52:50 -0700 (PDT) Received: from jheikkil-mobl1.. (91-156-196-125.elisa-laajakaista.fi. [91.156.196.125]) by smtp.gmail.com with ESMTPSA id c11-20020a05651c014b00b002dcdeb98653sm1673945ljd.8.2024.05.06.11.52.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 May 2024 11:52:49 -0700 (PDT) From: Juha-Pekka Heikkila To: intel-xe@lists.freedesktop.org, intel-gfx@lists.freedesktop.org Cc: Juha-Pekka Heikkila , "Chery, Nanley G" , "Saarinen, Jani" , "Graunke, Kenneth W" , "Souza, Jose" , "Mathew, Alwin" , "Zhang, Jianxun" , "Syrjala, Ville" , "Nikula, Jani" Subject: [RFC PATCH 1/3] drm/fourcc: define Intel Xe2 related tile4 ccs modifier Date: Mon, 6 May 2024 21:52:36 +0300 Message-Id: <20240506185238.364539-2-juhapekka.heikkila@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240506185238.364539-1-juhapekka.heikkila@gmail.com> References: <20240506185238.364539-1-juhapekka.heikkila@gmail.com> MIME-Version: 1.0 X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Add Tile4 type ccs modifier to indicate presence of compression on Xe2 Signed-off-by: Juha-Pekka Heikkila --- include/uapi/drm/drm_fourcc.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/include/uapi/drm/drm_fourcc.h b/include/uapi/drm/drm_fourcc.h index 84d502e42961..50db2cc89642 100644 --- a/include/uapi/drm/drm_fourcc.h +++ b/include/uapi/drm/drm_fourcc.h @@ -702,6 +702,18 @@ extern "C" { */ #define I915_FORMAT_MOD_4_TILED_MTL_RC_CCS_CC fourcc_mod_code(INTEL, 15) +/* + * Intel Color Control Surfaces (CCS) for graphics ver. 20 render compression. + * + * The main surface is Tile 4 and at plane index 0. For semi-planar formats + * like NV12, the Y and UV planes are Tile 4 and are located at plane indices + * 0 and 1, respectively. The CCS for all planes are stored outside of the + * GEM object in a reserved memory area dedicated for the storage of the + * CCS data for all compressible GEM objects. The main surface pitch is + * required to be a multiple of four Tile 4 widths. + */ +#define I915_FORMAT_MOD_4_TILED_XE2_CCS fourcc_mod_code(INTEL, 16) + /* * Tiled, NV12MT, grouped in 64 (pixels) x 32 (lines) -sized macroblocks * From patchwork Mon May 6 18:52:37 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Juha-Pekka Heikkila X-Patchwork-Id: 13655898 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 92D07C25B5C for ; Mon, 6 May 2024 18:52:57 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0781F112333; Mon, 6 May 2024 18:52:57 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="cS2NcB31"; dkim-atps=neutral Received: from mail-lj1-f172.google.com (mail-lj1-f172.google.com [209.85.208.172]) by gabe.freedesktop.org (Postfix) with ESMTPS id 42BD011232D; Mon, 6 May 2024 18:52:54 +0000 (UTC) Received: by mail-lj1-f172.google.com with SMTP id 38308e7fff4ca-2e1fa2ff499so37491531fa.0; Mon, 06 May 2024 11:52:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1715021572; x=1715626372; darn=lists.freedesktop.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=fRXEcplgXHgSpH5z+bBD/blQQXeujxGo3RqCtUdelJk=; b=cS2NcB31btTX91XhfrbSY3bAjWbipSbVhlSDz0FiIUVWBRM33QFq67tcfPZwt1IVLx +6tzF69SIjYW8t2uxF8CPUbF6HdLgUZv6G9T9MO2tcvAP3OZTJAf8ruVYmT035bQTnDW o8Gd/0FyAiKnkXx2Km/2YOJuCBnvPk6XegInIVx03MieTlnYQOkEClSWf6vwJMEEU95v 8wqNv9OGGEoqVyCBRdRFcAGw0n+gDFD0WIeOPn2af53QIvm5ECeWfY0/TGoe7DbnE0K6 K4XMc733efjyMtHbM8kVSe7qIl7KZmtfepRrafQueO+/Af/ACMRkpC2vnaAYYjJZTZhr F01A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715021572; x=1715626372; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=fRXEcplgXHgSpH5z+bBD/blQQXeujxGo3RqCtUdelJk=; b=iuVrC2SUtulHlPdSW8o0tHo+yA5QxxgUWNoqXfvkl2NhW05xQdtBGTjfJSHQMq1EC8 +in43l8EnJsKwOfh6JIo9X8AMmf77gl+dfoEajQRew5c9qJSDmZfpkma5TWsniRAmMua 1sY+HPQLGD43ngu07K/pMpxeg9tICSwhC92THiZA1pjsPBaQwxCRzo4bgXQc7eVJcKm0 t+iMLmy7kvfe/XQ5KR+lzqfGlvKSuaiVNHOtiq6cSHA9gVf4k2o7NdfMPkbRxbX5jcR+ BheMjSLJHbajIirCrtxWZNKMstwMJBWv7wfopYtVZdca1l4FGOL72wMUV/zztYqd659x 51YQ== X-Forwarded-Encrypted: i=1; AJvYcCWeBFvgJkzIl3vV3S4JGjx0v/2FAj3UCxlX0KZd8IgZFIYrbeqKeZSl22b+cYjkTLXCQboXa/+ngIvH9XT45k/2SDE5MyIZ9fyOzNqi/D61 X-Gm-Message-State: AOJu0YzKT+J5yhTVzc/p8Fu/zc1tdxrGPhWBBoAzimAzJ1gG2+Eki43l IFKEpcKNletCdI1Q0VXSqtCxc+NBA6KqujQ1cmUUX6/+qiyRa1ZzYjDmE4mXodYj+w== X-Google-Smtp-Source: AGHT+IG+eLoQxjHL5rqIdZuTdCIdf1XrSpVk82iWIL+Ty5Lpt7up5uh8Xqv+qJ14yz5nP9zkyWUKaQ== X-Received: by 2002:a2e:908d:0:b0:2dd:6235:a5ec with SMTP id l13-20020a2e908d000000b002dd6235a5ecmr156594ljg.17.1715021571787; Mon, 06 May 2024 11:52:51 -0700 (PDT) Received: from jheikkil-mobl1.. (91-156-196-125.elisa-laajakaista.fi. [91.156.196.125]) by smtp.gmail.com with ESMTPSA id c11-20020a05651c014b00b002dcdeb98653sm1673945ljd.8.2024.05.06.11.52.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 May 2024 11:52:50 -0700 (PDT) From: Juha-Pekka Heikkila To: intel-xe@lists.freedesktop.org, intel-gfx@lists.freedesktop.org Cc: Juha-Pekka Heikkila , "Chery, Nanley G" , "Saarinen, Jani" , "Graunke, Kenneth W" , "Souza, Jose" , "Mathew, Alwin" , "Zhang, Jianxun" , "Syrjala, Ville" , "Nikula, Jani" Subject: [RFC PATCH 2/3] drm/xe/display: allow creation of case I915_FORMAT_MOD_4_TILED_XE2_CCS type framebuffer Date: Mon, 6 May 2024 21:52:37 +0300 Message-Id: <20240506185238.364539-3-juhapekka.heikkila@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240506185238.364539-1-juhapekka.heikkila@gmail.com> References: <20240506185238.364539-1-juhapekka.heikkila@gmail.com> MIME-Version: 1.0 X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Add I915_FORMAT_MOD_4_TILED_XE2_CCS to possible created tiling for new framebuffer on Xe driver. Signed-off-by: Juha-Pekka Heikkila --- drivers/gpu/drm/xe/display/xe_plane_initial.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/xe/display/xe_plane_initial.c b/drivers/gpu/drm/xe/display/xe_plane_initial.c index 9693c56d386b..59adcd15eb31 100644 --- a/drivers/gpu/drm/xe/display/xe_plane_initial.c +++ b/drivers/gpu/drm/xe/display/xe_plane_initial.c @@ -145,6 +145,7 @@ intel_alloc_initial_plane_obj(struct intel_crtc *crtc, case I915_FORMAT_MOD_X_TILED: case I915_FORMAT_MOD_Y_TILED: case I915_FORMAT_MOD_4_TILED: + case I915_FORMAT_MOD_4_TILED_XE2_CCS: break; default: drm_dbg(&dev_priv->drm, From patchwork Mon May 6 18:52:38 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Juha-Pekka Heikkila X-Patchwork-Id: 13655899 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 98B04C25B4F for ; Mon, 6 May 2024 18:52:58 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A9048112330; Mon, 6 May 2024 18:52:57 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="Y3bLmQmR"; dkim-atps=neutral Received: from mail-lf1-f45.google.com (mail-lf1-f45.google.com [209.85.167.45]) by gabe.freedesktop.org (Postfix) with ESMTPS id DE34110F253; Mon, 6 May 2024 18:52:55 +0000 (UTC) Received: by mail-lf1-f45.google.com with SMTP id 2adb3069b0e04-51f1e8eaee5so3569474e87.1; Mon, 06 May 2024 11:52:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1715021573; x=1715626373; darn=lists.freedesktop.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=xeaPqsuCveAZqCPpRXP73BKzrGSBNna04Pd/8kyPoU4=; b=Y3bLmQmRmJDC6QBtnjtVjC9xoCxzI+9SO2Rhg0wp+cyIkEAFfIjhpblVk3ia+99+As 2qkEqXWwFOq3RokPYiAWqtNvZ7l0PbFmIwbqkS9Z+vwYesSLWuK7gC5fFv35vfD2xwWE ERsKRTGfH67d7m2go5K/XM/EXMkkxjWzBLyptElc960WciPV3fBXUOh2Ax87dZ21rsJ9 61QUZyquR0385ubO6lXuS3UcAF1gnVwbMoIBRsOarj/zIwSeWuXK1f99SB+N7sSfRC4X /HT++YmoO0uYmOHzS+Bz+Cj6RftgKD13scvjm8qthaenV3uG830w8ZS+AZzgGKsL8h1e VvsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715021573; x=1715626373; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xeaPqsuCveAZqCPpRXP73BKzrGSBNna04Pd/8kyPoU4=; b=OwZcrr+WRfU2CO1i2O0AJxRoZQC3VClnWTsg1VF03sdZRn/hvKQDt/awQXVn8pqE2F o9+QkdhgD9bnxYqZPHfF4KPemxj9fOg7cB5UTadRBaNZmLTGeAiTMmNkYO3KeyIB9+yR 13jQNc983YPGPhFynHMKl1b47a3gVGsDqr6Q8+OY1sAzokWLEMNx5crUvEhWUCOAYeTO J2B62b+FMzOZiVdpzaGquLSy9G/Ow0x7m3KBmlyW9Z4dT8MRxF2/5LpJ54nN2MnyfN/J 8DtbH8zOx+aKcQC3zLEhED5x+K5gttqzNFmgvNeuJ1D4wSI+2lK7utKxKo86H6OPjU8r C13Q== X-Forwarded-Encrypted: i=1; AJvYcCUWJt0rrcg5jDag99FJ32TaTJDgF9TvmFlxBYoRTX5vXbUe1Khk3U+9YkDTSPB2ir2yWZxPDYdjkTKeopdTRpdgFb6tvNiOJtg9nvAk5WTR X-Gm-Message-State: AOJu0YzxsHkhp2nrqiOR3rm/eHIzCXxc6/21yEuqbCnn83uDHN/5ZniL 0Dv2EtV+H1F0uQ6cvUohiYGx7XHT7nEGPkDEYl55OTIxjPbwTy4VZBvF7JW/aUfCDA== X-Google-Smtp-Source: AGHT+IEaOOjtyM9j5Mc0DnMRavCZ0N13P24Q7F0Jbxe19X6d7wPgU+aSu9+1F8N27CL65rioR6z5sw== X-Received: by 2002:a19:640d:0:b0:51f:4a03:9775 with SMTP id 2adb3069b0e04-5211086bd48mr116591e87.31.1715021573336; Mon, 06 May 2024 11:52:53 -0700 (PDT) Received: from jheikkil-mobl1.. (91-156-196-125.elisa-laajakaista.fi. [91.156.196.125]) by smtp.gmail.com with ESMTPSA id c11-20020a05651c014b00b002dcdeb98653sm1673945ljd.8.2024.05.06.11.52.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 May 2024 11:52:52 -0700 (PDT) From: Juha-Pekka Heikkila To: intel-xe@lists.freedesktop.org, intel-gfx@lists.freedesktop.org Cc: Juha-Pekka Heikkila , "Chery, Nanley G" , "Saarinen, Jani" , "Graunke, Kenneth W" , "Souza, Jose" , "Mathew, Alwin" , "Zhang, Jianxun" , "Syrjala, Ville" , "Nikula, Jani" Subject: [RFC PATCH 3/3] drm/i915/display: allow creation of case I915_FORMAT_MOD_4_TILED_XE2_CCS type framebuffer Date: Mon, 6 May 2024 21:52:38 +0300 Message-Id: <20240506185238.364539-4-juhapekka.heikkila@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240506185238.364539-1-juhapekka.heikkila@gmail.com> References: <20240506185238.364539-1-juhapekka.heikkila@gmail.com> MIME-Version: 1.0 X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Add I915_FORMAT_MOD_4_TILED_XE2_CCS to possible created tiling for new framebuffer on Xe driver. Signed-off-by: Juha-Pekka Heikkila --- drivers/gpu/drm/i915/display/intel_display.c | 1 + drivers/gpu/drm/i915/display/intel_fb.c | 10 ++++++++++ drivers/gpu/drm/i915/display/skl_universal_plane.c | 4 +++- 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c index ef986b508431..083147a21edb 100644 --- a/drivers/gpu/drm/i915/display/intel_display.c +++ b/drivers/gpu/drm/i915/display/intel_display.c @@ -6150,6 +6150,7 @@ static int intel_async_flip_check_hw(struct intel_atomic_state *state, struct in case I915_FORMAT_MOD_Y_TILED: case I915_FORMAT_MOD_Yf_TILED: case I915_FORMAT_MOD_4_TILED: + case I915_FORMAT_MOD_4_TILED_XE2_CCS: break; default: drm_dbg_kms(&i915->drm, diff --git a/drivers/gpu/drm/i915/display/intel_fb.c b/drivers/gpu/drm/i915/display/intel_fb.c index bf24f48a1e76..6a44746b8381 100644 --- a/drivers/gpu/drm/i915/display/intel_fb.c +++ b/drivers/gpu/drm/i915/display/intel_fb.c @@ -161,6 +161,10 @@ struct intel_modifier_desc { static const struct intel_modifier_desc intel_modifiers[] = { { + .modifier = I915_FORMAT_MOD_4_TILED_XE2_CCS, + .display_ver = { 14, -1 }, + .plane_caps = INTEL_PLANE_CAP_TILING_4, + }, { .modifier = I915_FORMAT_MOD_4_TILED_MTL_MC_CCS, .display_ver = { 14, 14 }, .plane_caps = INTEL_PLANE_CAP_TILING_4 | INTEL_PLANE_CAP_CCS_MC, @@ -435,6 +439,10 @@ static bool plane_has_modifier(struct drm_i915_private *i915, HAS_FLAT_CCS(i915) != !md->ccs.packed_aux_planes) return false; + if (md->modifier == I915_FORMAT_MOD_4_TILED_XE2_CCS && + GRAPHICS_VER(i915) < 20) + return false; + return true; } @@ -657,6 +665,7 @@ intel_tile_width_bytes(const struct drm_framebuffer *fb, int color_plane) return 128; else return 512; + case I915_FORMAT_MOD_4_TILED_XE2_CCS: case I915_FORMAT_MOD_4_TILED_DG2_RC_CCS: case I915_FORMAT_MOD_4_TILED_DG2_RC_CCS_CC: case I915_FORMAT_MOD_4_TILED_DG2_MC_CCS: @@ -858,6 +867,7 @@ unsigned int intel_surf_alignment(const struct drm_framebuffer *fb, case I915_FORMAT_MOD_4_TILED_MTL_RC_CCS: case I915_FORMAT_MOD_4_TILED_MTL_RC_CCS_CC: return 16 * 1024; + case I915_FORMAT_MOD_4_TILED_XE2_CCS: case I915_FORMAT_MOD_Y_TILED_CCS: case I915_FORMAT_MOD_Yf_TILED_CCS: case I915_FORMAT_MOD_Y_TILED: diff --git a/drivers/gpu/drm/i915/display/skl_universal_plane.c b/drivers/gpu/drm/i915/display/skl_universal_plane.c index 0a8e781a3648..e590fea1180a 100644 --- a/drivers/gpu/drm/i915/display/skl_universal_plane.c +++ b/drivers/gpu/drm/i915/display/skl_universal_plane.c @@ -792,6 +792,7 @@ static u32 skl_plane_ctl_tiling(u64 fb_modifier) case I915_FORMAT_MOD_Y_TILED: return PLANE_CTL_TILED_Y; case I915_FORMAT_MOD_4_TILED: + case I915_FORMAT_MOD_4_TILED_XE2_CCS: return PLANE_CTL_TILED_4; case I915_FORMAT_MOD_4_TILED_DG2_RC_CCS: return PLANE_CTL_TILED_4 | @@ -949,7 +950,8 @@ static u32 skl_plane_ctl(const struct intel_crtc_state *crtc_state, plane_ctl |= adlp_plane_ctl_arb_slots(plane_state); if (GRAPHICS_VER(dev_priv) >= 20 && - fb->modifier == I915_FORMAT_MOD_4_TILED) { + (fb->modifier == I915_FORMAT_MOD_4_TILED || + fb->modifier == I915_FORMAT_MOD_4_TILED_XE2_CCS)) { plane_ctl |= PLANE_CTL_RENDER_DECOMPRESSION_ENABLE; }