From patchwork Tue May 2 11:13:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Scally X-Patchwork-Id: 18581 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 050F8BD16B for ; Tue, 2 May 2023 11:14:10 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 4477B633B4; Tue, 2 May 2023 13:14:09 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org; s=mail; t=1683026049; bh=Gph7lxZ6oRl9DneDbS9F4Lvl6LB25JPHaEkWxF+z9yI=; h=To:Date:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:Cc:From; b=n0VVQNIVz6gXswPg3EcRJNURe+Pw4eLX+12GKBBLjmGL7+RwVFVCCpHeE2FqohiOO 090mYHgnuLxz7LGOhIaUGoUxYXN9ShWcCSShRIEAtQWLK0+yqrBzYkJR+uhamghjIc kTAl/PSDv8NFw8Yiop30FYen5EceJCYSz8060ve3BKD5W35e468LfJlkxIKDLwC//X A0Ax0G+YaHOMNqVGqwWMunFLW27IDqKoVCcxYs/oPSsivniYcpbk4a2K30Z6e/7LAV +06C+BYBGlBxoRlzX7bh6CNBY0gussS0cJBXfZeim68qI9LOnoBnXsTLbo7WWnau65 ZjA3ivZ37+kFQ== Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 249C860538 for ; Tue, 2 May 2023 13:14:08 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="RWaootAd"; dkim-atps=neutral Received: from mail.ideasonboard.com (cpc141996-chfd3-2-0-cust928.12-3.cable.virginm.net [86.13.91.161]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id CDEE6800; Tue, 2 May 2023 13:14:05 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1683026046; bh=Gph7lxZ6oRl9DneDbS9F4Lvl6LB25JPHaEkWxF+z9yI=; h=From:To:Cc:Subject:Date:From; b=RWaootAdJkyDpUI9RsI0HnZs3E5MZv3zdzjoFEB1qvAJBS5wnSOP08UH32LUK6N6X PvD570H1Kg668wktYwAC9ZUyX0tgA+tfVAq3gBlCpVnx674B5iSoVZ/N3/xezHpzK0 rKlbrd4Qq2cZjm11vT/JaD/Tr2LUCjBBJ16kh3sA= To: libcamera-devel@lists.libcamera.org Date: Tue, 2 May 2023 12:13:57 +0100 Message-Id: <20230502111357.157442-1-dan.scally@ideasonboard.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH] libcamera: pipeline: simple: Add support for ST's DCMIPP X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Daniel Scally via libcamera-devel From: Dan Scally Reply-To: Daniel Scally Cc: hugues.fruchet@foss.st.com, alain.volmat@foss.st.com Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" The STM32 contains a camera pipeline known as the DCMIPP (Digital Camera-Memory Interface Pixel Processor) which receives data from a parallel interface and dumps the post-processed data to memory. The pipeline is capable of some processing in the form of downscaling captured data through cropping or skipping the sensor's output. The simple pipeline handler is quite capable of handling the DCMIPP given its operation is handled entirely through configuring the pads of a media graph, so add support for the driver to the pipeline's supportedDevices array. Signed-off-by: Daniel Scally Reviewed-by: Kieran Bingham Reviewed-by: Laurent Pinchart --- Support for the dcmipp has been tested on an stm32mp135f-dk with a gc2145 camera sensor. Note that the dcmipp driver **is not** in mainline at the moment, and nor is the gc2145's driver. @Hugues, @Alain, is there a plan to move those drivers upstream? A few changes to ST's kernel were needed to fix some format propagation problems and some missing controls for the GC2145 for this to work. Those can be found in my tree linked below [1], along with some fixes to the CSI-2 to Parallel bridge driver which _is_ upstream and which I posted to linux-media [2]. [1] https://github.com/djrscally/linux/tree/v5.15-stm32mp [2] https://lore.kernel.org/linux-media/20230502103547.150918-1-dan.scally@ideasonboard.com/T/#t src/libcamera/pipeline/simple/simple.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/libcamera/pipeline/simple/simple.cpp b/src/libcamera/pipeline/simple/simple.cpp index e1f8b989..01516bc3 100644 --- a/src/libcamera/pipeline/simple/simple.cpp +++ b/src/libcamera/pipeline/simple/simple.cpp @@ -194,6 +194,7 @@ static const SimplePipelineInfo supportedDevices[] = { { "mxc-isi", {} }, { "qcom-camss", {} }, { "sun6i-csi", {} }, + { "dcmipp", {} }, }; } /* namespace */