From patchwork Wed Aug 4 11:26:03 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Umang Jain X-Patchwork-Id: 13193 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 76D07C3235 for ; Wed, 4 Aug 2021 11:26:12 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id D7D12687B6; Wed, 4 Aug 2021 13:26:11 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="tJTmuV1H"; dkim-atps=neutral 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 3A02D6026E for ; Wed, 4 Aug 2021 13:26:10 +0200 (CEST) Received: from perceval.ideasonboard.com (unknown [103.251.226.40]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 0FB7724F; Wed, 4 Aug 2021 13:26:08 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1628076369; bh=ggRcDA3XoNm0MRH18417HdtYo6YEUUmJoCWVUEz8RsY=; h=From:To:Cc:Subject:Date:From; b=tJTmuV1HPobJM4JCTun3YuKKcDkRP3RNlZNQuh8oo5apCWwdtsTec0QmxTzdSpRcU l7zybtcrnhef3mcE2ORkYbFaQyuYUNN7UwuzoB+41bZcQbGFXnZTouB/m5od0Ts6cR GZHwzSMkQh+oIYY00jTkZCktJl/hRXIlUjOvf3zQ= From: Umang Jain To: libcamera-devel@lists.libcamera.org Date: Wed, 4 Aug 2021 16:56:03 +0530 Message-Id: <20210804112603.152493-1-umang.jain@ideasonboard.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH] ipu3: Disallow raw only camera configuration 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: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Ideally to capture the raw frames, ImgU should not be required. However, we do need to configure the IPA since, it shall setup the sensor controls (exposure, vblank and so on) for the capture. One cannot simply configure the IPA, without the ImgU as the parameters and statistics buffer passed to the IPA are actually managed by the ImgU. Until we prepare and setup the ImgU to run an internal queue for raw-only camera configuration, disallow this configuration and report it as invalid. Signed-off-by: Umang Jain --- src/libcamera/pipeline/ipu3/ipu3.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/libcamera/pipeline/ipu3/ipu3.cpp b/src/libcamera/pipeline/ipu3/ipu3.cpp index 76c3bb3d..3e159279 100644 --- a/src/libcamera/pipeline/ipu3/ipu3.cpp +++ b/src/libcamera/pipeline/ipu3/ipu3.cpp @@ -248,6 +248,10 @@ CameraConfiguration::Status IPU3CameraConfiguration::validate() if (rawCount > 1 || yuvCount > 2) { LOG(IPU3, Debug) << "Camera configuration not supported"; return Invalid; + } else if (rawCount && !yuvCount) { + LOG(IPU3, Debug) + << "Camera configuration cannot support raw-only streams"; + return Invalid; } /*