From patchwork Sun Apr 2 09:51:42 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philipp Hortmann X-Patchwork-Id: 78213 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1657366vqo; Sun, 2 Apr 2023 02:53:01 -0700 (PDT) X-Google-Smtp-Source: AKy350ZN7ziIf5hNVnW41Zu388rSO5Jl4ijYERWVqI5UZ6s0iorrSw3JGVaMHDPryHkD+yxJeyHl X-Received: by 2002:a17:902:f34d:b0:1a1:eda9:6739 with SMTP id q13-20020a170902f34d00b001a1eda96739mr27136800ple.41.1680429180788; Sun, 02 Apr 2023 02:53:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680429180; cv=none; d=google.com; s=arc-20160816; b=UrHZTzFhFNUaoxhPPZ2Ix81T8e4vswVeDJy1B0lO0zKP3hS5Spa07D47dae4oWUtLO 0a87+oLBGkuDNg1Lg1DhVjvAKBUNHcglyJSHOx5dlJoO8Q/ERBdGveqZsPf6i66V3gFg 5IpTWlshFWsJWlIhR7RKgKvTD8SGacwmsuIrGyRl/BLk43RUUiWXMuFsKA4ty1D6HYwE hwR39Z1vxJKGsBs53LwBtIZsFyVO0F3zU77x/205+zZJYhpZFPx4s5gDk7xT7wMvgSMZ pLbYCQpiiZhf7aSxcHvmSXeTyDpi6V8sQ88+ER7qLxh/M0jhlKkokSaMOXtdhccQfbud PxOQ== 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=VaeBDPkSiTEyNdN0rUscDp5HyS5CgrVs8mEE78XtpGY=; b=xJyfaO7wpzp24Wz7EZlLknJebrqlV4TBZFJd3bowfBONA6b+l/0+60sauffvQP/LIN +QCftWyPwIWJfMuVCEKMvnyYdQ2B6lMhVrrBjJ0RkJVCwuBcjObotQu7BsfQx6qcijee 0amPn7TYs+vSWYIAX/BaJ55pkEjK3yeqAStoUUnQxOxy1Q1IGINXh/Owk9G+GLwuZOFB mQH7pyM+/BCflwnt7N1slyWaRFUMteFjVA0nWb1xt7BaoURJwHS351LCtxn+K9KV0rla iULjbbdnM6YjUNnvZFxjJRzyYayahuP4K7p1+9+3PvrjfgAEdO8Z9oVhii/lIn9FLaNS Rh/Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=m11NQ93M; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id kb14-20020a170903338e00b001a1c5d7f9a5si5644636plb.14.2023.04.02.02.52.49; Sun, 02 Apr 2023 02:53:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=m11NQ93M; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229945AbjDBJwU (ORCPT + 99 others); Sun, 2 Apr 2023 05:52:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49748 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230377AbjDBJwK (ORCPT ); Sun, 2 Apr 2023 05:52:10 -0400 Received: from mail-ed1-x536.google.com (mail-ed1-x536.google.com [IPv6:2a00:1450:4864:20::536]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7972C2C9FA for ; Sun, 2 Apr 2023 02:51:48 -0700 (PDT) Received: by mail-ed1-x536.google.com with SMTP id w9so106293379edc.3 for ; Sun, 02 Apr 2023 02:51:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1680429104; x=1683021104; 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=VaeBDPkSiTEyNdN0rUscDp5HyS5CgrVs8mEE78XtpGY=; b=m11NQ93My1CKSjCNRpFIoKODHOqd0MpOWOR7t4H6N1NO7dt1q4UiU98zUOXEi9iCwA awQ6J4BXGgVAEfH7b4sYbC10/RVwMeTSjRM5JdG7gpxSYC4ZxxBMZSee5HKAG47mca17 ltIG5/7kpiUHLHtiHXA2qNUEQ8cP6clXZM8we4dH5rG3dYJIl0hhS3EJeQPObh/M24Mh BTbITuCR0msP4rZ1Z/4LU479HmI+BC+U45/0A08gsx0zOEtDAzI9OwJRs+Lndmw7uazh D9N+HPMlkPqf19ornTNxVJExAjHKwpl+20TGPYEESHRtFCaw6BKEDM22rsF2GOrVdchl M1Fg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1680429104; x=1683021104; 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=VaeBDPkSiTEyNdN0rUscDp5HyS5CgrVs8mEE78XtpGY=; b=O4webkITj6FfTwQvVmx+9iq5aDgyL1z6+Ca6QJ3NsJDRI1qlZVFCgi8zu5Q2jQ/6sc SY+r1zbbTgWzjiwPo20navyrHxIIPct1oi6dm5Ol9HDT6xOJVQ/mNH7DF6AJCHnrr6Ym YQxjrvIPNvO1+/6kZax/dg8SnIeFfw0TMULSQsyWYvVhQBTnZuFD9X2/0DdV9H0i7411 7e6B8T4Cj7Ea7QFUzN+DmEgll0276gnfnLJjr+HEQRJlaURicnJopTyyVR743Doz/4Ld Fs2jQcwclmk8pLVfsWpM6LsTL6ipGKQ+6Y0m/HPabJTcwtDfDSlDDJs39FIJ73pOcA3C Ht9Q== X-Gm-Message-State: AAQBX9e74pQh367ONjsT093ZyLSRuJZ39QCeigY0KUneTLRmTgeYNtPI urvbCJlD7SzanrgqRYWDiQs4CgocYbk= X-Received: by 2002:a17:906:2098:b0:8d2:78c5:1d4e with SMTP id 24-20020a170906209800b008d278c51d4emr9637967ejq.5.1680429104567; Sun, 02 Apr 2023 02:51:44 -0700 (PDT) Received: from matrix-ESPRIMO-P710 (p57935146.dip0.t-ipconnect.de. [87.147.81.70]) by smtp.gmail.com with ESMTPSA id gl25-20020a170906e0d900b00929fc8d264dsm3103867ejb.17.2023.04.02.02.51.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Apr 2023 02:51:44 -0700 (PDT) Date: Sun, 2 Apr 2023 11:51:42 +0200 From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH v2 1/6] staging: rtl8192e: Remove RF_Type from .._dm_tx_update_tssi_weak_signal Message-ID: <95744a9d271723b44b92465809d092f90edf9bc9.1680427945.git.philipp.g.hortmann@gmail.com> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762057708306900775?= X-GMAIL-MSGID: =?utf-8?q?1762057708306900775?= Remove RF_Type from _rtl92e_dm_tx_update_tssi_weak_signal and _rtl92e_dm_tx_update_tssi_strong_signal as it is unused. Reported-by: kernel test robot Signed-off-by: Philipp Hortmann --- V1->V2: This patch did not exist before and was added because RF_Type was used here but left uninitialized by later patches. --- drivers/staging/rtl8192e/rtl8192e/rtl_dm.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c index b5f4d0230da7..258ea66ab2fd 100644 --- a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c +++ b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c @@ -475,8 +475,7 @@ static u8 CCKSwingTable_Ch14[CCK_TABLE_LEN][8] = { #define Tssi_Report_Value2 0x13e #define FW_Busy_Flag 0x13f -static void _rtl92e_dm_tx_update_tssi_weak_signal(struct net_device *dev, - u8 RF_Type) +static void _rtl92e_dm_tx_update_tssi_weak_signal(struct net_device *dev) { struct r8192_priv *p = rtllib_priv(dev); @@ -495,8 +494,7 @@ static void _rtl92e_dm_tx_update_tssi_weak_signal(struct net_device *dev, } } -static void _rtl92e_dm_tx_update_tssi_strong_signal(struct net_device *dev, - u8 RF_Type) +static void _rtl92e_dm_tx_update_tssi_strong_signal(struct net_device *dev) { struct r8192_priv *p = rtllib_priv(dev); @@ -610,10 +608,9 @@ static void _rtl92e_dm_tx_power_tracking_callback_tssi(struct net_device *dev) return; } if (Avg_TSSI_Meas_from_driver < tssi_13dBm - E_FOR_TX_POWER_TRACK) - _rtl92e_dm_tx_update_tssi_weak_signal(dev, - RF_Type); + _rtl92e_dm_tx_update_tssi_weak_signal(dev); else - _rtl92e_dm_tx_update_tssi_strong_signal(dev, RF_Type); + _rtl92e_dm_tx_update_tssi_strong_signal(dev); priv->cck_present_attn_diff = priv->rfa_txpowertrackingindex_real - priv->rfa_txpowertracking_default; From patchwork Sun Apr 2 09:51:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philipp Hortmann X-Patchwork-Id: 78219 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1662661vqo; Sun, 2 Apr 2023 03:08:07 -0700 (PDT) X-Google-Smtp-Source: AKy350YlzY5Nd53pFsKV2e8fpcDNfII/7hggpq6PaiwaohLWFvJYbTZ2QIua75K3kyzxWxV2YCTv X-Received: by 2002:a17:90b:1647:b0:236:73d5:82cf with SMTP id il7-20020a17090b164700b0023673d582cfmr37509951pjb.9.1680430087452; Sun, 02 Apr 2023 03:08:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680430087; cv=none; d=google.com; s=arc-20160816; b=B7Dvh4MC3sw7HfaherO7OBkrXirV4WzTX9vmp9Y0J/xgkOeSJxYjRskZtBziwnhKUO 1qLOVPAlDy8DQrrBPsSaCROZ6omUbMH9upciJ2Pbbg4u7OgoF5Q/3W6bfZpauPgfqEhB IafvCJ0bjSAcR5mMwWtN3nC4uKQKz/2duXxn2o5NC4ypN+VD2Ca7FEci4nWbWvcssLXf h2Zr5N13GbFfesnBed0v48B4tLT23XPSAtUh6rP0MwefaYNtse7veZ4gCocdsVGxLq/F yqfsR1rzglh+rd4Las8oySZIIL+8rZ4zTaDUUbZc3faS6K0kpty62kJKbZFJy2W2YPBu 28yQ== 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=KhiswCrusaKP4BJlZZJCPIbuTKVOmwuOxikLoZ9ebT0=; b=OPGlSAEORtYJE8uGCxSxlAExe3vLCil1sKQAfTYM9l7PaXQkf8ad4XcP/k1aJGhF37 b0j3/Z3wKrU7q6PhLRDm5J037zziy4J7gNC4BmOJVwlfzlRbOsBUBnO7nohEAPpOw5Yl FuYMSDiwD8Ng0IXYprgOqEPAmBk+NDqZAMWPUR+MLvFcF3aajv9JrPaXuzXrUUUdFUDJ 1r0kha2e4pic0bogJ+FnT+RO4Au8hz9BnIDMNDHWwXNFWbVEwmYIDjA7yPCGMuk3QUXh C/1EFfX0ATPCNaQaaZBBOOBWU1Bxi95Sw9kLL2WQyORAhJmnHb5zK7ii6L9184PZAxl0 9PPw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b="pAE7/h5V"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id p23-20020a17090b011700b00233cf4bbd67si5828682pjz.188.2023.04.02.03.07.48; Sun, 02 Apr 2023 03:08:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b="pAE7/h5V"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230343AbjDBJw1 (ORCPT + 99 others); Sun, 2 Apr 2023 05:52:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49292 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230381AbjDBJwQ (ORCPT ); Sun, 2 Apr 2023 05:52:16 -0400 Received: from mail-ed1-x52e.google.com (mail-ed1-x52e.google.com [IPv6:2a00:1450:4864:20::52e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7751C6194 for ; Sun, 2 Apr 2023 02:51:52 -0700 (PDT) Received: by mail-ed1-x52e.google.com with SMTP id w9so106294995edc.3 for ; Sun, 02 Apr 2023 02:51:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1680429110; x=1683021110; 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=KhiswCrusaKP4BJlZZJCPIbuTKVOmwuOxikLoZ9ebT0=; b=pAE7/h5VEeQ5yCr9LFJXyKFTAjLmOFfZTgw2MbmHa/BqqOSJ/flZdLHPdhivywjXaD fQvvJTywVJ3bv35d9VVrrYKrSc3OGhbaUb7j5r5UnYJukiB6vKNxrcmhR33FQAbm0iRU CihNxtBKhjVxHPN4jBCEgC5aIszRgj3kzAxKyeaY9r741RcWqCM6CRepPB1maZ14khB6 xIKGivfX2Cza9Zh0Abg3QtByp9AtrT/h8Gl4sfA6M2Ktoe2LCbvcvYCo/7XR2TYGHcu7 z8x8ZFa4E3I8ScwtRYe9DDA75xcDTmJrXJotnONyGso/2uiqVoJb1Fq/Dew7KlOLXNIv +Tag== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1680429110; x=1683021110; 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=KhiswCrusaKP4BJlZZJCPIbuTKVOmwuOxikLoZ9ebT0=; b=1J3yLY7+NTKyva/EAsTWl8wa8Ak8WrzHUYivVQSfQJ510kqZsMQ7wcJNn+PlKXmfnI DOWaSguqoHdHOpGe6XOAOnMwcbKgu3weYFjnb8/u+O7JjXmTwKf37OzT+kZ+hFiU42UQ p3/WizpoHTitA9uVrgRLfWkAZy6YTRns8M6J2JBruLswrqmh0fWjzkH/woEiNFymgDo5 7dL0ybjb0SvbG6KSJhBVcX8oYUFFqEryOnV0eva8/7ecmL5roBKTZV2YFETZIMALuZYy mUYJXX7+KDQI+icZU3PPj7yqpwduzaXSjEXs9uTeHH1yqYuLb4tnstpbKg53f3FD54E7 Tv3w== X-Gm-Message-State: AAQBX9dGic1Bam9RQDEReTNTSlovynic1wKAG+LSv3vJDdXoHcW6r8SC f7x0YKubC7V5Dfxe/FPuXjMPr6/uVxQ= X-Received: by 2002:a17:906:49:b0:930:aa02:f9cf with SMTP id 9-20020a170906004900b00930aa02f9cfmr10039192ejg.2.1680429109889; Sun, 02 Apr 2023 02:51:49 -0700 (PDT) Received: from matrix-ESPRIMO-P710 (p57935146.dip0.t-ipconnect.de. [87.147.81.70]) by smtp.gmail.com with ESMTPSA id u25-20020a1709060b1900b0093e39b921c8sm3021008ejg.164.2023.04.02.02.51.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Apr 2023 02:51:49 -0700 (PDT) Date: Sun, 2 Apr 2023 11:51:47 +0200 From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH v2 2/6] staging: rtl8192e: Remove enum RF_1T2R and RF_Type Message-ID: <6c29e709f5c328703870ca8e7d61ee6338886fa7.1680427945.git.philipp.g.hortmann@gmail.com> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762058659493103403?= X-GMAIL-MSGID: =?utf-8?q?1762058659493103403?= enum RF_1T2R is used to initialize a local variable RF_Type that is then shifted. The result of the shift is zero. Remove code that has always the same result to increase readability. Signed-off-by: Philipp Hortmann --- V1->V2: Removed declaration of local variable --- drivers/staging/rtl8192e/rtl8192e/rtl_dm.c | 5 ++--- drivers/staging/rtl8192e/rtllib.h | 4 ---- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c index 258ea66ab2fd..a21b3798db48 100644 --- a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c +++ b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c @@ -518,7 +518,7 @@ static void _rtl92e_dm_tx_power_tracking_callback_tssi(struct net_device *dev) struct dcmd_txcmd tx_cmd; u8 powerlevelOFDM24G; int i = 0, j = 0, k = 0; - u8 RF_Type, tmp_report[5] = {0, 0, 0, 0, 0}; + u8 tmp_report[5] = {0, 0, 0, 0, 0}; u32 Value; u8 Pwr_Flag; u16 Avg_TSSI_Meas, tssi_13dBm, Avg_TSSI_Meas_from_driver = 0; @@ -529,8 +529,7 @@ static void _rtl92e_dm_tx_power_tracking_callback_tssi(struct net_device *dev) priv->rtllib->bdynamic_txpower_enable = false; powerlevelOFDM24G = priv->pwr_track >> 24; - RF_Type = RF_1T2R; - Value = (RF_Type<<8) | powerlevelOFDM24G; + Value = powerlevelOFDM24G; for (j = 0; j <= 30; j++) { diff --git a/drivers/staging/rtl8192e/rtllib.h b/drivers/staging/rtl8192e/rtllib.h index 197c0a44ebd6..7d83a4c322cf 100644 --- a/drivers/staging/rtl8192e/rtllib.h +++ b/drivers/staging/rtl8192e/rtllib.h @@ -433,10 +433,6 @@ enum led_ctl_mode { LED_CTL_START_TO_LINK = 8, }; -enum rt_rf_type_def { - RF_1T2R = 0, -}; - enum wireless_mode { WIRELESS_MODE_UNKNOWN = 0x00, WIRELESS_MODE_A = 0x01, From patchwork Sun Apr 2 09:51:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philipp Hortmann X-Patchwork-Id: 78216 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1658885vqo; Sun, 2 Apr 2023 02:59:16 -0700 (PDT) X-Google-Smtp-Source: AKy350YWm96zWFYZrIUGnLE5FFIbudM6s321O2ln0bmLQgkrlwZ5NH+DUPhb4thlTAyzNyl0rHWd X-Received: by 2002:a05:6a20:2d9e:b0:db:e054:826a with SMTP id bf30-20020a056a202d9e00b000dbe054826amr15964366pzb.5.1680429555882; Sun, 02 Apr 2023 02:59:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680429555; cv=none; d=google.com; s=arc-20160816; b=ZfjGuzj6jF9gDN2xbM7XA/3rmuncmi0rtm1TYbEd5Fnt1nuzzT9N//xWDPlEgHU2aW 7L59xGCUWurYhWuYI5gY6D75KNPK+8Ttxqq2i1mb1F7t/GIopddi+0dZJISNvOxexGDb K+62LDSfj3FTdUTbztjUGtfHYV1kU3LVMQUZ9g5fzGYGDtU/gaYHKb7dguAx3NelS4oy CjiHtd2cXXrhjdNHQRjZ4XkRXNgDM4+I0CwzzVHk/kb4sQXH/vau4U7EjSGvx2Hvh9QK EQ26rq6U+21Ay1TjH73rPUuHcOo9iRs16H26wGikBJa3rJ/JFZltVw2brq1kBRkN3bh8 NfBw== 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=8kLb8IQUT4+CAKzjeCA5AxiV6CvhrMng8FzIucyahWM=; b=WlX8sSF1WoaoFQmFnWnK7Mg/Z1imt5thjqAYeFGL/ZTHtuw1tj74mPvJjUPyu82Twl ZTh9bJUg9sum7TIuCT0MhDn/zx8AHIobtWZgT+AXdEKxHYNBZZ7mg4jefU5MZg5xDtfb Q4wSjyULUEYHwBU2BVY3dm8K31oxEoljUD2yF1g+QkE/VhNJlkW995LsNc+aBjHrk9VK Vh5m3dL1TZNHG+tVL6AlZE1sA8AjZT8/tMCXf8hC3qMi6g4v5CO0ZxzW1VgKjRfzBdxD m5L64dcxe7hCLPRC1Oqr8b+E5nqcM8Kcix6TCYyZCHgPjmNAj9JmWVVFRfAq4NIDxu+5 uAow== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=GmlE4ygR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h17-20020a63f911000000b0050c0c9d2931si6251683pgi.671.2023.04.02.02.59.03; Sun, 02 Apr 2023 02:59:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=GmlE4ygR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230436AbjDBJwe (ORCPT + 99 others); Sun, 2 Apr 2023 05:52:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51078 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230377AbjDBJwV (ORCPT ); Sun, 2 Apr 2023 05:52:21 -0400 Received: from mail-ej1-x629.google.com (mail-ej1-x629.google.com [IPv6:2a00:1450:4864:20::629]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4E4C65FF9 for ; Sun, 2 Apr 2023 02:51:58 -0700 (PDT) Received: by mail-ej1-x629.google.com with SMTP id a640c23a62f3a-930bc91df7bso77010666b.1 for ; Sun, 02 Apr 2023 02:51:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1680429116; x=1683021116; 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=8kLb8IQUT4+CAKzjeCA5AxiV6CvhrMng8FzIucyahWM=; b=GmlE4ygRZEOIOnMBg94rr+q76rKLFyj+RlkqpMsBHVrx0rPeQYQIs/dR0nyxdf/EAa AnUd8eYZLWB58oL5RYTQJTwWW21ZuqnxQmtSKTd7wQDtsnJAd6F7Go5sXXFiEpeNZc8v kjSUdQV2J4v+Ecvh3Q9CpHCopfvzw9SJ9xsqprSUS9fxKul+Sq20RaGrzmQYB+uHToHU ivPO38uZm4xVQEcwTKsKt7EpN8RVHfZPG313eoINCLtRz+BtbxBKS41hD3T025tRXnDG WUrzGZWr/s/1epGq3pnqHJ4+OFPs9Qi3YazOmzJuc/xxaEBZC5sIreYwbdZVAqaDBGo8 yvlw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1680429116; x=1683021116; 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=8kLb8IQUT4+CAKzjeCA5AxiV6CvhrMng8FzIucyahWM=; b=3/cZ+Blaau3IEH9ArgDGKepjlTLjUyn078JPZU6HyKpCQeoMFrPkTcG33h/BbzWoPN o2wsPh8nuBH8eTAwFkRZ5gAKuoZVpQ00v0fupAquXfvBKFiQQ6vxzQu4sG0B+EL2LY7N OH0vrhCg8wVKHtU5V8hzr5IveMAIK/rmHuju+WOlR45GNP3r8IJECygIDVpJOCxBgZi+ 6+A46Kpf8vrk1GBVXL+K4H34kPmzMgusNkaXpjAvh1fxrQZNzPz9IJtqEzEBsfa3sDNL 192Dx2XmZv9422NrXL7LQE/r6kN4XpIMXLc/+8OxvEaWPjzRWAiZJPOarSlorbmxOzIS pVvQ== X-Gm-Message-State: AAQBX9eRMVB4lgyWx5IxTml1ZGBfptQRdehr/Hw+RNPD81Wge4oLHfiy BzDfNZ1Aat4SOTNNs5A8UDzpnztsZPc= X-Received: by 2002:a17:906:2098:b0:930:7f40:c1bb with SMTP id 24-20020a170906209800b009307f40c1bbmr9702476ejq.4.1680429116281; Sun, 02 Apr 2023 02:51:56 -0700 (PDT) Received: from matrix-ESPRIMO-P710 (p57935146.dip0.t-ipconnect.de. [87.147.81.70]) by smtp.gmail.com with ESMTPSA id g17-20020a1709064e5100b009312cc428e4sm3026075ejw.165.2023.04.02.02.51.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Apr 2023 02:51:55 -0700 (PDT) Date: Sun, 2 Apr 2023 11:51:54 +0200 From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH v2 3/6] staging: rtl8192e: Remove local variable Value and powerlevelOFDM24G Message-ID: <2076dc2f8f5afc11cbab23bc3f5d4ace9bf33bfd.1680427945.git.philipp.g.hortmann@gmail.com> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762058101814424159?= X-GMAIL-MSGID: =?utf-8?q?1762058101814424159?= powerlevelOFDM24G is set to priv->pwr_track. Then Value is set to powerlevelOFDM24G and then only once used. Remove both variables to increase readability. Signed-off-by: Philipp Hortmann --- V1->V2: No changes just rebased --- drivers/staging/rtl8192e/rtl8192e/rtl_dm.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c index a21b3798db48..cde41111012a 100644 --- a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c +++ b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c @@ -516,10 +516,8 @@ static void _rtl92e_dm_tx_power_tracking_callback_tssi(struct net_device *dev) struct r8192_priv *priv = rtllib_priv(dev); bool viviflag = false; struct dcmd_txcmd tx_cmd; - u8 powerlevelOFDM24G; int i = 0, j = 0, k = 0; u8 tmp_report[5] = {0, 0, 0, 0, 0}; - u32 Value; u8 Pwr_Flag; u16 Avg_TSSI_Meas, tssi_13dBm, Avg_TSSI_Meas_from_driver = 0; u32 delta = 0; @@ -528,14 +526,11 @@ static void _rtl92e_dm_tx_power_tracking_callback_tssi(struct net_device *dev) rtl92e_writeb(dev, FW_Busy_Flag, 0); priv->rtllib->bdynamic_txpower_enable = false; - powerlevelOFDM24G = priv->pwr_track >> 24; - Value = powerlevelOFDM24G; - for (j = 0; j <= 30; j++) { tx_cmd.op = TXCMD_SET_TX_PWR_TRACKING; tx_cmd.length = 4; - tx_cmd.value = Value; + tx_cmd.value = priv->pwr_track >> 24; rtl92e_send_cmd_pkt(dev, DESC_PACKET_TYPE_NORMAL, (u8 *)&tx_cmd, sizeof(struct dcmd_txcmd)); mdelay(1); From patchwork Sun Apr 2 09:51:59 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philipp Hortmann X-Patchwork-Id: 78218 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1662096vqo; Sun, 2 Apr 2023 03:06:31 -0700 (PDT) X-Google-Smtp-Source: AKy350ZZdbJIUkXEHW3k6BRu8tZ2y4D03lYxdV6/oB/vJ8dtnXvcCCdyUr+9HtN2zMaOx33zMQJS X-Received: by 2002:a17:902:d48a:b0:19f:3617:e9e9 with SMTP id c10-20020a170902d48a00b0019f3617e9e9mr46518385plg.43.1680429990811; Sun, 02 Apr 2023 03:06:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680429990; cv=none; d=google.com; s=arc-20160816; b=eeX2/EOlIR13wd65SDjgS5L0xFLidq7tdseZMpcfJJ9UO1Wqbksc2smlSoDRhuIbmV 0OBhAj93SVkQwDBolYNoEGdw1vtPekPDhwlNafTSw1GGxCsnuAvvVhD6ogzMuqEqfhMm 8Ts3T9SLCuHxp9oZscToLQzv/AjtiHAVU8RmRDfQquPsAqpM7R92jINE/S9Wbeqz9ew7 L/DksW4gHKTD6+4mHoDtCZ2M21hClCXdHAU5F6A49RWMzXOOeGXlhHv00gF95VAzQoDN 7mmwAm9yIkDJqxFxQHAHgrAqKQBoveDxGaGrgBaO6pWUK82pdhJ98rW5ewof7a6YNNLt 6Fgg== 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=mPalzn3j45ikPjT3aRccNp7p7+9165ZTfapmFphFUHY=; b=MTqCol2fHePbdsbiRV/ttjW25x/OxOakmDJlKeo+4xITKB3jLf/EuBVISlLw3HcT5j fGUk78EBoNbuepbBCrSwxe/zxiTtpbnfDhfbzZ+4MlZKvHdnsRJ1TCETpQlvSoukL2vt IFpw8KFGQATAX7SmodaITcKqbW+uN3h2xJhppYtvEhSYblYl5x4IDu6c8jg9uI9xLNVN PuUJzYHvkgbSbU9XDeJF39HnMblsKt0eyUiL8tY18NDOhfzaeUaAErMYdaEszIYtP9es CfGszrostqdaLyBSZ5J3CsqcYZ9GTMIlOe/D9lt9O4fUl3IU8sxkh1/TndUk9Jc/cyxw XXAw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=M2LZmF84; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h3-20020a170902f54300b001a0442e0038si6607134plf.414.2023.04.02.03.06.19; Sun, 02 Apr 2023 03:06:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=M2LZmF84; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230405AbjDBJwj (ORCPT + 99 others); Sun, 2 Apr 2023 05:52:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51248 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230400AbjDBJwY (ORCPT ); Sun, 2 Apr 2023 05:52:24 -0400 Received: from mail-ed1-x536.google.com (mail-ed1-x536.google.com [IPv6:2a00:1450:4864:20::536]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C921E1BF79 for ; Sun, 2 Apr 2023 02:52:03 -0700 (PDT) Received: by mail-ed1-x536.google.com with SMTP id h8so106308324ede.8 for ; Sun, 02 Apr 2023 02:52:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1680429122; x=1683021122; 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=mPalzn3j45ikPjT3aRccNp7p7+9165ZTfapmFphFUHY=; b=M2LZmF84K5PaWvGfhAd9RAgX8+pIOyPa5ZkoljoOxi+fNNAY+EN8e0kUQURdXqHeac rq37xn/t+Or7SwfBy+V/pHdnd5dhf0FzpSFM/lF+cogNljTsD+ySns69JJtnBuZFvmY/ l1Z8CSrtYLteFt9YZZvVaxku6dECKL/iGnxGLdcAxAOWM+22gjoRFz3vw2x2vc0L3AhS UqAuUNzsxK1xMCsVuhdsF13WakMo1932/wXO4XIz7WBGbwt5sVAYZuT2RrIbSw+Mutt8 9aUdO+eddzs4osK/9rjtiZI3w46sngqi1Qkp6bIlTPd+a9Iiu9mVYMcuoVu6NBRaXeFk O80g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1680429122; x=1683021122; 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=mPalzn3j45ikPjT3aRccNp7p7+9165ZTfapmFphFUHY=; b=tOgjrAuPBpKkMNLYksv+7IL1ooNjGaU4pScsxvVHUYRssDO/EOBU6nZ6L6fhiY8jEy yhzegD0fp0h2Kq5cX87QmTvACw73wkdZvvYtyfBnysdrA4xqusXlaDXPWtKs5delvVhB 4T1l9yMOajIXASyWnukhSVmKFgTSjGK8Jy1/6CuLhcVnCAABGBzt/u2qZzbHApadX2oL D8W5JHxtemE72DYjSCDfmyJX2d0GUVVioa3tYDpjRxhLCME83kpp1nxvNXy0n3r7/U2W HQNYI3HBMFvDdhDRaLmywk35KiE6U7Udv8Z7YbGCD5tpCSsx6nnTDgS7fxiEerHlEqzu rMGQ== X-Gm-Message-State: AAQBX9fgNiu7hPsUJlTtLcLttCQwc022Rb4vW60EPzyazQ2RHYhZGSfT mWQ164mbnXDLiThtQfcyZsE= X-Received: by 2002:a17:906:1ce:b0:92e:f520:7762 with SMTP id 14-20020a17090601ce00b0092ef5207762mr10352217ejj.6.1680429121988; Sun, 02 Apr 2023 02:52:01 -0700 (PDT) Received: from matrix-ESPRIMO-P710 (p57935146.dip0.t-ipconnect.de. [87.147.81.70]) by smtp.gmail.com with ESMTPSA id u13-20020a1709063b8d00b0093e261cc8bcsm3063039ejf.58.2023.04.02.02.52.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Apr 2023 02:52:01 -0700 (PDT) Date: Sun, 2 Apr 2023 11:51:59 +0200 From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH v2 4/6] staging: rtl8192e: Remove case customer_id = RT_CID_DLINK Message-ID: References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762058557910996043?= X-GMAIL-MSGID: =?utf-8?q?1762058557910996043?= customer_id is initialize to zero. Changing customer_id to RT_CID_DLINK would not change the program execution as there is no equation for RT_CID_DLINK. Remove useless code lines to increase readability. Signed-off-by: Philipp Hortmann --- V1->V2: No changes --- drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c | 6 ------ drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h | 1 - drivers/staging/rtl8192e/rtl8192e/rtl_core.h | 1 - 3 files changed, 8 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c index 1da14e737aa4..cbe66b4a6ad9 100644 --- a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c +++ b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c @@ -431,9 +431,6 @@ static void _rtl92e_read_eeprom_info(struct net_device *dev) else priv->chnl_plan = priv->reg_chnl_plan; - if (priv->eeprom_vid == 0x1186 && priv->eeprom_did == 0x3304) - priv->customer_id = RT_CID_DLINK; - switch (priv->eeprom_customer_id) { case EEPROM_CID_DEFAULT: priv->customer_id = RT_CID_DEFAULT; @@ -460,9 +457,6 @@ static void _rtl92e_read_eeprom_info(struct net_device *dev) case EEPROM_CID_Pronet: priv->customer_id = RT_CID_PRONET; break; - case EEPROM_CID_DLINK: - priv->customer_id = RT_CID_DLINK; - break; case EEPROM_CID_WHQL: break; diff --git a/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h b/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h index 99640c4779f7..706d024bcfd1 100644 --- a/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h +++ b/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h @@ -37,7 +37,6 @@ enum baseband_config { #define EEPROM_CID_NetCore 0x5 #define EEPROM_CID_Nettronix 0x6 #define EEPROM_CID_Pronet 0x7 -#define EEPROM_CID_DLINK 0x8 #define EEPROM_CID_WHQL 0xFE enum _RTL8192PCI_HW { MAC0 = 0x000, diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_core.h b/drivers/staging/rtl8192e/rtl8192e/rtl_core.h index 1e99eb833405..91d634f5d3e7 100644 --- a/drivers/staging/rtl8192e/rtl8192e/rtl_core.h +++ b/drivers/staging/rtl8192e/rtl8192e/rtl_core.h @@ -134,7 +134,6 @@ enum rt_customer_id { RT_CID_TOSHIBA = 9, RT_CID_819X_NETCORE = 10, RT_CID_Nettronix = 11, - RT_CID_DLINK = 12, RT_CID_PRONET = 13, }; From patchwork Sun Apr 2 09:52:05 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philipp Hortmann X-Patchwork-Id: 78220 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1662743vqo; Sun, 2 Apr 2023 03:08:19 -0700 (PDT) X-Google-Smtp-Source: AKy350Zcvf9+Oew80BsQ+6cIuLLRgpRuneK/9kT4W95SWYu0wj8e9iUxfjBUVDmK7NrE+R+FXVTi X-Received: by 2002:a17:903:27ce:b0:19c:da7f:a234 with SMTP id km14-20020a17090327ce00b0019cda7fa234mr26658656plb.67.1680430099189; Sun, 02 Apr 2023 03:08:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680430099; cv=none; d=google.com; s=arc-20160816; b=kCkvhGQAwIs8CEdG9Cv7VyZNzGdWuutV8DqUlgew0Nu+CgKpEq4C/DXR1XCWAUx7Qp gDHreIXZlQJurEyKyxBVAu59t3wWYqwgCJqFZ8uZ9tQ6WkcOX0Td728jqTWdJCdZyVUl LrDnQmUbPSh8BdGYKCQ8jMVP1HIlwyZ4rFvvYBxgZqxvJBXKlnjySkz8mFb2L1uZxFga n/fgPunzfMNIQ6x+6/t3ZQPwdS7WCBQeT+gBB04W8/99/+ujuRWaKDGylOgxu3yOfpCX 3GnJVivwjUG6dK7mk+55WqK7O68XqGYYdgflG3UVJXH5pMi6eiiNbBuofjcNJ3b6wtn6 CAsw== 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=S93CG6AlbKMkphzwNXa0JGigafN4J3sDtR60tP0Iyzc=; b=jcTOaAyG8p0ONhnCzKGsIAqh7A8Y5OsI11ZG5wjli9/Pqe2HRnokSRuCdh/ZHRRIYn tBlXq2DjYKIveG3cDgGGOCfG4p33S0Pe808X9mWVJQXAZH1CFGgkzccITtd3saNJ8p9T UkKs4fnhP6o0zovDDx+qpj+iiw3Dthy8vQfDzlGOsdJxiynZOm7J4BsGoyfXA7S+kcCs 9+6RiB9tMBI6pq71l0A859miDAqNb0mqb7CfybyeXTWbgQ4a+id4CrRFQPNLDkXFMuFF osOM8I/Ouyix59jUGNOkRXUUjRLzHXusAPxEDATPkfUb1ETDkWy5jcReHDiW73lZ9FWy HC/Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=BJQE7ANH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u9-20020a170903124900b001a1fc721c0csi6502260plh.116.2023.04.02.03.07.56; Sun, 02 Apr 2023 03:08:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=BJQE7ANH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230470AbjDBJwp (ORCPT + 99 others); Sun, 2 Apr 2023 05:52:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48524 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230201AbjDBJw2 (ORCPT ); Sun, 2 Apr 2023 05:52:28 -0400 Received: from mail-ej1-x62b.google.com (mail-ej1-x62b.google.com [IPv6:2a00:1450:4864:20::62b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7ED641C1C6 for ; Sun, 2 Apr 2023 02:52:09 -0700 (PDT) Received: by mail-ej1-x62b.google.com with SMTP id a640c23a62f3a-930bc91df7bso77011266b.1 for ; Sun, 02 Apr 2023 02:52:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1680429128; x=1683021128; 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=S93CG6AlbKMkphzwNXa0JGigafN4J3sDtR60tP0Iyzc=; b=BJQE7ANH3TiEiq8wKmFaXIUoNuo92b0CHpEetEDbHu2ZgYuYW3JUfJFQWAyMX67xYU ZG5xX1JAvgY/jHoOJBWLBILwWJPzk1tNKupr6RAWHKNhkBBgi/eIKMJ+u1YziMPBuM3j lxxYXs1r87oV4F5ZW/bDRasox9c+51LTKZvV01MayxVPfVSxr4uB4VJOkWsRoqGKKCJH nm3Gq3QIft/el+6tgE43X/AaANGHNXflTSgaKcMFElA7kxNBSGMZ3EAQNn/ryZ8SBx91 RMBVuziShC/rLOLjrHm/XJ47eAj4EczrYsqxrbZG1Y+SdYNS9TDMtIlI8xhbF+5m+jq1 zPKw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1680429128; x=1683021128; 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=S93CG6AlbKMkphzwNXa0JGigafN4J3sDtR60tP0Iyzc=; b=FVFHWQHWCza/cCVnSJ8Y7iXGxM7duE7HsSqlmsPSz4860iAXrTjUrQUI+prho0oqmA Pmt5mzyjCCKeE6NWWUH6u6cV5OAPPzEdiIrCm74rVa+H5LpRDHtrXJPRR66ftDPvx5X6 WtUAHEiFtPDR4ey4/ciYJhDTNAbxnXXqyuFO3qYi5fldAKSyQI+gXMGOCPlp/k1pUVtN v7Cu3nfyMzLKn2KA1rN7FF9cMWrSd1AOnDBr14vXN5+Zcw/8fvSIzy0YeQw57+6eRF7q qmPocPNNk/By9BtIO0vrBnZqZN+58E72fGBJzW5cRO3lBk2A2ddt7RRBT5v5Y057GTVe GwrQ== X-Gm-Message-State: AAQBX9fK93VC86/xKTLO77DGgZxNIdwl5jdYTF/K9FLP/XCb7Nf1RNGf iX6U5Bs6AcYcmLkOvRnVqto= X-Received: by 2002:a17:906:224e:b0:92c:fc0:b229 with SMTP id 14-20020a170906224e00b0092c0fc0b229mr10688924ejr.0.1680429127797; Sun, 02 Apr 2023 02:52:07 -0700 (PDT) Received: from matrix-ESPRIMO-P710 (p57935146.dip0.t-ipconnect.de. [87.147.81.70]) by smtp.gmail.com with ESMTPSA id 20-20020a170906101400b00947732c6521sm3061047ejm.79.2023.04.02.02.52.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Apr 2023 02:52:07 -0700 (PDT) Date: Sun, 2 Apr 2023 11:52:05 +0200 From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH v2 5/6] staging: rtl8192e: Remove case customer_id = RT_CID_819x_CAMEO, .. Message-ID: References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762058671822628957?= X-GMAIL-MSGID: =?utf-8?q?1762058671822628957?= customer_id is initialize to zero. Changing customer_id to RT_CID_819x_CAMEO, RT_CID_819x_RUNTOP, RT_CID_Nettronix or RT_CID_PRONET would not change the program execution as there is no equation for RT_CID_819x_CAMEO, RT_CID_819x_RUNTOP, RT_CID_Nettronix or RT_CID_PRONET. Remove useless code lines to increase readability. Signed-off-by: Philipp Hortmann --- V1->V2: No changes --- drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c | 12 ------------ drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h | 4 ---- drivers/staging/rtl8192e/rtl8192e/rtl_core.h | 4 ---- 3 files changed, 20 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c index cbe66b4a6ad9..df8de35cbe0e 100644 --- a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c +++ b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c @@ -435,12 +435,6 @@ static void _rtl92e_read_eeprom_info(struct net_device *dev) case EEPROM_CID_DEFAULT: priv->customer_id = RT_CID_DEFAULT; break; - case EEPROM_CID_CAMEO: - priv->customer_id = RT_CID_819x_CAMEO; - break; - case EEPROM_CID_RUNTOP: - priv->customer_id = RT_CID_819x_RUNTOP; - break; case EEPROM_CID_NetCore: priv->customer_id = RT_CID_819X_NETCORE; break; @@ -451,12 +445,6 @@ static void _rtl92e_read_eeprom_info(struct net_device *dev) else priv->chnl_plan = 0x0; break; - case EEPROM_CID_Nettronix: - priv->customer_id = RT_CID_Nettronix; - break; - case EEPROM_CID_Pronet: - priv->customer_id = RT_CID_PRONET; - break; case EEPROM_CID_WHQL: break; diff --git a/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h b/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h index 706d024bcfd1..4ee78b7a558e 100644 --- a/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h +++ b/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h @@ -31,12 +31,8 @@ enum baseband_config { #define EEPROM_TxPwIndex_OFDM_24G 0x3A #define EEPROM_CID_DEFAULT 0x0 -#define EEPROM_CID_CAMEO 0x1 -#define EEPROM_CID_RUNTOP 0x2 #define EEPROM_CID_TOSHIBA 0x4 #define EEPROM_CID_NetCore 0x5 -#define EEPROM_CID_Nettronix 0x6 -#define EEPROM_CID_Pronet 0x7 #define EEPROM_CID_WHQL 0xFE enum _RTL8192PCI_HW { MAC0 = 0x000, diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_core.h b/drivers/staging/rtl8192e/rtl8192e/rtl_core.h index 91d634f5d3e7..2b2d8af4cf6e 100644 --- a/drivers/staging/rtl8192e/rtl8192e/rtl_core.h +++ b/drivers/staging/rtl8192e/rtl8192e/rtl_core.h @@ -129,12 +129,8 @@ enum dcmg_txcmd_op { enum rt_customer_id { RT_CID_DEFAULT = 0, - RT_CID_819x_CAMEO = 6, - RT_CID_819x_RUNTOP = 7, RT_CID_TOSHIBA = 9, RT_CID_819X_NETCORE = 10, - RT_CID_Nettronix = 11, - RT_CID_PRONET = 13, }; enum reset_type { From patchwork Sun Apr 2 09:52:13 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philipp Hortmann X-Patchwork-Id: 78229 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1666933vqo; Sun, 2 Apr 2023 03:20:13 -0700 (PDT) X-Google-Smtp-Source: AKy350bOR7gv0s0eZ47NIgbeBQ0XoUx3alv4ax+kvmRDcjmTJwpFA4+f+w70Poag6w6T6h9yC1yf X-Received: by 2002:a17:90b:3949:b0:23b:3f1b:9cf0 with SMTP id oe9-20020a17090b394900b0023b3f1b9cf0mr16017737pjb.19.1680430813222; Sun, 02 Apr 2023 03:20:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680430813; cv=none; d=google.com; s=arc-20160816; b=UEaRaWhYqiVKOkxjr+m5EboLYHr94Sf62/Q/xNL31zlTGtGFlZlm6sLxlnPU8YwFx3 n8aObkxDMLdEmZxyPwwlwalGAN+vd9JplT9VD+eE/PUDsFQL810sJz2lrUr5uztL3psl Dgn9TWdpnJBF4kXBpkXBEYQ+w8X0RNLeVVSZNQC2gJ+Spf+NQPXRfG8a4Q1YrTZLgtkM TuS9HGQc0xuBQo/JK6H73RwhWndSCIx0QqKYq4mQyege7WSKUg9i+z6XuyIu4brdXx2M A7xlBBsVnmtNCfZMawi3PXfiQUpSXWnbW0X0E1dZKEoN/dEtwsIPIj5eUCeiSfObo1R9 ycUg== 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=0/d2ZeR1z4unotF600EGJ8LS6r3TxAXihhwj6OvhZ4s=; b=M4k6dk341iHz0Rhm5cAyvC31gN4SULwPlJ6HHmgag7Zi5Z+83MGGKck3R/Z28J9bNm z3yOm7CMNhjAyt83rQLc+npk8vmAHHHl9A7XdUqjenWSa0SxFYgHBKMui82P7lzPSRuH sGapFDSp/L6OKbIFQTpip5+VUqBCTChGYQeSU95H8lcAjG6MZW+GokEQPaBwx8uTpD6B ksRyGALfOOCFBQcNLSBT5FcNmCpTNo/Q7H/PRtqW8KzIIHIx3kWRvS9hY/hXLinFfFhM Q50oN/g/EfWOpyTjkBbCZDd+tDG2trf9HfSNNUMhzCGQ3BlIp8TsEeGSxGm33tHU9Y6F pQmA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=Vhs4KIS8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x4-20020a17090a8a8400b00240e633e032si4729039pjn.8.2023.04.02.03.20.01; Sun, 02 Apr 2023 03:20:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=Vhs4KIS8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229503AbjDBJwr (ORCPT + 99 others); Sun, 2 Apr 2023 05:52:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50584 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230367AbjDBJw3 (ORCPT ); Sun, 2 Apr 2023 05:52:29 -0400 Received: from mail-ed1-x529.google.com (mail-ed1-x529.google.com [IPv6:2a00:1450:4864:20::529]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 459BB1D86D for ; Sun, 2 Apr 2023 02:52:16 -0700 (PDT) Received: by mail-ed1-x529.google.com with SMTP id y4so106365714edo.2 for ; Sun, 02 Apr 2023 02:52:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1680429136; x=1683021136; 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=0/d2ZeR1z4unotF600EGJ8LS6r3TxAXihhwj6OvhZ4s=; b=Vhs4KIS8EiSOEDtFrW5LWi892ufy5hYLekAexhJ7VTBT23bHuDBUUwV4vArZaxEZcP 9/cay62aOVWWH6M1N6cNHvZ1QZ2nqCtqyw2a7LdjK0p1KfuWrz1FSmG2yOdDr4PQIGCB jW2DNQLlxPjl/zdnZ1mEXrqWhBzDJk3ftS74carwEtcG3vBucvzwnWxHKZbyJ567US68 js1CLL5WF2k0/pvNwmjxPLvD4rYY+eTPsj9wh+jLXQbUj3kPt6RovjY/2p4FvsDQj2ry bPnQojhYRCn5EVaJ0i2lK4Z6wKr+OnGeed0w4UspfqBqLkcrCDbRBD3HNtdpyBko14Jm 5q7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1680429136; x=1683021136; 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=0/d2ZeR1z4unotF600EGJ8LS6r3TxAXihhwj6OvhZ4s=; b=mdj1+QG6N3KsP4JBO02yK2s9J8Wk7dlHH1Kt4k2IJuzlD6XFkQuopTX1GTU034EcVl cRxbu3CGEJjFmqd3U6ntvPfs9zPWJcHinEjCtL0oCeaCfb6Bd4GjilVf/g55GB1loGJW AU0A+kZcC8oR4fDGSXM05gpBx+v/BO+xronh8XZ37D2iFU4DOtieVvhP9x8sYBJfkm61 ogxBlyT0NOiQylvmKL5m8SXTUulyfwCPd2hyfnJsrAfw19Fhq0uVDdkhBktG1xIx1viW rx0Aw4jzVn1HZYOCSvk3gMFWMR37ja4UrKsv5JzpAinrPVYPIEAsQF8TtYZer9nW0jyr hldg== X-Gm-Message-State: AAQBX9e5g6It6l+a+IlXk0nr72nGoHD6SoxXK1nHnBAqDO2GAJ2kAAeE qtltiQTB9iPhUHMHb8X6nQAISumeqP0= X-Received: by 2002:a17:906:7390:b0:947:8734:a058 with SMTP id f16-20020a170906739000b009478734a058mr8284146ejl.4.1680429135633; Sun, 02 Apr 2023 02:52:15 -0700 (PDT) Received: from matrix-ESPRIMO-P710 (p57935146.dip0.t-ipconnect.de. [87.147.81.70]) by smtp.gmail.com with ESMTPSA id p16-20020a170906a01000b008cc920469b5sm3099067ejy.18.2023.04.02.02.52.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Apr 2023 02:52:15 -0700 (PDT) Date: Sun, 2 Apr 2023 11:52:13 +0200 From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH v2 6/6] staging: rtl8192e: Remove case customer_id = RT_CID_DEFAULT, .. Message-ID: <58df9db5da84991206266e739b2a12c893d1be8e.1680427945.git.philipp.g.hortmann@gmail.com> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762059420579317996?= X-GMAIL-MSGID: =?utf-8?q?1762059420579317996?= customer_id is initialize to zero. Changing customer_id to RT_CID_DEFAULT will not change customer_id as it is already zero. default and EEPROM_CID_WHQL contain only a break. Remove useless code lines to increase readability. Signed-off-by: Philipp Hortmann --- V1->V2: No changes --- drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c | 8 -------- drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h | 2 -- 2 files changed, 10 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c index df8de35cbe0e..aed53fedeb61 100644 --- a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c +++ b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c @@ -432,9 +432,6 @@ static void _rtl92e_read_eeprom_info(struct net_device *dev) priv->chnl_plan = priv->reg_chnl_plan; switch (priv->eeprom_customer_id) { - case EEPROM_CID_DEFAULT: - priv->customer_id = RT_CID_DEFAULT; - break; case EEPROM_CID_NetCore: priv->customer_id = RT_CID_819X_NETCORE; break; @@ -445,11 +442,6 @@ static void _rtl92e_read_eeprom_info(struct net_device *dev) else priv->chnl_plan = 0x0; break; - - case EEPROM_CID_WHQL: - break; - default: - break; } if (priv->chnl_plan > CHANNEL_PLAN_LEN - 1) diff --git a/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h b/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h index 4ee78b7a558e..f4d4b01630a2 100644 --- a/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h +++ b/drivers/staging/rtl8192e/rtl8192e/r8192E_hw.h @@ -30,10 +30,8 @@ enum baseband_config { #define EEPROM_TxPwIndex_CCK 0x2C #define EEPROM_TxPwIndex_OFDM_24G 0x3A -#define EEPROM_CID_DEFAULT 0x0 #define EEPROM_CID_TOSHIBA 0x4 #define EEPROM_CID_NetCore 0x5 -#define EEPROM_CID_WHQL 0xFE enum _RTL8192PCI_HW { MAC0 = 0x000, MAC4 = 0x004,