From patchwork Fri Jan 10 12:33:55 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "paul-pl.chen" X-Patchwork-Id: 13934506 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 5A06CE77188 for ; Fri, 10 Jan 2025 12:52:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type: Content-Transfer-Encoding:MIME-Version:Message-ID:Date:Subject:CC:To:From: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=sbyY/dLJKnwhMtn8olYX/SdnuBiSGSBddV3RnGGZbYM=; b=gY/aAC74DrdenezM+POHwm2qua aIy0z7DNLx/Gj2SiVN8xG7MpcRDJmfuMbF6Qa3VcL2hP/ta4Kt3CjvOxh1mzgf5KZ7qs0kxMz1D8Z YXgognPrmTYmnxBQJI5wRE4VDjqyJpEd2mxFWzjF7mcATo+FiS4W8LlHfgRBQ7vrHmstbNYV9fVtW tPJNmJmE5ypVpwhsSfD1ucRSHu0s/Z0YVrqEc3RG6cOlEhM9jBqa6LuK8bo6sJdLKcwo19jtp7Pqk NNvzsGbuFe3jfkm0V7uFppKCmpPrZtgLg9vt8dd0VsiYXELtkEqYfuVFaemOCrelNFjr2QVQnp264 AjwSpQQQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1tWEUt-0000000FMBA-1VAz; Fri, 10 Jan 2025 12:52:19 +0000 Received: from mailgw01.mediatek.com ([216.200.240.184]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1tWEHx-0000000FIpI-0wDZ; Fri, 10 Jan 2025 12:38:59 +0000 X-UUID: d69c78eacf4f11ef82ff63e91e7eb18c-20250110 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Type:Content-Transfer-Encoding:MIME-Version:Message-ID:Date:Subject:CC:To:From; bh=sbyY/dLJKnwhMtn8olYX/SdnuBiSGSBddV3RnGGZbYM=; b=duneBVLuuNrtAJ3qXgmXlB7+iRqF4Hm8MLQXMebhYYJBbRdfSCRp8pZzqOFp6IkIn4/LeZiRVdfX36ORlNbgPMZXyCN2dK+CBZ+OsmYmtKPO2ODwCMmihaJmkCqy1LuEqe2AvfNrt2ffoFHmpx0qw/VZNLMT+xRjRxQKlxkw8Ig=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.46,REQID:a11b586c-7107-481e-a03d-8a9bc3df8ffa,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:60aa074,CLOUDID:2f3cb20e-078a-483b-8929-714244d25c49,B ulkID:nil,BulkQuantity:0,Recheck:0,SF:102,TC:nil,Content:0|50,EDM:-3,IP:ni l,URL: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,NGT X-CID-BAS: 0,NGT,0,_ X-CID-FACTOR: TF_CID_SPAM_SNR X-UUID: d69c78eacf4f11ef82ff63e91e7eb18c-20250110 Received: from mtkmbs14n1.mediatek.inc [(172.21.101.75)] by mailgw01.mediatek.com (envelope-from ) (musrelay.mediatek.com ESMTP with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 11497864; Fri, 10 Jan 2025 05:38:48 -0700 Received: from mtkmbs11n2.mediatek.inc (172.21.101.187) by mtkmbs10n1.mediatek.inc (172.21.101.34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.26; Fri, 10 Jan 2025 20:38:45 +0800 Received: from mtksitap99.mediatek.inc (10.233.130.16) by mtkmbs11n2.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.1118.26 via Frontend Transport; Fri, 10 Jan 2025 20:38:45 +0800 From: paul-pl.chen To: , , , , CC: , , , , , , , , , , , , , , , , Subject: [PATCH 00/12] Add Mediatek Soc DRM support for mt8196 Date: Fri, 10 Jan 2025 20:33:55 +0800 Message-ID: <20250110123835.2719824-1-paul-pl.chen@mediatek.com> X-Mailer: git-send-email 2.45.2 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20250110_043857_305840_AE81D8F0 X-CRM114-Status: UNSURE ( 8.94 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: "Paul-pl.Chen" Add support multiple mmsys instances in the one mediatek-drm instance. Nancy.Lin (7): soc: mediatek: add mmsys support for MT8196 soc: mediatek: mutex: add mutex support for MT8196 drm/mediatek: add EXDMA support for MT8196 drm/mediatek: add BLENDER support for MT8196 drm/mediatek: add OUTPROC support for MT8196 drm/mediatek: add ovlsys_adaptor support for MT8196 drm/mediatek: Add support for multiple mmsys in the one mediatek-drm driver Paul-pl.Chen (5): dt-bindings: arm: mediatek: mmsys: add compatible for MT8196 dt-bindings: soc: mediatek: add mutex yaml for MT8196 dt-bindings: display: mediatek: add EXDMA yaml for MT8196 dt-bindings: display: mediatek: add BLENDER yaml for MT8196 dt-bindings: display: mediatek: add OUTPROC yaml for MT8196 .../bindings/arm/mediatek/mediatek,mmsys.yaml | 5 + .../display/mediatek/mediatek,blender.yaml | 50 ++ .../display/mediatek/mediatek,exdma.yaml | 77 ++ .../display/mediatek/mediatek,outproc.yaml | 57 ++ .../bindings/soc/mediatek/mediatek,mutex.yaml | 2 + drivers/gpu/drm/mediatek/Makefile | 4 + drivers/gpu/drm/mediatek/mtk_crtc.c | 350 ++++++-- drivers/gpu/drm/mediatek/mtk_crtc.h | 6 +- drivers/gpu/drm/mediatek/mtk_ddp_comp.c | 134 +++- drivers/gpu/drm/mediatek/mtk_ddp_comp.h | 6 + drivers/gpu/drm/mediatek/mtk_disp_blender.c | 352 ++++++++ drivers/gpu/drm/mediatek/mtk_disp_blender.h | 17 + drivers/gpu/drm/mediatek/mtk_disp_drv.h | 66 +- drivers/gpu/drm/mediatek/mtk_disp_exdma.c | 447 +++++++++++ drivers/gpu/drm/mediatek/mtk_disp_outproc.c | 244 ++++++ drivers/gpu/drm/mediatek/mtk_disp_outproc.h | 22 + .../drm/mediatek/mtk_disp_ovlsys_adaptor.c | 758 ++++++++++++++++++ drivers/gpu/drm/mediatek/mtk_drm_drv.c | 287 ++++++- drivers/gpu/drm/mediatek/mtk_drm_drv.h | 28 +- drivers/soc/mediatek/mt8196-mmsys.h | 447 +++++++++++ drivers/soc/mediatek/mtk-mmsys.c | 204 ++++- drivers/soc/mediatek/mtk-mmsys.h | 18 + drivers/soc/mediatek/mtk-mutex.c | 233 +++++- include/linux/soc/mediatek/mtk-mmsys.h | 60 ++ include/linux/soc/mediatek/mtk-mutex.h | 2 + 25 files changed, 3734 insertions(+), 142 deletions(-) create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,blender.yaml create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,exdma.yaml create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,outproc.yaml create mode 100644 drivers/gpu/drm/mediatek/mtk_disp_blender.c create mode 100644 drivers/gpu/drm/mediatek/mtk_disp_blender.h create mode 100644 drivers/gpu/drm/mediatek/mtk_disp_exdma.c create mode 100644 drivers/gpu/drm/mediatek/mtk_disp_outproc.c create mode 100644 drivers/gpu/drm/mediatek/mtk_disp_outproc.h create mode 100644 drivers/gpu/drm/mediatek/mtk_disp_ovlsys_adaptor.c create mode 100644 drivers/soc/mediatek/mt8196-mmsys.h