From patchwork Tue Jun 23 19:54:40 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 223489 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=-10.0 required=3.0 tests=DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT 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 5E406C433DF for ; Tue, 23 Jun 2020 20:24:42 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 398512080C for ; Tue, 23 Jun 2020 20:24:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1592943882; bh=P4si8H1SED+EKjaI6lFpz3kNayMuEC68QWo0fi1aWMA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=qiZkOyNe+Oiaugh/UfUmSwrYkDwMvWon7j8sVuGrRb+YyD13zSAVJWIl9WZaH/353 /nSPGFMYNddgREEy4yBwgCNQmh+HnPQ0Kkgs0v9bBiT5FRE7Fpa0YqdJlc5T/SnLB7 zyw+R/1qN/dswCNmsyReZhLUZZ44fhbnIhpqC9s4= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390179AbgFWUYk (ORCPT ); Tue, 23 Jun 2020 16:24:40 -0400 Received: from mail.kernel.org ([198.145.29.99]:43310 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2390180AbgFWUYg (ORCPT ); Tue, 23 Jun 2020 16:24:36 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id B175D206C3; Tue, 23 Jun 2020 20:24:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1592943876; bh=P4si8H1SED+EKjaI6lFpz3kNayMuEC68QWo0fi1aWMA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=qLi4/2QMsRP4SoN4rpmSLHDWA+F1oyB1kEBNs0EHL5U5XcB7Nk9WZI0KuBTdRGQku tX0AYdG9LR9KthOpgngR85kkHITQr5VVsOHed0xur1EXyfwcpTlKRXqxJxu324z8jW /RfBN+ZIAVEsjv0lb66YSIsTo0IrPwGrTn9Y4K+E= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Aiman Najjar , Dan Carpenter , Sasha Levin Subject: [PATCH 5.4 085/314] staging: rtl8712: fix multiline derefernce warnings Date: Tue, 23 Jun 2020 21:54:40 +0200 Message-Id: <20200623195342.928743926@linuxfoundation.org> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200623195338.770401005@linuxfoundation.org> References: <20200623195338.770401005@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Aiman Najjar [ Upstream commit 269da10b1477c31c660288633c8d613e421b131f ] This patch fixes remaining checkpatch warnings in rtl871x_xmit.c: WARNING: Avoid multiple line dereference - prefer 'psecuritypriv->PrivacyKeyIndex' 636: FILE: drivers/staging//rtl8712/rtl871x_xmit.c:636: + (u8)psecuritypriv-> + PrivacyKeyIndex); WARNING: Avoid multiple line dereference - prefer 'psecuritypriv->XGrpKeyid' 643: FILE: drivers/staging//rtl8712/rtl871x_xmit.c:643: + (u8)psecuritypriv-> + XGrpKeyid); WARNING: Avoid multiple line dereference - prefer 'psecuritypriv->XGrpKeyid' 652: FILE: drivers/staging//rtl8712/rtl871x_xmit.c:652: + (u8)psecuritypriv-> + XGrpKeyid); Signed-off-by: Aiman Najjar Reviewed-by: Dan Carpenter Link: https://lore.kernel.org/r/98805a72b92e9bbf933e05b827d27944663b7bc1.1585508171.git.aiman.najjar@hurranet.com Signed-off-by: Greg Kroah-Hartman Signed-off-by: Sasha Levin --- drivers/staging/rtl8712/rtl871x_xmit.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/drivers/staging/rtl8712/rtl871x_xmit.c b/drivers/staging/rtl8712/rtl871x_xmit.c index cc5809e49e356..7a821921c0da1 100644 --- a/drivers/staging/rtl8712/rtl871x_xmit.c +++ b/drivers/staging/rtl8712/rtl871x_xmit.c @@ -590,7 +590,7 @@ sint r8712_xmitframe_coalesce(struct _adapter *padapter, _pkt *pkt, addr_t addr; u8 *pframe, *mem_start, *ptxdesc; struct sta_info *psta; - struct security_priv *psecuritypriv = &padapter->securitypriv; + struct security_priv *psecpriv = &padapter->securitypriv; struct mlme_priv *pmlmepriv = &padapter->mlmepriv; struct xmit_priv *pxmitpriv = &padapter->xmitpriv; struct pkt_attrib *pattrib = &pxmitframe->attrib; @@ -633,15 +633,13 @@ sint r8712_xmitframe_coalesce(struct _adapter *padapter, _pkt *pkt, case _WEP40_: case _WEP104_: WEP_IV(pattrib->iv, psta->txpn, - (u8)psecuritypriv-> - PrivacyKeyIndex); + (u8)psecpriv->PrivacyKeyIndex); break; case _TKIP_: if (bmcst) TKIP_IV(pattrib->iv, psta->txpn, - (u8)psecuritypriv-> - XGrpKeyid); + (u8)psecpriv->XGrpKeyid); else TKIP_IV(pattrib->iv, psta->txpn, 0); @@ -649,8 +647,7 @@ sint r8712_xmitframe_coalesce(struct _adapter *padapter, _pkt *pkt, case _AES_: if (bmcst) AES_IV(pattrib->iv, psta->txpn, - (u8)psecuritypriv-> - XGrpKeyid); + (u8)psecpriv->XGrpKeyid); else AES_IV(pattrib->iv, psta->txpn, 0);