Message ID | 20221208142006.425809-6-paul.kocialkowski@bootlin.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp224873wrr; Thu, 8 Dec 2022 06:24:54 -0800 (PST) X-Google-Smtp-Source: AA0mqf5KleWvu13aOOhlsQTDfON18urC7bWUbE5PUa9ZhZb0Sy7US793LSUFSaFJzebTOgNIeSei X-Received: by 2002:aa7:81cb:0:b0:56e:1092:1272 with SMTP id c11-20020aa781cb000000b0056e10921272mr78896330pfn.31.1670509494023; Thu, 08 Dec 2022 06:24:54 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1670509494; cv=none; d=google.com; s=arc-20160816; b=QI4EO36HIkUy/qrtEZZ7dLQfJy3pbfdaiYiYlCPBgtw4sLC9S88LKiupDfVMbPfFhg Y+M6D9hOYXOld6+Ot/sD3X4dHNoCOTtUtz34tv2u6UQcnbaX1Tfo1bKmnhpjj1Sn6hNB 67QjTavkK4YhrgB1pU/YIBFWGsB5yTUeQX8itUU2P1/vXKJ+CQ8jbsNBKaQn5vKEaYgk f+zfHVYh9PeoV3+fS7HIO/uP3bGYt/G0SeLGsI70pZp1Qx58Ee8NMmpibKOszrdkAC51 DEaou1jlPEGVny1q4oIFFMYnCiYY7c0jW9AZNf6IDAl+m9DMKln5DRQ2vUi/g2ACTH8U cWAA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=DcI0CE2vpt8M7xlyKhWsNrg5u9xwZtrv/Ts2Ew1lIMc=; b=EAGf/y98whyggM7Ds2ffFq/DoWGmTNguFqsgAaOEVOkUiTtRLmViRitxm81awjYLXe 9Ud53o5K0qrl40RRUaFXAEOQ/LFu8q5WeSkQ11fHh3Oy2Dtyh++sSrjPzauwBppjDj5v JdGYAig1v21DyH/LtKe0f+5Wny7U/JtSFsGKn9xn8H3DoUv+Hs8KKWddYe8o0f6R1yFY DskQcxdfI+IfJJ4qZY5XARlFoWtiVi8Uy7qnpnPis5vlM/4pnF0yI9KZ1zeaBx8yChKt V+BcVlXxzqjay13lgcbq0i/laSWycG5xr13wFghh6MoeOr7wI7OJVDF6yNWSrHaMWjgz qeAA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=NUTQupy9; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 70-20020a630149000000b00478ff3661d1si3827448pgb.440.2022.12.08.06.24.40; Thu, 08 Dec 2022 06:24:54 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=NUTQupy9; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230025AbiLHOU4 (ORCPT <rfc822;foxyelen666@gmail.com> + 99 others); Thu, 8 Dec 2022 09:20:56 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48892 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229847AbiLHOUo (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 8 Dec 2022 09:20:44 -0500 Received: from relay6-d.mail.gandi.net (relay6-d.mail.gandi.net [IPv6:2001:4b98:dc4:8::226]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5CCCC84DD2; Thu, 8 Dec 2022 06:20:39 -0800 (PST) Received: (Authenticated sender: paul.kocialkowski@bootlin.com) by mail.gandi.net (Postfix) with ESMTPSA id E8DDCC001E; Thu, 8 Dec 2022 14:20:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1670509237; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=DcI0CE2vpt8M7xlyKhWsNrg5u9xwZtrv/Ts2Ew1lIMc=; b=NUTQupy9h9GiEVOPXOZIucyLmIa8F5OCH+jK9GuNbCCMRX/nWubMvp8590YSc0Di8t66N3 c2fqtdypEndYmjytjJuaVGrDAaqoDGn0nXhWWPCy4H9ECzo+lfVH3k9zxz3/MD/s/tK65c /DJlwZxNCSf9vdrmsttFr424GCXMTPg2OdNwh2LpTkIHtT4O7v4fMgsIA2rdInUh4sXFfb WwsXK5CHXnu12C4nteflqtOI3grHazyb0qjKY3oCQg4m8/AoB+n4GnRPcTYqgrXZhx0htd B8QX6wI3kpzjjRDi04QMNGibIjIbD21CC9MjrDDWebwJE+mPwrwSPfxC6cD+Yg== From: Paul Kocialkowski <paul.kocialkowski@bootlin.com> To: linux-media@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org, linux-staging@lists.linux.dev Cc: Yong Deng <yong.deng@magewell.com>, Paul Kocialkowski <paul.kocialkowski@bootlin.com>, Mauro Carvalho Chehab <mchehab@kernel.org>, Chen-Yu Tsai <wens@csie.org>, Jernej Skrabec <jernej.skrabec@gmail.com>, Samuel Holland <samuel@sholland.org>, Thomas Petazzoni <thomas.petazzoni@bootlin.com>, Hans Verkuil <hverkuil@xs4all.nl>, Sakari Ailus <sakari.ailus@iki.fi>, Conor Dooley <conor@kernel.org>, Nathan Chancellor <nathan@kernel.org> Subject: [PATCH v3 05/12] media: sun6i-mipi-csi2: Clarify return code handling in stream off path Date: Thu, 8 Dec 2022 15:19:59 +0100 Message-Id: <20221208142006.425809-6-paul.kocialkowski@bootlin.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221208142006.425809-1-paul.kocialkowski@bootlin.com> References: <20221208142006.425809-1-paul.kocialkowski@bootlin.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1751656163319801286?= X-GMAIL-MSGID: =?utf-8?q?1751656163319801286?= |
Series |
Allwinner A31/A83T CSI/ISP/MIPI CSI-2 media fixes
|
|
Commit Message
Paul Kocialkowski
Dec. 8, 2022, 2:19 p.m. UTC
Explicitly set ret to zero instead of assigning it and overwriting it later,
which is a bit confusing to understand.
Signed-off-by: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
---
.../media/platform/sunxi/sun6i-mipi-csi2/sun6i_mipi_csi2.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/media/platform/sunxi/sun6i-mipi-csi2/sun6i_mipi_csi2.c b/drivers/media/platform/sunxi/sun6i-mipi-csi2/sun6i_mipi_csi2.c index 484ac5f054d5..a220ce849b41 100644 --- a/drivers/media/platform/sunxi/sun6i-mipi-csi2/sun6i_mipi_csi2.c +++ b/drivers/media/platform/sunxi/sun6i-mipi-csi2/sun6i_mipi_csi2.c @@ -188,7 +188,8 @@ static int sun6i_mipi_csi2_s_stream(struct v4l2_subdev *subdev, int on) return -ENODEV; if (!on) { - ret = v4l2_subdev_call(source_subdev, video, s_stream, 0); + v4l2_subdev_call(source_subdev, video, s_stream, 0); + ret = 0; goto disable; } @@ -280,8 +281,6 @@ static int sun6i_mipi_csi2_s_stream(struct v4l2_subdev *subdev, int on) return 0; disable: - if (!on) - ret = 0; phy_power_off(dphy); sun6i_mipi_csi2_disable(csi2_dev);