From patchwork Thu Mar 25 13:42:18 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kieran Bingham X-Patchwork-Id: 11708 X-Patchwork-Delegate: kieran.bingham@ideasonboard.com 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 DAC9EC32E9 for ; Thu, 25 Mar 2021 13:42:39 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 3BE7D68D74; Thu, 25 Mar 2021 14:42:38 +0100 (CET) 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="jPmdKJAK"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 6543B602D5 for ; Thu, 25 Mar 2021 14:42:36 +0100 (CET) Received: from Q.local (cpc89244-aztw30-2-0-cust3082.18-1.cable.virginm.net [86.31.172.11]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 3BF9B560; Thu, 25 Mar 2021 14:42:35 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1616679755; bh=Zx2LcXfUZnX8WTgOgtW7xBH5lkQR0N1PFz7qAVL3mlk=; h=From:To:Cc:Subject:Date:From; b=jPmdKJAKSEZHjj8AndE1kU/6d25wrAl5bmKXXnu2UHTJ3ZV0TWwalvBMTRgGrHfof Na2RCpJZViEY/DSix91FmlWswY1hhSE24tdwnNb63LVZRLF6wOMQVe25vjm8LH5EB8 YhHy7GhSZQ6oLXDqRbuKtsCLUhooF/3ASLzaAnxY= From: Kieran Bingham To: libcamera devel Date: Thu, 25 Mar 2021 13:42:18 +0000 Message-Id: <20210325134231.1400051-1-kieran.bingham@ideasonboard.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 10/11] libcamera: pipeline: ipu3: frames: Fail if the FrameInfo can't be found 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" The FrameInfo structure associates the data sent to the IPA and is essential for handling events. If it can not be found, this is a fatal error which must be fixed. Signed-off-by: Kieran Bingham --- v3: - Make all occurrences of failing to find a frame info fatal. --- src/libcamera/pipeline/ipu3/frames.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/libcamera/pipeline/ipu3/frames.cpp b/src/libcamera/pipeline/ipu3/frames.cpp index e8eb1c5103e8..34ab4be6711b 100644 --- a/src/libcamera/pipeline/ipu3/frames.cpp +++ b/src/libcamera/pipeline/ipu3/frames.cpp @@ -115,7 +115,8 @@ IPU3Frames::Info *IPU3Frames::find(unsigned int id) if (itInfo != frameInfo_.end()) return itInfo->second.get(); - LOG(IPU3, Error) << "Can't find tracking informaton for frame " << id; + LOG(IPU3, Fatal) << "Can't find tracking informaton for frame " << id; + return nullptr; } @@ -133,7 +134,8 @@ IPU3Frames::Info *IPU3Frames::find(FrameBuffer *buffer) return info; } - LOG(IPU3, Error) << "Can't find tracking informaton from buffer"; + LOG(IPU3, Fatal) << "Can't find tracking informaton from buffer"; + return nullptr; }