From patchwork Wed Apr 3 10:25:44 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kieran Bingham X-Patchwork-Id: 901 Return-Path: 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 BB62F6110E for ; Wed, 3 Apr 2019 12:25:57 +0200 (CEST) Received: from Q.imgcgcw.net (unknown [147.50.13.10]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 2A77A9AA; Wed, 3 Apr 2019 12:25:55 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1554287157; bh=aFtJTRlak4oEQjDY4ywqQ2zlXRKvGj+Yg0DShaQGbO4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Eisuneg++3pLmQ10HQbxlKow3Nc//EkGm82s8VS+ELJxpZhkcugCt6EtqsImJC6bu jZfpXWJdf9cyKdg2QvrvtyQIyI/9SDClkG1E9CcWxPo96zGVt0Q/ZHx6RpwYQ6ld0W yMAyUs33XNL6GPCdHpxYewscHTOYbv2rOfmPYI2Q= From: Kieran Bingham To: LibCamera Devel Date: Wed, 3 Apr 2019 17:25:44 +0700 Message-Id: <20190403102545.7143-2-kieran.bingham@ideasonboard.com> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190403102545.7143-1-kieran.bingham@ideasonboard.com> References: <20190403102545.7143-1-kieran.bingham@ideasonboard.com> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 1/2] libcamera: ipu3: Catch return value when disabling links X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 Apr 2019 10:25:58 -0000 Ensure that any error from the disableLinks() call during match() is propogated to the caller. Fixes: d698ed27494a ("libcamera: ipu3: Create ImgUDevice class") Signed-off-by: Kieran Bingham Reviewed-by: Laurent Pinchart --- src/libcamera/pipeline/ipu3/ipu3.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/libcamera/pipeline/ipu3/ipu3.cpp b/src/libcamera/pipeline/ipu3/ipu3.cpp index 164e187c769d..fed04ce50387 100644 --- a/src/libcamera/pipeline/ipu3/ipu3.cpp +++ b/src/libcamera/pipeline/ipu3/ipu3.cpp @@ -511,7 +511,8 @@ bool PipelineHandlerIPU3::match(DeviceEnumerator *enumerator) * going through a library teardown->match() sequence would fail * at the moment. */ - if (imguMediaDev_->disableLinks()) + ret = imguMediaDev_->disableLinks(); + if (ret) goto error; ret = registerCameras();