From mboxrd@z Thu Jan 1 00:00:00 1970 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 54DE0F99363 for ; Thu, 23 Apr 2026 09:47:13 +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:To:From: Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=qgLpb03rA/VB4m2qJlLIRGjqfCwA9y2IVE+wL7RS9A4=; b=bJ3DKIyoot8xBE xsoHllPSLwmrtyluY1f3JYBtKhDf6ey9L8ouqCTLbWey8bEDpOuA1+bTCYjRv5+TtYTtml9thHZSw 1WTIP0tJemdZUwgA+I57Az0w8nmdZsRBb+zScje4xrxByB9iS9BISfVO0HLwS4K54uigLaK4vSwkP lr0f1Fp9GJfTMEvUWreo/2qIr6EVFDoWTTSR1r0JFLEmfX4kKU8uchrxk9/sqQ49yUBWKnTvpmoL6 3r1ry6rfJwphkikw2wPi7M959Z5hC0rV/ys06AOrCV6zzA0XvOTEvYB6861SsrXLFebmq6IJ3VxR4 k48fGDWIXq58XQiPeHEw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux)) id 1wFqeO-0000000BQ10-19uS; Thu, 23 Apr 2026 09:47:12 +0000 Received: from mailgw01.mediatek.com ([216.200.240.184]) by bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux)) id 1wFqeM-0000000BPyZ-1yz2; Thu, 23 Apr 2026 09:47:11 +0000 X-UUID: 620b13223ef911f19e7563141e833ce8-20260423 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:To:From; bh=qgLpb03rA/VB4m2qJlLIRGjqfCwA9y2IVE+wL7RS9A4=; b=MX5u9jLmAb10Mb4RRx7z4xcFc5E8JwEOfwnXAmG1+oDdDt2BKbf5HRY4eY5uA/lRYjf6EoPE0M6oE8NMtqDbmHDji1tu68jDEkuZvar79PhM2mZxFjyYPe2/7UPVUdsX7sclrQSemY7zml2jRuwDOOZSLWDGO2uK2c0t8/c6des=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.3.12,REQID:5b0a56d9-ae7d-4a7f-9396-96af87533e05,IP:0,U RL:0,TC:0,Content:0,EDM:-25,RT:0,SF:0,FILE:0,BULK:0,RULE:Release_Ham,ACTIO N:release,TS:-25 X-CID-META: VersionHash:e7bac3a,CLOUDID:9f667e64-469e-4eb6-aeb8-4b21454b0f32,B ulkID:nil,BulkQuantity:0,Recheck:0,SF:102|836|865|888|898,TC:-5,Content:0| 15|50,EDM:2,IP:nil,URL:0,File:130,RT:0,Bulk:nil,QS:nil,BEC:-1,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: 2,SSN|SDN X-CID-BAS: 2,SSN|SDN,0,_ X-CID-FACTOR: TF_CID_SPAM_SNR X-CID-RHF: D41D8CD98F00B204E9800998ECF8427E X-UUID: 620b13223ef911f19e7563141e833ce8-20260423 Received: from mtkmbs11n1.mediatek.inc [(172.21.101.185)] by mailgw01.mediatek.com (envelope-from ) (musrelay.mediatek.com ESMTP with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 214902854; Thu, 23 Apr 2026 02:47:03 -0700 Received: from mtkmbs13n2.mediatek.inc (172.21.101.108) by MTKMBS09N1.mediatek.inc (172.21.101.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29; Thu, 23 Apr 2026 17:47:01 +0800 Received: from mhfsdcap04.gcn.mediatek.inc (10.17.3.154) by mtkmbs13n2.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.2562.29 via Frontend Transport; Thu, 23 Apr 2026 17:47:00 +0800 From: Kyrie Wu To: Hans Verkuil , Mauro Carvalho Chehab , Rob Herring , Krzysztof Kozlowski , Nicolas Dufresne , Conor Dooley , Matthias Brugger , AngeloGioacchino Del Regno , Kyrie Wu , , , , , Subject: [PATCH v14 00/12]Enable jpeg enc & dec multi-hardwares for MT8196 Date: Thu, 23 Apr 2026 17:46:44 +0800 Message-ID: <20260423094656.32044-1-kyrie.wu@mediatek.com> X-Mailer: git-send-email 2.46.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-MTK: N X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20260423_024710_515105_1E95F771 X-CRM114-Status: GOOD ( 10.50 ) X-BeenThere: linux-mediatek@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-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=archiver.kernel.org@lists.infradead.org This series have the follow changing: Firstly fix some bugs, including resolution change handleing, stop streaming sw flow, fix buffer layout and clock setting to support multi-hw jpeg working and others. Secondly add mt8196 jpegdec and jpegenc compatible to support MT8196 kernel driver. Lastly, Add smmu setting to support smmu and iommu at the same time. This series has been tested with MT8196 tast test. Encoding and decoding worked for this chip. Patches 1 fix jpeg hw count setting to support different chips. Patches 2 fix jpeg buffer payload setting to handle buffer size bug while resolution changed. Patches 3 fix jpeg dst buffer layout. Patches 4 fix multi-core stop streaming flow Patches 5 fix multi-core clk suspend/resume setting Patches 6 fix decoding buffer number setting timing issue Patches 7 fix decoding resolution change operation Patches 8 fix remove buffer operation Patches 9-11 Adds jpeg encoder and decoder compatible. Patches 12 add jpeg smmu sid setting. --- Changes compared with v13: --Rebased on top of the latest media tree Changes compared with v12: --Rebased on top of the latest media tree --fix kernel rebot build warnings in patch 5 Changes compared with v11: --Rebased on top of the latest media tree --Some modifications for patch v11's review comments. --add reviewer to commit messages Changes compared with v10: --Rebased on top of the latest media tree --add reviewer to commit messages Changes compared with v9: --Rebased on top of the latest media tree Changes compared with v8: --Rebased on top of the latest media tree Changes compared with v7: --Rebased on top of the latest media tree Changes compared with v6: --Rebased on top of the latest media tree Changes compared with v5: --reorder the patches set. --fix commit message of patch 1-8. Changes compared with v4: --fix kernel robot build errors for patch 4. --add reviewer for patch 1 and patch 2. Changes compared with v3: --change patch subject of jpeg encoder and decoder compatible. Changes compared with v2: --refactor smmu sid setting function interface --Some modifications for patch v2's review comments. Changes compared with v1: --refine jpeg dt-bindings for MT8196 --optimize software code to manage jpeg HW count --refactor smmu sid setting function interface --Some modifications for patch v1's review comments. Kyrie Wu (12): media: mediatek: jpeg: fix jpeg cores' amounts setting media: mediatek: jpeg: fix jpeg buffer payload size setting media: mediatek: jpeg: fix buffer structure size and layout media: mediatek: jpeg: Fix buffer completion on multi-core streaming stop media: mediatek: jpeg: Fix multi-core clk suspend and resume setting media: mediatek: jpeg: fix decoding buffer number setting timing issue media: mediatek: jpeg: fix resolution change event handling in decoder media: mediatek: jpeg: fix remove buffer removal timing for multi-core media: dt-bindings: mediatek,jpeg: Add mediatek, mt8196-jpgdec compatible media: dt-bindings: mediatek,jpeg: Add mediatek, mt8196-jpgenc compatible media: mediatek: jpeg: add jpeg compatible media: mediatek: jpeg: add jpeg smmu sid setting .../media/mediatek,mt8195-jpegdec.yaml | 8 +- .../media/mediatek,mt8195-jpegenc.yaml | 8 +- .../platform/mediatek/jpeg/mtk_jpeg_core.c | 151 +++++++++++++----- .../platform/mediatek/jpeg/mtk_jpeg_core.h | 19 ++- .../platform/mediatek/jpeg/mtk_jpeg_dec_hw.c | 90 ++++++++++- .../platform/mediatek/jpeg/mtk_jpeg_enc_hw.c | 88 +++++++++- 6 files changed, 308 insertions(+), 56 deletions(-) -- 2.45.2