Received: by 2002:a05:7412:b995:b0:f9:9502:5bb8 with SMTP id it21csp158881rdb; Thu, 21 Dec 2023 05:51:43 -0800 (PST) X-Google-Smtp-Source: AGHT+IFqyKQnYwId/VPpB84dGMdjuQyuT8GupnU1pCWPQw3Vs9itKSLowgk/TqP5ulsZ3q9Ll4O+ X-Received: by 2002:a50:9f8d:0:b0:554:264b:23ab with SMTP id c13-20020a509f8d000000b00554264b23abmr845080edf.0.1703166702980; Thu, 21 Dec 2023 05:51:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703166702; cv=none; d=google.com; s=arc-20160816; b=PcB0doxRC7NVwtKAKFVoTg95+eN72Ba+8WfQNPUMLdH0e5wKIgMhxtCGolxexNvTv1 NTBV+4odwDLcWOrI9k9fWvgVuTVrKVPlY2r6zBxHax0FB1qvBphu82pjRAcsocx6gQTM OiGCsQE6ojr6676Yamf3FFlXds99LriBouWGALze1KqumTUdg7fEA8FrF8UVPeebqVjF jn++Jfmkm8Y5LxrgV6H6h0fwpJGqsUXrDtJEHWGjdksaGY9vtcmvLrcQVTNNG++nu+al zYyEnAWdC/oquwUi/WKa59otVmXYqpD54qsnFMjFkGRcuVMBxTzAXjpby4K90EO8/rlk ONMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=LVUFSbN3qi21K+lCGgFuXM1K02jusWBDY0oqKAcbjUE=; fh=Ilhq+P6Z51ZMv1DqLCCrjCGxyeVItmCUkgWryLne6YA=; b=WILj5hDcwqik5tKFD4PnYojlc/gnfFthEf+n9CIBlfICO0//QMyGHLIquu949QVROm bEgIbSCkeHUkaXNf761C67L7jf5W5Oz7hWFb4yBpjuqLzrdxfbZai/kjO2UN8aXKK04K lFFsXWhzkOCfjIDam4441jV0JpzUEXZ8OR7CBxEivhSqUwNNHejU5Kg+lXKmvyYlOp0f FMT/0cL8odP2Pijuh1kECbxF4GG6YesSTX4KMZ9fO3R4RKSpzOoL58lnQZ8HeC7pMiBD Z3uxrZfFEd8QdqeTOldMrW2rRx6x2WpyerWhV1YDfjxFKFtSmnPU6pK2I/udRHpf1R9D xPWw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=QAPUkHd6; spf=pass (google.com: domain of linux-kernel+bounces-8501-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-8501-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.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 s26-20020a508d1a000000b00553f9df5df6si851756eds.213.2023.12.21.05.51.42 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 21 Dec 2023 05:51:42 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-8501-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=@gmail.com header.s=20230601 header.b=QAPUkHd6; spf=pass (google.com: domain of linux-kernel+bounces-8501-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-8501-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.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 8FCC71F228B6 for ; Thu, 21 Dec 2023 13:51:42 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B06307AE99; Thu, 21 Dec 2023 13:39:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="QAPUkHd6" X-Original-To: linux-kernel@vger.kernel.org Received: from mail-pg1-f169.google.com (mail-pg1-f169.google.com [209.85.215.169]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 968FB7AE87; Thu, 21 Dec 2023 13:38:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pg1-f169.google.com with SMTP id 41be03b00d2f7-5cd5cdba609so628816a12.0; Thu, 21 Dec 2023 05:38:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1703165939; x=1703770739; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=LVUFSbN3qi21K+lCGgFuXM1K02jusWBDY0oqKAcbjUE=; b=QAPUkHd6JRzBTxtyg3IkME3wab2rzwrm5fQzYFTOaxES52XV1NNgRC2gFG/cNR/opt BMzge6g906prBOo9utL9hZiSNSH5tWpU9mHWAetFVrC6I1t2bIclrQ4s+wbmKpzuZ7UD 1sHn/fafPWI2XZULxNyzmx3+ONGlN0V2fI5i43nMf7BnvguKwLpWKPaWMp09y+X3uDkK HVY4pVW0b4JAH7pogFi5eydce8rrJGueIPibnhYx+zHWGUdTO+ub8bR+k3SCR/hHlbmD CxqpUUCTKn4PLXsjWkrtfxtb7ie/2xnpl/mbSL1CVFL4lvRBGba13z7krCQEtfQlxNyj xZNg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703165939; x=1703770739; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=LVUFSbN3qi21K+lCGgFuXM1K02jusWBDY0oqKAcbjUE=; b=daRirpWoa5r9C0ktNRqY1QV06ziTH9FnJlpE+Q2f5ta8AZgzadA3oX3bapQOZa7Jo2 SOk6sfM0SS6wGxkSnveouMiK3x8iuyV9ehzJZw+Wm3bPkwdt1h66f+qRX1o56zI69ZZT uRDa/wQF1CZvWHlHg2aNzfFmp0AJVYYH79OFtKIGwy4/3vF9J0GM5MVguvvgAWj70jvq Ix6kb0QLUv1Je3onQiTZwDfj8Fa96XgOWHaMTBcAdoqn8/C6ApwZ0HcFOYo0Iy0POSPZ vCK4DU25brp2TuWQH/OlnAhreKSexz79tDTjgWFg9NsDSTIGbDcG/wbf5g0y0+ZA3PD2 VcOA== X-Gm-Message-State: AOJu0YyX+KWqHsSXXL6vX/APxkWcA3yhDE+480FVxoJku9yjmZRqtlc7 4ZnVMQTL57lU4o8ZTzM3uNIo8DszKq7y0848Nno= X-Received: by 2002:a17:90b:3648:b0:28b:6aa5:34a3 with SMTP id nh8-20020a17090b364800b0028b6aa534a3mr5032677pjb.60.1703165938655; Thu, 21 Dec 2023 05:38:58 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20231221084723.2152034-1-hugues.fruchet@foss.st.com> <769a1510-f8d2-4095-9879-42f413141dee@gmail.com> In-Reply-To: From: Adam Ford Date: Thu, 21 Dec 2023 07:38:47 -0600 Message-ID: Subject: Re: [PATCH v5 0/5] Add support for video hardware codec of STMicroelectronics STM32 SoC series To: Alex Bee Cc: Hugues FRUCHET , Nicolas Dufresne , Marco Felsch , Philipp Zabel , Andrzej Pietrasiewicz , Sakari Ailus , Benjamin Gaignard , Laurent Pinchart , Benjamin Mugnier , Mauro Carvalho Chehab , linux-kernel@vger.kernel.org, Daniel Almeida , Heiko Stuebner , Hans Verkuil , Rob Herring , Conor Dooley , linux-stm32@st-md-mailman.stormreply.com, Krzysztof Kozlowski , linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, devicetree@vger.kernel.org, Maxime Coquelin , linux-media@vger.kernel.org, Alexandre Torgue , Ezequiel Garcia Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Thu, Dec 21, 2023 at 7:31=E2=80=AFAM Alex Bee wrot= e: > > Hi Hugues, > > Am 21.12.23 um 14:08 schrieb Hugues FRUCHET: > > Hi Alex, > > > > This is because VDEC and VENC are two separated IPs with their own > > hardware resources and no links between both. > > On future SoCs, VDEC can ship on its own, same for VENC. > > > I think that's what the driver is/was designed for :) > > I don't think there _has_ to be a link between variants in the same file= . > For Rockchip we only had the issue that there _is_ a link (shared > resources) between encoder and decoder and they had (for that reason) to = be > defined has a _single_ variant. And there is no reason you can ship decod= er > and encoder seperated when you have two variants (with different > compatibles). > For Rockchip and iMX those files are even containing variants for complet= ly > different generations / different SoCs. I had to cleanup this mess for The i.MX8M Mini and Plus have different power domains for encoder and decoders as well as different clocks. Keeping them separate would almost be necessary. adam > Rockchip once - and it was no fun :) Anyways: It's up to the maintainers = I > guess - I just wanted to ask if I missunderstand something here. > > Greetings, > > Alex > > > Hoping that this clarify. > > > > Best regards, > > Hugues. > > > > On 12/21/23 13:40, Alex Bee wrote: > >> Hi Hugues, Hi Nicolas, > >> > >> is there any specific reason I'm not understanding / seeing why this > >> is added in two seperate vdec* / venc* files and not a single vpu* > >> file? Is it only for the seperate clocks (-names) / irqs (-names) / > >> callbacks? Those are defined per variant and perfectly fit in a > >> single file holding one vdec and one venc variant. > >> > >> Alex > >> > >> Am 21.12.23 um 09:47 schrieb Hugues Fruchet: > >>> This patchset introduces support for VDEC video hardware decoder > >>> and VENC video hardware encoder of STMicroelectronics STM32MP25 > >>> SoC series. > >>> > >>> This initial support implements H264 decoding, VP8 decoding and > >>> JPEG encoding. > >>> > >>> This has been tested on STM32MP257F-EV1 evaluation board. > >>> > >>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > >>> =3D history =3D > >>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > >>> version 5: > >>> - Precise that video decoding as been successfully tested up to > >>> full HD > >>> - Add Nicolas Dufresne reviewed-by > >>> > >>> version 4: > >>> - Fix comments from Nicolas about dropping encoder raw steps > >>> > >>> version 3: > >>> - Fix remarks from Krzysztof Kozlowski: > >>> - drop "items", we keep simple enum in such case > >>> - drop second example - it is the same as the first > >>> - Drop unused node labels as suggested by Conor Dooley > >>> - Revisit min/max resolutions as suggested by Nicolas Dufresne > >>> > >>> version 2: > >>> - Fix remarks from Krzysztof Kozlowski on v1: > >>> - single video-codec binding for both VDEC/VENC > >>> - get rid of "-names" > >>> - use of generic node name "video-codec" > >>> > >>> version 1: > >>> - Initial submission > >>> > >>> Hugues Fruchet (5): > >>> dt-bindings: media: Document STM32MP25 VDEC & VENC video codecs > >>> media: hantro: add support for STM32MP25 VDEC > >>> media: hantro: add support for STM32MP25 VENC > >>> arm64: dts: st: add video decoder support to stm32mp255 > >>> arm64: dts: st: add video encoder support to stm32mp255 > >>> > >>> .../media/st,stm32mp25-video-codec.yaml | 50 ++++++++ > >>> arch/arm64/boot/dts/st/stm32mp251.dtsi | 12 ++ > >>> arch/arm64/boot/dts/st/stm32mp255.dtsi | 17 +++ > >>> drivers/media/platform/verisilicon/Kconfig | 14 ++- > >>> drivers/media/platform/verisilicon/Makefile | 4 + > >>> .../media/platform/verisilicon/hantro_drv.c | 4 + > >>> .../media/platform/verisilicon/hantro_hw.h | 2 + > >>> .../platform/verisilicon/stm32mp25_vdec_hw.c | 92 ++++++++++++++ > >>> .../platform/verisilicon/stm32mp25_venc_hw.c | 115 > >>> ++++++++++++++++++ > >>> 9 files changed, 307 insertions(+), 3 deletions(-) > >>> create mode 100644 > >>> Documentation/devicetree/bindings/media/st,stm32mp25-video-codec.yaml > >>> create mode 100644 > >>> drivers/media/platform/verisilicon/stm32mp25_vdec_hw.c > >>> create mode 100644 > >>> drivers/media/platform/verisilicon/stm32mp25_venc_hw.c > >>> > >>