From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id BD61DC25B76 for ; Wed, 5 Jun 2024 06:52:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=JANfT3x+njeKUbM1YtvqRo3w0Q1hNZ8rHDAJMZfcK1Q=; b=GpaF3StesDxIZS PVyIWcWLhkva4oy86hIkpgbWsDFaS6OuyZIDxRnTjS7R2mN4EvJ5T33rUp4VQJUFFOuXOFJM4JHir HwGZWgDbZo30txq+azZasPc1XCr2IVzibOjCLwsX5+SRydLOL6cuE5r3ACWPXXpe7gwCQ0SxmQYba UBERLBxt7yspmcehoFRLIWq2GUR6zFX1DHeOezCMbsx0RfnAC2Je8SmU59XhUNoJLsjwhV7J+Kv1/ XEGmLuSDljA8FJAzrBtoBKYQRT50UBTUD4+FAJ1lYd8lIBqynLvwfdSCtRrL7olGLQRVYln8uve+g WpfAgSuE0geClzvi+Hbg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sEkVD-00000004sDs-3p3N; Wed, 05 Jun 2024 06:52:07 +0000 Received: from perceval.ideasonboard.com ([213.167.242.64]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sEkV8-00000004sCM-32xA for linux-arm-kernel@lists.infradead.org; Wed, 05 Jun 2024 06:52:04 +0000 Received: from pendragon.ideasonboard.com (81-175-209-231.bb.dnainternet.fi [81.175.209.231]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 7C2E915C5; Wed, 5 Jun 2024 08:51:43 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1717570303; bh=JQvTXp/u13hNE9HZTmN3031xJuoZnsQBXSw2U3Npr1A=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=imZHXs/AANJYbOULXt7F5RVeuyEPyrKtaRJUDSlqL1PwfooUEON30pqtcQ5k4/oYp wvElV6UWTK1irpVO60p0SgOdhpcC0etJMtLvoomK46JY2HfagbaSreBGKBek+AvvSk lw1yH9dL77hVdGWRX6FOizFmN2tH+j+11orIWuL0= Date: Wed, 5 Jun 2024 09:51:34 +0300 From: Laurent Pinchart To: Stefan Wahren Cc: Greg Kroah-Hartman , Florian Fainelli , Umang Jain , linux-staging@lists.linux.dev, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH 01/11] staging: vchiq_arm: Replace variable ret with status Message-ID: <20240605065134.GC879@pendragon.ideasonboard.com> References: <20240604172904.61613-1-wahrenst@gmx.net> <20240604172904.61613-2-wahrenst@gmx.net> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20240604172904.61613-2-wahrenst@gmx.net> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240604_235202_939498_D342C5DD X-CRM114-Status: GOOD ( 18.02 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Stefan, Thank you for the patch. On Tue, Jun 04, 2024 at 07:28:54PM +0200, Stefan Wahren wrote: > The variable ret is just storing the result of last function > call like the variable status. So replace ret with status > and make a consistent use of this variable. I would have gone the other way around, and replaced 'status' with 'ret' as the latter is more commonly used for this purpose in kernel code. I know it will generate more churn, but I think the result will be more maintainable. > Signed-off-by: Stefan Wahren > --- > .../staging/vc04_services/interface/vchiq_arm/vchiq_arm.c | 8 ++++---- > 1 file changed, 4 insertions(+), 4 deletions(-) > > diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c > index 69daeba974f2..e2f4aa00cb70 100644 > --- a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c > +++ b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c > @@ -1298,7 +1298,6 @@ vchiq_keepalive_thread_func(void *v) > int status; > struct vchiq_instance *instance; > unsigned int ka_handle; > - int ret; > > struct vchiq_service_params_kernel params = { > .fourcc = VCHIQ_MAKE_FOURCC('K', 'E', 'E', 'P'), > @@ -1307,9 +1306,10 @@ vchiq_keepalive_thread_func(void *v) > .version_min = KEEPALIVE_VER_MIN > }; > > - ret = vchiq_initialise(state, &instance); > - if (ret) { > - dev_err(state->dev, "suspend: %s: vchiq_initialise failed %d\n", __func__, ret); > + status = vchiq_initialise(state, &instance); > + if (status) { > + dev_err(state->dev, "suspend: %s: vchiq_initialise failed %d\n", > + __func__, status); > goto exit; > } > -- Regards, Laurent Pinchart _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel