Received: by 2002:a89:413:0:b0:1fd:dba5:e537 with SMTP id m19csp544793lqs; Thu, 13 Jun 2024 19:49:06 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXYjKjsPOkK5YBdRxOuJhdn1WQ1QqwMLchStEyQOtSv5BIj3Rtq7cqGSwQTirycD/lWKdvuVFg2pbx3mcBWmC2KnRuH5ufzOW3ueZUtUw== X-Google-Smtp-Source: AGHT+IF77OQMnxXIpW2/wGkgzegM30IMduJYxmnQUosmNRx4bWPi7GbrA1wWmkTwvA3KKeSORaLV X-Received: by 2002:a17:907:7f26:b0:a6f:50ae:e09 with SMTP id a640c23a62f3a-a6f60cefc4emr123439566b.4.1718333346311; Thu, 13 Jun 2024 19:49:06 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718333346; cv=pass; d=google.com; s=arc-20160816; b=rOYHtoI11V/PMgc6MJv7FAuFDzwCjZrXy8Ha4BEsqHGdk27NhwsoEdLI1IP2/ns9oY DE/XvA9fF8A74FCNwUyGclYIobpUhmrRM9rOz/5J9PAGVxwSTs9a/s8e/IqmituC391M Td/FaUuYnQOMdH7Yi1OCNuWM7kwHs1QKTEzYB1eoIPagxeznrCXYFk/TWlfcyzNb3asb r+T3wB0IYYDh8w0TkeXjZI4xqkwczDs1a4lX1hvwovhs4XdLSvw3ZLGrcsohfgkvNy95 VBClXA0oEz8MBrb62tAw5sWVjYihRW6+be+jGWBUgYmALr0qrUGZQsvnh+71Hm3AlclQ k+vw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:list-unsubscribe:list-subscribe:list-id:precedence :message-id:date:subject:cc:to:from:dkim-signature; bh=FBOTipKdhwPMUM/fdFD0D1fdazLJkTD6AhWAkm3itOg=; fh=BpiDvjFDWrGnlz5UzwHXo6i7NfZns2KZ9vOeLBq0SDg=; b=u9cQzwctzNH+o7oPt7atRPxC+L+uBtmoD9xsPoamcVAC7hiAC+I+pYvZ6/ntf3lo4c 6SXpiocDmkmxd/TTK9luAO+9dZIV4a/ZiELRU1TXlIMH7C5z6Kqqph1rm862aq0eYnMv 3buI2wiBYzKfIZ2YLWUCziLPWBNxqJOw+ghXVkChtEppApaU4A3BzSvqFsFbt7R7nFkw slo6kXjN3dAWYJ+RIFVw5h5t/onCSyIZFn4WOKTV3oBqx7ZSO8XSlPC3+8G3PJFKATWK M996wiRLgS654JdBZC4uFj9Kpu1bcdzAsJszc/FWtJFxpOEddtTPfn+l8XorTOBu0bhL 25nQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=D08jlQ2t; arc=pass (i=1 spf=pass spfdomain=mediatek.com dkim=pass dkdomain=mediatek.com dmarc=pass fromdomain=mediatek.com); spf=pass (google.com: domain of linux-kernel+bounces-214261-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-214261-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id a640c23a62f3a-a6f56e3b4d7si126463166b.827.2024.06.13.19.49.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 13 Jun 2024 19:49:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-214261-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=D08jlQ2t; arc=pass (i=1 spf=pass spfdomain=mediatek.com dkim=pass dkdomain=mediatek.com dmarc=pass fromdomain=mediatek.com); spf=pass (google.com: domain of linux-kernel+bounces-214261-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-214261-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id D94851F21E25 for ; Fri, 14 Jun 2024 02:49:05 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 7E86718C322; Fri, 14 Jun 2024 02:46:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=mediatek.com header.i=@mediatek.com header.b="D08jlQ2t" Received: from mailgw02.mediatek.com (unknown [210.61.82.184]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8C4D11850A2 for ; Fri, 14 Jun 2024 02:46:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=210.61.82.184 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718333194; cv=none; b=MgBplvjJQl21pYcUAKXpZ8LqNj/jGiRTRNu97rSvWNn+QrNJPF4Ml+lvbs5PXGmPiOaiEPvDAt7A5rh9y2e3cWqBwoIz4/HFlP7HbHwaZeoI55q8TugiQIueVqP2dmWq/0mKWm0BQfwc807tAjs6g1Z2marAbdrZP4dbW/3OvRc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718333194; c=relaxed/simple; bh=icNmAID2EvMQTKejkkvoyVXTnXQaUa5EIvyMHjLlbUo=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=incD/xtyVbk0K1dJV3oZHdAAMVGM7cIs311QgxADJ8ttmSZiovhTAI3Kg7q7WXH85lsb7RRQ8L59q+8A4mEN0RYq+ZKZ7idAKq6MTa0JqOG2Qu0uf/KyODL+4Q9B8HyYXkxH7cLNXDpDaQSLXZUkZxDqI6AtEk4TFkTqjTTsIQE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=mediatek.com; spf=pass smtp.mailfrom=mediatek.com; dkim=pass (1024-bit key) header.d=mediatek.com header.i=@mediatek.com header.b=D08jlQ2t; arc=none smtp.client-ip=210.61.82.184 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=mediatek.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mediatek.com X-UUID: 49665bf029f811efa22eafcdcd04c131-20240614 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Type:MIME-Version:Message-ID:Date:Subject:CC:To:From; bh=FBOTipKdhwPMUM/fdFD0D1fdazLJkTD6AhWAkm3itOg=; b=D08jlQ2tDnRUdqrPtjpl9gnTl+U/4Jl6pofBxfsaIaoW5QFwvYmQYJMvGuqFDxP1EsnpEQhahE1E9p27/+x5B/D9o7hgLHnTSRrbsHxmrOO8TLSeFXiGZKjSIf67CI6H2kfKcs2qWoQ0HbXR+YU+E5gVXo0qo9wzuhamdS4tPxc=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.39,REQID:26bed175-b0fd-4b89-af8c-5d31ab207883,IP:0,U RL:0,TC:0,Content:0,EDM:0,RT:0,SF:0,FILE:0,BULK:0,RULE:Release_Ham,ACTION: release,TS:0 X-CID-META: VersionHash:393d96e,CLOUDID:95df9188-8d4f-477b-89d2-1e3bdbef96d1,B ulkID:nil,BulkQuantity:0,Recheck:0,SF:102,TC:nil,Content:0,EDM:-3,IP:nil,U RL:0,File:nil,RT:nil,Bulk:nil,QS:nil,BEC:nil,COL:0,OSI:0,OSA:0,AV:0,LES:1, SPR:NO,DKR:0,DKP:0,BRR:0,BRE:0,ARC:0 X-CID-BVR: 0 X-CID-BAS: 0,_,0,_ X-CID-FACTOR: TF_CID_SPAM_SNR X-UUID: 49665bf029f811efa22eafcdcd04c131-20240614 Received: from mtkmbs09n1.mediatek.inc [(172.21.101.35)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 1415769070; Fri, 14 Jun 2024 10:46:23 +0800 Received: from mtkmbs11n2.mediatek.inc (172.21.101.187) by mtkmbs11n2.mediatek.inc (172.21.101.187) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.26; Fri, 14 Jun 2024 10:46:21 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by mtkmbs11n2.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.1118.26 via Frontend Transport; Fri, 14 Jun 2024 10:46:21 +0800 From: Shawn Sung To: Chun-Kuang Hu CC: Philipp Zabel , David Airlie , Daniel Vetter , Matthias Brugger , AngeloGioacchino Del Regno , Bibby Hsieh , CK Hu , "Nancy . Lin" , Sean Paul , Jason Chen , Fei Shao , , , , , Hsiao Chien Sung Subject: [PATCH v9 00/21] Support IGT in display driver Date: Fri, 14 Jun 2024 10:45:59 +0800 Message-ID: <20240614024620.19011-1-shawn.sung@mediatek.com> X-Mailer: git-send-email 2.18.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain X-MTK: N From: Hsiao Chien Sung This series adds support for running IGT (Intel GPU Tool) tests with MediaTek display driver. The following changes will be applied: 1. Add a new API for creating GCE thread loop to retrieve CRCs from the hardware component 2. Support hardware CRC calculation in both VDOSYS0 and VDOSYS1 3. Support alpha blending in both VDOSYS0 and VDOSYS1 Changes in v9: - Separate the patch into smaller ones Changes in v8: - Start/Stop CRC CMDQ thread on when needed - Squash and rearrange the commits - Add more information to the commit message and comments Changes in v7: - Separate the patch into smaller ones Changes in v6: - Use drm_vblank_work to deffer the CRC work into bottom halves - Separate the patches for "Premultiplied" and "None" alpha blending Changes in v5: - Add more descriptions to the codes - Add DRM mode configs to the driver data - Squash and rearrange the commits Changes in v4: - Separate the patch into smaller ones - Change the title of some patches - Revert the changes that are not related to the series Changes in v3: - Modify the dt-binding document of Mediatek OVL - Set DRM mode configs accroding to the hardware capabilities - Replace cmdq_pkt_jump_absolute() with cmdq_pkt_jump() Changes in v2: - Simplify CMDQ by adding commands that are currently used only - Integrate CRC related codes into new APIs for Mixer and OVL to reuse - Add CPU version CRC retrieval when CMDQ is disabled Hsiao Chien Sung (21): soc: mediatek: Disable 9-bit alpha in ETHDR drm/mediatek: Add OVL compatible name for MT8195 drm/mediatek: Add missing plane settings when async update drm/mediatek: Add DRM_MODE_ROTATE_0 to rotation property drm/mediatek: Set DRM mode configs accordingly drm/mediatek: Turn off the layers with zero width or height drm/mediatek: Support more 10bit formats in OVL drm/mediatek: Support RGBA8888 and RGBX8888 in OVL on MT8195 drm/mediatek: Fix XRGB setting error in OVL drm/mediatek: Fix XRGB setting error in Mixer drm/mediatek: Add new color format MACROs in OVL drm/mediatek: Support DRM plane alpha in OVL drm/mediatek: Support DRM plane alpha in Mixer drm/mediatek: Support "None" blending in OVL drm/mediatek: Support "None" blending in Mixer drm/mediatek: Support "Pre-multiplied" blending in OVL drm/mediatek: Support "Pre-multiplied" blending in Mixer drm/mediatek: Support alpha blending in display driver drm/mediatek: Support CRC in display driver drm/mediatek: Support CRC in OVL drm/mediatek: Support CRC in OVL adaptor drivers/gpu/drm/mediatek/mtk_crtc.c | 279 +++++++++++++++ drivers/gpu/drm/mediatek/mtk_crtc.h | 38 ++ drivers/gpu/drm/mediatek/mtk_ddp_comp.c | 10 + drivers/gpu/drm/mediatek/mtk_ddp_comp.h | 11 +- drivers/gpu/drm/mediatek/mtk_disp_drv.h | 10 + drivers/gpu/drm/mediatek/mtk_disp_ovl.c | 330 +++++++++++++++--- .../gpu/drm/mediatek/mtk_disp_ovl_adaptor.c | 37 +- drivers/gpu/drm/mediatek/mtk_drm_drv.c | 24 ++ drivers/gpu/drm/mediatek/mtk_drm_drv.h | 4 + drivers/gpu/drm/mediatek/mtk_ethdr.c | 110 +++++- drivers/gpu/drm/mediatek/mtk_ethdr.h | 7 + drivers/gpu/drm/mediatek/mtk_plane.c | 15 +- drivers/soc/mediatek/mtk-mmsys.c | 1 + 13 files changed, 826 insertions(+), 50 deletions(-) -- 2.18.0