Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp668098ybb; Wed, 25 Mar 2020 07:24:33 -0700 (PDT) X-Google-Smtp-Source: ADFU+vucPDm8xawCc9r7MNVomlaHy1/+r3/Ywp1CKXNurrd0IKBoar+0SzongMG7/8EGNc/b2+65 X-Received: by 2002:a9d:1d43:: with SMTP id m61mr2679254otm.91.1585146272685; Wed, 25 Mar 2020 07:24:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585146272; cv=none; d=google.com; s=arc-20160816; b=YoWjd8OBXDtUYTdoUacv8v6vMf+mOXJmV/JLuSwJtShnkhKG4vgIpLlfA17Pybym4r vDjeFLSm4D54J9NvRkgTiwaNAKV6oAFoejVFu6EVP218YRRRjHWZEAZD2u2Zi1boReqo IgY1oJdfzAoPTkyWXnmzyy1gKjdq3yOusnMST5ABZPQB2s0kURoPcY0yMeU+UhksqSbb bmRungL8W163JOm4wnAT/qGJc3Yd9gfUJFs2lnYSt7JjL7D3D29AX2cIPXRxwM9BxjWg N0duu99yqvDP5V7oIA31kzbvXgX/+BNezmYw3qF7FM+Pquq5dNOrJKAHXBe+Tnz2lICq 5xzQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:content-disposition :mime-version:message-id:subject:to:from:date:dkim-signature; bh=pcFRyCnL2SJ7lsWb00Ktgfpiha1T6QVZTxHpgve0HfA=; b=PEv6z1iT/ikeg/3iggX66X+FYvNtiyHqH42jqYEbDI3eRO3gxxdZq/vvgS/s7T5w6r 400ftEFjhdKYb2U0etgTgRjRFQ47emXD4XzHFU72cw1e4Ge/H7a+7WgYv4MFv6QIAjnd HyIzuBuXHYrVAce/i+4+a1gNeV99ofs7Vf/DNA0ZOiBC8PkHeJoj7/EMKs8cF0El84uJ OMEQ1eyqvd33txIhMvCmMUk7VzsHoe18BF2LzrRuL4V1opV63dld0Kj3yAxjv1acwWlu A6Cz+QSyslfu/01YEVWIHxhgMLlUVF0dpNXjq5tBEO0m+4u4JW/SFz2MVTWn7jod9aF3 OFFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=IBvMOXic; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l6si6267955otf.248.2020.03.25.07.24.18; Wed, 25 Mar 2020 07:24:32 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=IBvMOXic; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727697AbgCYOWe (ORCPT + 99 others); Wed, 25 Mar 2020 10:22:34 -0400 Received: from mail-pg1-f196.google.com ([209.85.215.196]:41262 "EHLO mail-pg1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727579AbgCYOWe (ORCPT ); Wed, 25 Mar 2020 10:22:34 -0400 Received: by mail-pg1-f196.google.com with SMTP id b1so1205655pgm.8 for ; Wed, 25 Mar 2020 07:22:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:mime-version:content-disposition :user-agent; bh=pcFRyCnL2SJ7lsWb00Ktgfpiha1T6QVZTxHpgve0HfA=; b=IBvMOXic3QYDgQSRZGPtISAPOTYAbBG+IPlPXOuv8W5fiiD/2joX9ypEKZDeqzeXtR 9hv8+1RDYXz/f0teGPl8n/iRkNmc7DMFBw6PpIJ29ObnRdulDiQB9oz0xG2tz6jqMUXp cfNHYHvZPQVuVfWaa93mk4GzBZ/ynzZbbl4OwI2Pt+lARObkyRoCkY0JcZy0y8cq5u8F RkTgMPqCwAyUj/JuNLaeHL57azs0LRCeL12fOcQb8KK4dMmRY2sVY80+L1JsUZeYigx3 qbNYX7PL1yYalalmDh8yUsrxxnR4f6kTkc/jcu3VtRtbXItJy3KqVugRDo6VH7/R1OKo talw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:mime-version :content-disposition:user-agent; bh=pcFRyCnL2SJ7lsWb00Ktgfpiha1T6QVZTxHpgve0HfA=; b=QNzvjSHbYqY+5ztP/x1FEUvr0lvtkWciY7gXcANJmlHM/lU8U1M/ZCBTSSNlEwI0Fk U6HH1yY630EVLDhPwwJubQnzVbMJFMH/KcUn4NUfnrNf2zY5Mfp2AcEuSZnUJm9HR2nc jeKeEP7KZpDftMn7nVFh45ZnvFEs+KiqYid2eYHtAr5WeD+uubG8FcOhctLbzZkcY26n O8TWs/aiQTXnIvTdMRLl/0Nax/zAT4fAQD6r1ucDgzl/HQmQyqz+aQTsAngtAnuaNfZF kHhi7asKz2G5f13YxJPdi36fEPj6EHAhPWafZqKQUJVHtLJOWxsJESJdXk2uzTpFW7/9 eGow== X-Gm-Message-State: ANhLgQ09HipX3sV/41ERCv3+nMtc18xJCt4uvyez+a/5+8RYNdYRfTPV 1OpvJHmL9pGqPSIkK2rlxr4= X-Received: by 2002:a63:7359:: with SMTP id d25mr3285349pgn.2.1585146152947; Wed, 25 Mar 2020 07:22:32 -0700 (PDT) Received: from simran-Inspiron-5558 ([2409:4052:78f:bb47:8124:5e4b:ea06:7595]) by smtp.gmail.com with ESMTPSA id x4sm16570514pgi.76.2020.03.25.07.22.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Mar 2020 07:22:32 -0700 (PDT) Date: Wed, 25 Mar 2020 19:52:26 +0530 From: Simran Singhal To: Greg Kroah-Hartman , devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org, outreachy-kernel Subject: [PATCH] staging: rtl8723bs: Remove multiple assignments Message-ID: <20200325142226.GA14711@simran-Inspiron-5558> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Remove multiple assignments by factorizing them. Problem found using checkpatch.pl:- CHECK: multiple assignments should be avoided Signed-off-by: Simran Singhal --- drivers/staging/rtl8723bs/core/rtw_cmd.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/staging/rtl8723bs/core/rtw_cmd.c b/drivers/staging/rtl8723bs/core/rtw_cmd.c index 61a9bf61b976..744b40dd4cf0 100644 --- a/drivers/staging/rtl8723bs/core/rtw_cmd.c +++ b/drivers/staging/rtl8723bs/core/rtw_cmd.c @@ -194,7 +194,9 @@ int rtw_init_cmd_priv(struct cmd_priv *pcmdpriv) pcmdpriv->rsp_buf = pcmdpriv->rsp_allocated_buf + 4 - ((SIZE_PTR)(pcmdpriv->rsp_allocated_buf) & 3); - pcmdpriv->cmd_issued_cnt = pcmdpriv->cmd_done_cnt = pcmdpriv->rsp_cnt = 0; + pcmdpriv->cmd_issued_cnt = 0; + pcmdpriv->cmd_done_cnt = 0; + pcmdpriv->rsp_cnt = 0; mutex_init(&pcmdpriv->sctx_mutex); exit: @@ -2138,7 +2140,8 @@ void rtw_setassocsta_cmdrsp_callback(struct adapter *padapter, struct cmd_obj * goto exit; } - psta->aid = psta->mac_id = passocsta_rsp->cam_id; + psta->aid = passocsta_rsp->cam_id; + psta->mac_id = passocsta_rsp->cam_id; spin_lock_bh(&pmlmepriv->lock); -- 2.17.1