From nobody Wed Dec 17 10:19:51 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 51328C77B72 for ; Thu, 20 Apr 2023 13:38:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231370AbjDTNif (ORCPT ); Thu, 20 Apr 2023 09:38:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44630 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231311AbjDTNi2 (ORCPT ); Thu, 20 Apr 2023 09:38:28 -0400 X-Greylist: delayed 341 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Thu, 20 Apr 2023 06:38:19 PDT Received: from out-57.mta0.migadu.com (out-57.mta0.migadu.com [IPv6:2001:41d0:1004:224b::39]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5DF065245 for ; Thu, 20 Apr 2023 06:38:19 -0700 (PDT) X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tinyglitch.net; s=key1; t=1681997555; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=HYPasswPNjthbHxXzPBv9mP61cdgKG5LEiRivNJjVRE=; b=eKwD+AJhzVcAHvYj2LhRyrUZiTSixI4oin8FrxXXrGk0ItAiIJshOXQzdZ+Y23HJihlo/7 ecw9FNuNA1DohnTsNJK4e0c15mb57Mg/aUwlovfSzIq2i/Yl6NNh00wcTThcPmxIo766hO dPWhMJdxQvmYFT3/EmYnVvGJ1MZ87Q8IJLaPBX8YAyFLSaRcQBXFV5uqtBxDOqq8L9fL9o M62GOw0I2kRBIRDhBqSfJQVEcAfAeVcBTjhZAy/a4g5UV8X10RccubpKed/uIH8fjUruLK K1vHoppMKF5HM6uTUx83lip+OFHnZOpUdu+iVoYZOovz4IGbXqaE9fcEnOjIKA== From: Stephan Snyman To: gregkh@linuxfoundation.org Cc: philipp.g.hortmann@gmail.com, kamrankhadijadj@gmail.com, linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, Stephan Snyman Subject: [PATCH] staging: rtl8192e: add missing braces {} Date: Thu, 20 Apr 2023 15:32:09 +0200 Message-Id: <20230420133209.4661-1-rooiratel@tinyglitch.net> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Migadu-Flow: FLOW_OUT Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Add missing braces to if/else statements to adhere to the Linux kernel coding-style guidelines. These issues were reported by checkpatch.pl "CHECK: braces {} should be used on all arms of this statement" Signed-off-by: Stephan Snyman Tested-by: Philipp Hortmann --- drivers/staging/rtl8192e/rtllib_rx.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/drivers/staging/rtl8192e/rtllib_rx.c b/drivers/staging/rtl8192= e/rtllib_rx.c index b649d02dc5c8..d44bf261de54 100644 --- a/drivers/staging/rtl8192e/rtllib_rx.c +++ b/drivers/staging/rtl8192e/rtllib_rx.c @@ -264,8 +264,9 @@ static int rtllib_is_eapol_frame(struct rtllib_device *= ieee, RTLLIB_FCTL_FROMDS && memcmp(hdr->addr1, dev->dev_addr, ETH_ALEN) =3D=3D 0) { /* FromDS frame with own addr as DA */ - } else + } else { return 0; + } =20 if (skb->len < 24 + 8) return 0; @@ -433,8 +434,9 @@ static int is_duplicate_packet(struct rtllib_device *ie= ee, if (*last_frag + 1 !=3D frag) /* out-of-order fragment */ goto drop; - } else + } else { *last_seq =3D seq; + } =20 *last_frag =3D frag; *last_time =3D jiffies; @@ -2314,8 +2316,9 @@ static inline int rtllib_network_init( if (stats->freq =3D=3D RTLLIB_52GHZ_BAND) { /* for A band (No DS info) */ network->channel =3D stats->received_channel; - } else + } else { network->flags |=3D NETWORK_HAS_CCK; + } =20 network->wpa_ie_len =3D 0; network->rsn_ie_len =3D 0; @@ -2329,9 +2332,10 @@ static inline int rtllib_network_init( return 1; =20 network->mode =3D 0; - if (stats->freq =3D=3D RTLLIB_52GHZ_BAND) + + if (stats->freq =3D=3D RTLLIB_52GHZ_BAND) { network->mode =3D IEEE_A; - else { + } else { if (network->flags & NETWORK_HAS_OFDM) network->mode |=3D IEEE_G; if (network->flags & NETWORK_HAS_CCK) --=20 2.40.0