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 X-Spam-Level: X-Spam-Status: No, score=-8.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 461D4ECE58C for ; Wed, 9 Oct 2019 20:48:51 +0000 (UTC) Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 23900218AC for ; Wed, 9 Oct 2019 20:48:51 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 23900218AC Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=lip6.fr Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=driverdev-devel-bounces@linuxdriverproject.org Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id C3D1B86D82; Wed, 9 Oct 2019 20:48:50 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ShXrLUnMABTD; Wed, 9 Oct 2019 20:48:49 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by hemlock.osuosl.org (Postfix) with ESMTP id 4921D883EB; Wed, 9 Oct 2019 20:48:49 +0000 (UTC) Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 884CB1BF41B for ; Wed, 9 Oct 2019 20:48:47 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 5D0BA232FA for ; Wed, 9 Oct 2019 20:48:47 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id wNupopuIAJbC for ; Wed, 9 Oct 2019 20:48:46 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by silver.osuosl.org (Postfix) with ESMTPS id 151B7232F2 for ; Wed, 9 Oct 2019 20:48:45 +0000 (UTC) X-IronPort-AV: E=Sophos;i="5.67,277,1566856800"; d="scan'208";a="405491148" Received: from 81-65-53-202.rev.numericable.fr (HELO hadrien) ([81.65.53.202]) by mail2-relais-roc.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 09 Oct 2019 22:48:44 +0200 Date: Wed, 9 Oct 2019 22:48:43 +0200 (CEST) From: Julia Lawall X-X-Sender: jll@hadrien To: Jules Irenge Subject: Re: [Outreachy kernel] [PATCH] staging: qlge: Fix multiple assignments warning by splitting the assignement into two each In-Reply-To: <20191009204311.7988-1-jbi.octave@gmail.com> Message-ID: References: <20191009204311.7988-1-jbi.octave@gmail.com> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 X-BeenThere: driverdev-devel@linuxdriverproject.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux Driver Project Developer List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devel@driverdev.osuosl.org, GR-Linux-NIC-Dev@marvell.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, outreachy-kernel@googlegroups.com, gregkh@linuxfoundation.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: driverdev-devel-bounces@linuxdriverproject.org Sender: "devel" On Wed, 9 Oct 2019, Jules Irenge wrote: > Fix multiple assignments warning " check > issued by checkpatch.pl tool: > "CHECK: multiple assignments should be avoided". > > Signed-off-by: Jules Irenge > --- > drivers/staging/qlge/qlge_dbg.c | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/drivers/staging/qlge/qlge_dbg.c b/drivers/staging/qlge/qlge_dbg.c > index 086f067fd899..69bd4710c5ec 100644 > --- a/drivers/staging/qlge/qlge_dbg.c > +++ b/drivers/staging/qlge/qlge_dbg.c > @@ -141,8 +141,10 @@ static int ql_get_serdes_regs(struct ql_adapter *qdev, > u32 *direct_ptr, temp; > u32 *indirect_ptr; > > - xfi_direct_valid = xfi_indirect_valid = 0; > - xaui_direct_valid = xaui_indirect_valid = 1; > + xfi_indirect_valid = 0; > + xfi_direct_valid = xfi_indirect_valid; > + xaui_indirect_valid = 1; > + xaui_direct_valid = xaui_indirect_valid Despite checkpatch, I think that the original code was easier to understand. julia > > /* The XAUI needs to be read out per port */ > status = ql_read_other_func_serdes_reg(qdev, > -- > 2.21.0 > > -- > You received this message because you are subscribed to the Google Groups "outreachy-kernel" group. > To unsubscribe from this group and stop receiving emails from it, send an email to outreachy-kernel+unsubscribe@googlegroups.com. > To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20191009204311.7988-1-jbi.octave%40gmail.com. > _______________________________________________ devel mailing list devel@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel