Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C57FB70 for ; Wed, 28 Jul 2021 05:44:34 +0000 (UTC) Received: by mail.kernel.org (Postfix) with ESMTPSA id CF5F360F91; Wed, 28 Jul 2021 05:44:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1627451074; bh=CYjhDYPNMH+Hg9kMhEDMaCiOh0Q61z7lbz39STzyZmg=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=HDpl0uUCU6bga5BodqjpnEYl0kd6HLLgTZMtAPfIgeBwnHH5uiF76teYESxc/N4P7 k/ovqM79T9eyqn6SgP7x6USscrXpWQGUwkqmkTAeIwXiTkI3zRy+yNsdBXldz1UQUJ Hvi6qaBybDCmvB47KKVGK/LzMBZxd/Qe4TYGhA0A= Date: Wed, 28 Jul 2021 07:44:31 +0200 From: Greg Kroah-Hartman To: "Fabio M. De Francesco" Cc: linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: Re: [PATCH] staging: rtl8723bs: core: Fix incorrect type in assignment Message-ID: References: <20210728004223.15102-1-fmdefrancesco@gmail.com> Precedence: bulk X-Mailing-List: linux-staging@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210728004223.15102-1-fmdefrancesco@gmail.com> On Wed, Jul 28, 2021 at 02:42:23AM +0200, Fabio M. De Francesco wrote: > Fix sparse warning: incorrect type in assignment (different base types). > > Signed-off-by: Fabio M. De Francesco > --- > drivers/staging/rtl8723bs/core/rtw_security.c | 31 +++++++++++-------- > 1 file changed, 18 insertions(+), 13 deletions(-) > > diff --git a/drivers/staging/rtl8723bs/core/rtw_security.c b/drivers/staging/rtl8723bs/core/rtw_security.c > index a99f439328f1..527f710c7658 100644 > --- a/drivers/staging/rtl8723bs/core/rtw_security.c > +++ b/drivers/staging/rtl8723bs/core/rtw_security.c > @@ -35,8 +35,10 @@ const char *security_type_str(u8 value) > */ > void rtw_wep_encrypt(struct adapter *padapter, u8 *pxmitframe) > { /* exclude ICV */ > - > - unsigned char crc[4]; > + union { > + __le32 f0; > + unsigned char f1[4]; > + } crc; Odd indentation, are you sure this is right? Please indent the fields by one more tab. thanks, greg k-h