From patchwork Sat Nov 18 08:51:25 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philipp Hortmann X-Patchwork-Id: 166473 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9910:0:b0:403:3b70:6f57 with SMTP id i16csp1064804vqn; Sat, 18 Nov 2023 00:52:21 -0800 (PST) X-Google-Smtp-Source: AGHT+IGyOQskUYmK4rI1J9xO5b+h01KWhvN2n4uW7gOgKOdB/E7oDwmz/viYeTWy/c8rV1qIHFJC X-Received: by 2002:a17:90b:3a87:b0:27c:f48e:e245 with SMTP id om7-20020a17090b3a8700b0027cf48ee245mr1854785pjb.24.1700297541630; Sat, 18 Nov 2023 00:52:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700297541; cv=none; d=google.com; s=arc-20160816; b=DJRVA5D3IuGo5OMLbUBD/Wfl2YVX9yB/UWZYzv+TYRD/dWrNMxDb4dTOs+g3cR2DN+ uLe/qLOmwW573p32NBQ3UxPbHo23pbUKU7+NKmcxkDPIWUeoUi3QlSptxP21jvKzjxT1 XO4Q0M2/IM96vQNPOQHiO9M7UpqcSUe2TGR0CjGtY5ozoUn8+HANfyxnR5VBVZlNoRMf avCsLLqd3CC+3yzFa/LI8d5mAzlZI2R4Ctbe2pxZ3WZPxPotKoDI/K9WWvaNbL/c75XC uTGV1Td8/AtlpMRSWaMDV68xFvdI6oBwAetRbV3t3wNCe75czJCiBGd5gXDVFDy7Dxu2 UJ6w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:to:from:date:dkim-signature; bh=vMytCypAKR6h1wsB0OQEQ+cFMOVYMGL6IbHLXc4UGuE=; fh=Sw1rtAM+hKyOoOQVYiiLzcdjc4spg79Z/tN6UmWUAKs=; b=bimxv1gC5Gbwu9bZ0RHs3ovn9TGv/bQcUAXIPC4BTcyehvlhFT/GyEL3P+p3H53k1T mgvebXM37id+8Ut2Sq6JqQiZyzcWZ+FePPGJmiMw7+UGeLE/gsWOYLN4xI4E+BNoA7tV EcF5aW7DVdjVB+y8+SE8e7bZ2Tzjkn1eyDGDkyIpMT1s/WW5dYNVRl7V4ZVOZH73GhdI kmJacxDPn87TV6ZNh50qRZkAHi73yP4SBR6Ysu5fW+mmN05UpKEhhv5YMyzmOg02XVsx fmYGykk9W6oSMEkWbc9+l8pnr798VacWLAF6XVUOL/GS9T1GvNtx183tJCJa9VEldwgb QkZw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=QOp7DghV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from agentk.vger.email (agentk.vger.email. [23.128.96.32]) by mx.google.com with ESMTPS id ob14-20020a17090b390e00b00283a0cb5b9bsi2304979pjb.58.2023.11.18.00.52.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Nov 2023 00:52:21 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) client-ip=23.128.96.32; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=QOp7DghV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id 9E3ED821C5C4; Sat, 18 Nov 2023 00:52:17 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233067AbjKRIvm (ORCPT + 29 others); Sat, 18 Nov 2023 03:51:42 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39994 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232967AbjKRIve (ORCPT ); Sat, 18 Nov 2023 03:51:34 -0500 Received: from mail-ej1-x630.google.com (mail-ej1-x630.google.com [IPv6:2a00:1450:4864:20::630]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F0F5D1725 for ; Sat, 18 Nov 2023 00:51:28 -0800 (PST) Received: by mail-ej1-x630.google.com with SMTP id a640c23a62f3a-9e28215db77so83283666b.1 for ; Sat, 18 Nov 2023 00:51:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700297487; x=1700902287; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=vMytCypAKR6h1wsB0OQEQ+cFMOVYMGL6IbHLXc4UGuE=; b=QOp7DghVXLTjC7R4yi8ZRl2+m7Ks6D7zvTmqscPCGjqJoimRC7hISTveXUzivvDWIi PaZLyrvkdS5+vDv3MoHQm4XiJ5Rwn2UOaGY8f41CxZ/5GdKwNn+2aCE1cd85HBkqR/iT FFL+I+N/xllw4a/t9pp6ovuyzQCNq4m7dRS6CJkSb4eItyUHEkMH0GeH3fSS88G/Vy47 skFZzevMIe/TCQMLZiFKkcG/4MNh9ZIpELJwcl++9NE+e6ht61Kxc1AfQSUCuPOYaAsf EKNus/6XYnn0wdwN3iGU0JTVj5Mmyam2ROXBExECcQEoV9TDz16PGAc372SNJfdJBTOv fbjw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700297487; x=1700902287; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=vMytCypAKR6h1wsB0OQEQ+cFMOVYMGL6IbHLXc4UGuE=; b=RYS2Sjj4qcAH31bxdsUuI5P0AiRlJr3AHEJRiFQb5Tewix1Th22dUb65DlDSI+eU/o zU/WV6783jYgv4jMrtgwKit2vkzpaPcpY5uVAJY7b8Jr1PukO6G5JVaKyseYSWqD5iu4 0lr6xhlIbW37gLNY47VsN/rT40bKCZl9NLvti3NBiLHyyrT45MmsJL3iXwwSx67YXQ2H xndPHu+l5GN5EqnvJ6gKwW3THFzlDak43IicDkvOpXcmutUV/QMRcwB4lmYDk6fs0wr1 8FW/vnJy64EZrgOGTbdcfVtOrqEZjsViGOZJ4mdrJKClkgAhrNPFhBpSi7aOYzPb4gFA JsWQ== X-Gm-Message-State: AOJu0Ywf0s44QEw6blaEFHcDUOkOroI319Rdu+l5YPOo4ESUCpMLWntf R+AN3ndT5t4HJ84s9ETGPOU= X-Received: by 2002:a17:906:10cf:b0:9e6:dfee:8154 with SMTP id v15-20020a17090610cf00b009e6dfee8154mr1036711ejv.3.1700297487250; Sat, 18 Nov 2023 00:51:27 -0800 (PST) Received: from matrix-ESPRIMO-P710 (p57ba2f20.dip0.t-ipconnect.de. [87.186.47.32]) by smtp.gmail.com with ESMTPSA id jz12-20020a170906bb0c00b00988f168811bsm1675679ejb.135.2023.11.18.00.51.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Nov 2023 00:51:27 -0800 (PST) Date: Sat, 18 Nov 2023 09:51:25 +0100 From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH 04/10] staging: rtl8192e: Remove equation that results in constant for chnl_plan Message-ID: References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Sat, 18 Nov 2023 00:52:17 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1782891194880247920 X-GMAIL-MSGID: 1782891194880247920 Remove equation for chnl_plan as the last line sets chnl_plan to a constant. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c index e93394c51264..44898e0be21c 100644 --- a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c +++ b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c @@ -387,23 +387,15 @@ static void _rtl92e_read_eeprom_info(struct net_device *dev) rtl92e_init_adaptive_rate(dev); - priv->chnl_plan = priv->eeprom_chnl_plan; - switch (priv->eeprom_customer_id) { case EEPROM_CID_NetCore: priv->customer_id = RT_CID_819X_NETCORE; break; case EEPROM_CID_TOSHIBA: priv->customer_id = RT_CID_TOSHIBA; - if (priv->eeprom_chnl_plan & 0x80) - priv->chnl_plan = priv->eeprom_chnl_plan & 0x7f; - else - priv->chnl_plan = 0x0; break; } - if (priv->chnl_plan > CHANNEL_PLAN_LEN - 1) - priv->chnl_plan = 0; priv->chnl_plan = COUNTRY_CODE_WORLD_WIDE_13; if (priv->eeprom_vid == 0x1186 && priv->eeprom_did == 0x3304)