From patchwork Tue May 10 11:51:29 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 15872 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 D78FCC3275 for ; Tue, 10 May 2022 11:52:33 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 77E416569F; Tue, 10 May 2022 13:52:33 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org; s=mail; t=1652183553; bh=uk7QSLv2qM0UlTKkUT4qWhdMuv+9FNoxBd4UtAMVX14=; h=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=cOjhzEKKS9csVH2hEj0RXHYCvTOpGZIxcvGeqbchqmYNcRRWX4SXrk/32+p3H4HSd VhSI0zaPyeR85E2ufYISOToNmZWak/D8V4yoMxHxVSwAT4pKGvVHT5HBpCBupjzDkn O/C5sqr0ENa8COVfCEOkmtO7SsrYxUUkxk8r3VA7FUXy18tTjFFys9jOd8esrg3Vc7 aPrb6FMCjktD4JnrT15k/Qa1/sMFsbHbxYds7jE12eST+HWp5F2a7HxMZO01HI7oV2 4P9nMRB3LwXPK6Yyc0i9UqmvZkccopGDuNLLhBdiESmgAl0iUPglocbuYK9PA4et/A Gga8Snm7WASsA== Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 709AB6566A for ; Tue, 10 May 2022 13:52:24 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="lnWZYK7G"; dkim-atps=neutral Received: from pendragon.lan (62-78-145-57.bb.dnainternet.fi [62.78.145.57]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 81A66D18; Tue, 10 May 2022 13:52:23 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1652183544; bh=uk7QSLv2qM0UlTKkUT4qWhdMuv+9FNoxBd4UtAMVX14=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lnWZYK7GsmbTF8kuGsPZhrCgE2T+1B5Rkf6ianutoom90chzgz+Pb0vYKFIkFZ6gD eKpSvL1ueUVepgB+HNZm1XEScL9Jiof4U6Rvr7GjwNRE7RLMJt2/clkZHhvH3VLElS PDfE481GeXeukVWapCT7U2gWQXwPhvSwq8fr2IEA= To: libcamera-devel@lists.libcamera.org Date: Tue, 10 May 2022 14:51:29 +0300 Message-Id: <20220510115147.19360-33-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220510115147.19360-1-laurent.pinchart@ideasonboard.com> References: <20220510115147.19360-1-laurent.pinchart@ideasonboard.com> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 32/50] staging: media: imx: imx7-media-csi: Drop error message on alloc failure 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: Laurent Pinchart via libcamera-devel From: Laurent Pinchart Reply-To: Laurent Pinchart Cc: Martin Kepplinger , kernel@pengutronix.de, Dorota Czaplejewicz , Alexander Stein , Rui Miguel Silva , Philipp Zabel , Steve Longerbeam Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" The kernel memory allocators already complain loudly to the log when allocation fails. There's no need for an additional message. Signed-off-by: Laurent Pinchart --- drivers/staging/media/imx/imx7-media-csi.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/staging/media/imx/imx7-media-csi.c b/drivers/staging/media/imx/imx7-media-csi.c index 2106a72ebe85..e5dc9525fa52 100644 --- a/drivers/staging/media/imx/imx7-media-csi.c +++ b/drivers/staging/media/imx/imx7-media-csi.c @@ -442,10 +442,8 @@ static int imx7_csi_alloc_dma_buf(struct imx7_csi *csi, buf->len = PAGE_ALIGN(size); buf->virt = dma_alloc_coherent(csi->dev, buf->len, &buf->phys, GFP_DMA | GFP_KERNEL); - if (!buf->virt) { - dev_err(csi->dev, "%s: failed\n", __func__); + if (!buf->virt) return -ENOMEM; - } return 0; }