aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging
diff options
context:
space:
mode:
authorMichael Straube <straube.linux@gmail.com>2024-02-01 09:18:24 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2024-02-17 17:28:56 +0100
commit72c068a1c71ffac8d522ad50beda775b45cd5953 (patch)
tree7db31e5f694203f92ab8b8bfee4a75a778a8f7fe /drivers/staging
parent2025908b8e3ab4318295c3dfc4c2781157a266f0 (diff)
downloadlinux-72c068a1c71ffac8d522ad50beda775b45cd5953.tar.gz
staging: rtl8192e: initialize variables at declaration
Initialize two variables at declaration instead of first declare and then initialize them. This saves a line of code and clears a checkpatch warning. WARNING: Missing a blank line after declarations Signed-off-by: Michael Straube <straube.linux@gmail.com> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/20240201081824.6998-4-straube.linux@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r--drivers/staging/rtl8192e/rtllib_rx.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/staging/rtl8192e/rtllib_rx.c b/drivers/staging/rtl8192e/rtllib_rx.c
index e6be6dbe2bb5b..29bdaff4cbab9 100644
--- a/drivers/staging/rtl8192e/rtllib_rx.c
+++ b/drivers/staging/rtl8192e/rtllib_rx.c
@@ -943,10 +943,9 @@ static void rtllib_rx_extract_addr(struct rtllib_device *ieee,
static int rtllib_rx_data_filter(struct rtllib_device *ieee, struct ieee80211_hdr *hdr,
u8 *dst, u8 *src, u8 *bssid, u8 *addr2)
{
- u8 type, stype;
u16 fc = le16_to_cpu(hdr->frame_control);
- type = WLAN_FC_GET_TYPE(fc);
- stype = WLAN_FC_GET_STYPE(fc);
+ u8 type = WLAN_FC_GET_TYPE(fc);
+ u8 stype = WLAN_FC_GET_STYPE(fc);
/* Filter frames from different BSS */
if (ieee80211_has_a4(hdr->frame_control) &&