linux-staging.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: Phillip Potter <phil@philpotter.co.uk>
To: gregkh@linuxfoundation.org
Cc: Larry.Finger@lwfinger.net, dan.carpenter@oracle.com,
	linux-kernel@vger.kernel.org, linux-staging@lists.linux.dev
Subject: [PATCH 3/7] staging: rtl8188eu: remove unused variables from core/rtw_efuse.c
Date: Tue, 15 Jun 2021 23:36:03 +0100	[thread overview]
Message-ID: <20210615223607.13863-4-phil@philpotter.co.uk> (raw)
In-Reply-To: <20210615223607.13863-1-phil@philpotter.co.uk>

Remove set but unused variables from within the file core/rtw_efuse.c
in the function efuse_read_phymap_from_txpktbuf, as they are triggering
kernel test robot warnings. Also, remove the local 'lenc' array as well,
as nothing is done with its values. Keep the two usb_read8 calls
however, as this patch is purely for warnings, not to change behaviour
of the code.

Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Phillip Potter <phil@philpotter.co.uk>
---
 drivers/staging/rtl8188eu/core/rtw_efuse.c | 11 ++---------
 1 file changed, 2 insertions(+), 9 deletions(-)

diff --git a/drivers/staging/rtl8188eu/core/rtw_efuse.c b/drivers/staging/rtl8188eu/core/rtw_efuse.c
index 0d51bf9c9bb0..21619fd67217 100644
--- a/drivers/staging/rtl8188eu/core/rtw_efuse.c
+++ b/drivers/staging/rtl8188eu/core/rtw_efuse.c
@@ -234,16 +234,9 @@ static void efuse_read_phymap_from_txpktbuf(
 		hi32 = usb_read32(adapter, REG_PKTBUF_DBG_DATA_H);
 
 		if (i == 0) {
-			u8 lenc[2];
-			u16 lenbak, aaabak;
-			u16 aaa;
+			usb_read8(adapter, REG_PKTBUF_DBG_DATA_L);
+			usb_read8(adapter, REG_PKTBUF_DBG_DATA_L + 1);
 
-			lenc[0] = usb_read8(adapter, REG_PKTBUF_DBG_DATA_L);
-			lenc[1] = usb_read8(adapter, REG_PKTBUF_DBG_DATA_L + 1);
-
-			aaabak = le16_to_cpup((__le16 *)lenc);
-			lenbak = le16_to_cpu(*((__le16 *)lenc));
-			aaa = le16_to_cpup((__le16 *)&lo32);
 			len = le16_to_cpu(*((__le16 *)&lo32));
 
 			limit = min_t(u16, len - 2, limit);
-- 
2.30.2


  parent reply	other threads:[~2021-06-15 22:36 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-15 22:36 [PATCH 0/7] Fixup unused variables and warnings Phillip Potter
2021-06-15 22:36 ` [PATCH 1/7] staging: rtl8188eu: remove empty label from mlmeext_joinbss_event_callback Phillip Potter
2021-06-15 22:36 ` [PATCH 2/7] staging: rtl8188eu: use prefix decrement operator on trycnt variable Phillip Potter
2021-06-15 22:36 ` Phillip Potter [this message]
2021-06-15 22:36 ` [PATCH 4/7] staging: rtl8188eu: remove unused variables from core/rtw_mlme_ext.c Phillip Potter
2021-06-15 22:36 ` [PATCH 5/7] staging: rtl8188eu: remove unused variable from os_dep/ioctl_linux.c Phillip Potter
2021-06-15 22:36 ` [PATCH 6/7] staging: rtl8188eu: remove unused variables from hal/rtl8188e_cmd.c Phillip Potter
2021-06-15 22:36 ` [PATCH 7/7] staging: rtl8188eu: remove _dbg_dump_tx_info function Phillip Potter
2021-06-16  7:24 ` [PATCH 0/7] Fixup unused variables and warnings Greg KH
2021-06-16  7:58   ` Phillip Potter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210615223607.13863-4-phil@philpotter.co.uk \
    --to=phil@philpotter.co.uk \
    --cc=Larry.Finger@lwfinger.net \
    --cc=dan.carpenter@oracle.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-staging@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).