Received: by 2002:ab2:6816:0:b0:1f9:5764:f03e with SMTP id t22csp2835198lqo; Mon, 20 May 2024 20:22:42 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVV3wlZbWm1Ww2SZJq01RFjG4fuU+fPG9/I9iZjGVssrGnGGFsospDBdvlNfGXmwUV285cIO/ePB+0/+czvW6+XNPBT/EPIKePJR3U/qA== X-Google-Smtp-Source: AGHT+IFhjKRoHjuOdR1SrMr1g4d/8axX4St9ZsCXPEEtZWs7vEhj8ZR0YdRcB5C2CH00aGFRFK1h X-Received: by 2002:a05:6830:1058:b0:6f0:29cc:c545 with SMTP id 46e09a7af769-6f0e92f2329mr32047373a34.38.1716261762472; Mon, 20 May 2024 20:22:42 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716261762; cv=pass; d=google.com; s=arc-20160816; b=VcpdB6EiPflm32opaqty+bvX8+MWvtIcJ8pzoofgRSmV5LwDPHf+ScGILsLao9E2bJ wJCNUXtxnhFbVl641g5gYRMrI013ZfzH3Xz7aVM840YhN9zkxSvaqzmzVDh8H6kEDdH+ dT9dUTb6rOkJSLA/Tz5OIuRRl8Q9oPNKjiGg5l8HLoJRTRsrQjjlp5Hpi78hpi1MmkQB pc5eOlujCgsodt9gddiVAlUEwHus9K8NYk65ke/q7OMuk3eexaDh8KVkhYlHbYeNv5oq 9sc9H/u3iD67TnKMYIjN9inl9BoLpXqax9sdA3kAKGJX1MzoV0QYgMurXAmMS1ypHlu7 vkZA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=vIGSQ3C/BdvZT98agea7mQnapaDbDhw1o6G8ocniTTE=; fh=dCc+J33q9mBE7b8YFt46SERIsdUqQYKkom+nu1WYPZA=; b=j8wRbS2mPehanLg9Hgbc1mXTSdqXXK8Q3Lv8UFsHG+P7kbM0+3IkjR5C02kQLdLSXW /dr1BrM06f5j77ml0r9x4JnX+r2gA5jkc0biNj9ewO5TSWU0JjpB09bRP1jGnAAjqLfm qV91Vk4pdzo5TxGxNOhJcElu1EXnXSIk1kc+NLvuryck7ZMyUo9cUrmq4t1VP1FhHuJw g5p3anoOxKfjikTtPG0CnPoJaxfNVJWTb0jj/bPWcTvC33LZz39LBSwnANVfSCc578I/ 39lofp/LrF139o6RWzc07Dm5P2A4fEkMdMyEC+NImvQnN4eu9J4bs/F8FUAKGp7mUl28 SEGg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@darkphysics.net header.s=google header.b=JM+FM1Hu; arc=pass (i=1 spf=pass spfdomain=darkphysics.net dkim=pass dkdomain=darkphysics.net); spf=pass (google.com: domain of linux-kernel+bounces-184443-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-184443-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id 41be03b00d2f7-65c954451b0si3609343a12.199.2024.05.20.20.22.42 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 20 May 2024 20:22:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-184443-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@darkphysics.net header.s=google header.b=JM+FM1Hu; arc=pass (i=1 spf=pass spfdomain=darkphysics.net dkim=pass dkdomain=darkphysics.net); spf=pass (google.com: domain of linux-kernel+bounces-184443-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-184443-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 19250281D9F for ; Tue, 21 May 2024 03:22:42 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0DA7E745F0; Tue, 21 May 2024 03:17:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=darkphysics.net header.i=@darkphysics.net header.b="JM+FM1Hu" Received: from mail-pl1-f171.google.com (mail-pl1-f171.google.com [209.85.214.171]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AF2146D1B0 for ; Tue, 21 May 2024 03:17:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.171 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716261458; cv=none; b=S8SBRPIxRiB887cse14gQRK3OXTzHOn7TyM28MVwlsOtFC2p1cF7ATeCF1TnTImP8/AXLDoWf04j56U3NmnRxr54mhg9nsGOmWqXWUDX4zjiQ8RAhdBrXf7hXqHCJvwKLmbYUpODcjqj9A3LSAB1uVnBrHWn65Hl72jDLzE9/zw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716261458; c=relaxed/simple; bh=vOlhyRJiwMlcqMkjgh8ZqeWXUxY6D61pDutdGqwl5CY=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=t6wo2FzmGAexU3ITN9h1vzomREA5Ofjcx2iH/c97AIBwD/p74ZF3lbwlMuyrLnP8QN5CjhpMAgGk4FHo61VO7ej7lcztOVojgSEX4MKYR+r0Sk0q9l+hJ7P5cCM9/0YuqoDwshjERZaM/6tE6Wy4lh1K84LsJkBcoZs25e8rMz8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=darkphysics.net; spf=pass smtp.mailfrom=darkphysics.net; dkim=pass (2048-bit key) header.d=darkphysics.net header.i=@darkphysics.net header.b=JM+FM1Hu; arc=none smtp.client-ip=209.85.214.171 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=darkphysics.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=darkphysics.net Received: by mail-pl1-f171.google.com with SMTP id d9443c01a7336-1edc696df2bso30589315ad.0 for ; Mon, 20 May 2024 20:17:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=darkphysics.net; s=google; t=1716261456; x=1716866256; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=vIGSQ3C/BdvZT98agea7mQnapaDbDhw1o6G8ocniTTE=; b=JM+FM1HukvOhiVVfpaBzpqrpMhTCy2bh0Monq8xoWuWFx4DKq63gr9YXu3yGvYvMLU 3T228LHr/qwuHJdfYP3LPd9RpUyaht/PPXDwDRKPoXKE1gE8q/Fh5SWkGXqan7gf352F KSdYIINB5MAqiotW1VDrmmyGyNYZ568/NsnNF8ubFV1SAW72fkBWvtJowp3XQ7Iq6hYL dEasRh2wl+SPNc/mkYnmJdn8b5EaDFu5sUu7vZaq7fP9cSpRbiOJAh/LwPHTHfXF9uAE Ym321F2b0mmNVlhfUbwZlEyjDhqpuAskfxUqpZrKp2Gs34n5WpkMXi+4yltMR9YpxV1O aWFQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716261456; x=1716866256; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=vIGSQ3C/BdvZT98agea7mQnapaDbDhw1o6G8ocniTTE=; b=Xj072Ch0W3+sEdG2J+lu0f/nUdl3Xwp9fn7YzRFU10ykOsy5y+9BoMq183YnbgRL4b ZnnJRbNsFcDCUOuYGN2AjP4M8YeXTJdEMToRcKotoYKom5sqVNzXkAGmCiaK+uNtWpx0 VECDg9ehA0lOy3EoN4vHzIdrt6MleayOtg/vuBklXLo9UM/MXjulmqjjlU9xqkTFkCcE CfuqKacX3iTAXBO1yWe1AtzXQWuxmMiYjyh7JWkBljYBam24d1qaeeWM1x0EzBlqs/SC cShs5BdmBX/n5sht/3tsxh6kfkFJyBfBmNP0nsLONB3roCAQDIHoDI9KqdAfmVTU0u+c nCAQ== X-Forwarded-Encrypted: i=1; AJvYcCVw1Jc3TufMdI6LdI6He8KJoRKy/7+uVyBLxMfuwpGVibIEDQGekpJN2IjmLbQhpJBQJUdgaJV6VK/odTEI6z84tse20oxHENJu7XHa X-Gm-Message-State: AOJu0YyJ5AQT6g68dVB1Axvqveh8HliCOJY8/zja5OA7xTEENQScXF7A t9HIqIXGRIV5vn0bjuIRu3zMzodgwoVoMlHLBbHHdfv24vagr4bCfOwc+BtqBfletoCPZq4yPOb 5 X-Received: by 2002:a17:902:6b82:b0:1e3:dfdc:6972 with SMTP id d9443c01a7336-1ef43d15755mr316580525ad.9.1716261456179; Mon, 20 May 2024 20:17:36 -0700 (PDT) Received: from lunchbox.darkphysics (c-76-146-178-2.hsd1.wa.comcast.net. [76.146.178.2]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1ef0bf31a93sm214885415ad.134.2024.05.20.20.17.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 20 May 2024 20:17:35 -0700 (PDT) From: Tree Davies To: gregkh@linuxfoundation.org, philipp.g.hortmann@gmail.com Cc: dan.carpenter@linaro.org, linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, Tree Davies Subject: [PATCH v2 19/31] Staging: rtl8192e: Remove variable ChkLength Date: Mon, 20 May 2024 20:17:06 -0700 Message-Id: <20240521031718.17852-20-tdavies@darkphysics.net> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20240521031718.17852-1-tdavies@darkphysics.net> References: <20240521031718.17852-1-tdavies@darkphysics.net> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Remove variable ChkLength which fixes warning Avoid CamelCase, and use llc_offset in its place. Signed-off-by: Tree Davies --- v2: Delete ChkLength, and use llc_offset instead. drivers/staging/rtl8192e/rtllib_rx.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/staging/rtl8192e/rtllib_rx.c b/drivers/staging/rtl8192e/rtllib_rx.c index 52fbbbaf30b0..3a637731506c 100644 --- a/drivers/staging/rtl8192e/rtllib_rx.c +++ b/drivers/staging/rtl8192e/rtllib_rx.c @@ -729,7 +729,6 @@ static u8 parse_subframe(struct rtllib_device *ieee, struct sk_buff *skb, u16 fc = le16_to_cpu(hdr->frame_control); u16 llc_offset = sizeof(struct ieee80211_hdr_3addr); - u16 ChkLength; bool is_aggregate_frame = false; u16 nSubframe_Length; u8 pad_len = 0; @@ -746,9 +745,7 @@ static u8 parse_subframe(struct rtllib_device *ieee, struct sk_buff *skb, if (rx_stats->contain_htc) llc_offset += sHTCLng; - ChkLength = llc_offset; - - if (skb->len <= ChkLength) + if (skb->len <= llc_offset) return 0; skb_pull(skb, llc_offset); -- 2.30.2