From patchwork Sun Nov 19 22:14: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: 166892 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9910:0:b0:403:3b70:6f57 with SMTP id i16csp1858254vqn; Sun, 19 Nov 2023 14:14:55 -0800 (PST) X-Google-Smtp-Source: AGHT+IFoq22H/6yCFpE7lCjmyIw1Q+KNQHMcSNDhoo506Qhv35RN+VzhGfnmbK2zMNPdmuibeuTS X-Received: by 2002:a05:6a21:9210:b0:187:7f06:da3d with SMTP id tl16-20020a056a21921000b001877f06da3dmr10472364pzb.21.1700432095704; Sun, 19 Nov 2023 14:14:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700432095; cv=none; d=google.com; s=arc-20160816; b=i53sEbcuepWHiZ4sQwTmWTCHk2avz1atnr3QRNsBNrjsrqbZThJ+ZsJ9MdOnjR0bWj L6z4QmpOfbu7CzPM0VXJf63NJvylUNjihOehiqgXZ1gOJXMevh3Ah5fPo7IG6w7o/V5Z mB0Nli3OVcfEz5gBBxSi2X6G/z/H9tmK1fq6eg01rlDANrRUpCL2W+P5f7lCFe1Dnequ zs3w6KrrZnzBU6fMH/tkIDOGJqq8hP89DSi2hDtaygzzq8mrW2kPbXc7Q+B5AX8By3e6 qhG2mi/qU/hprtTtTJO5UPeYe/hH6BpKyqpu5iFLjYGOax+zmmZXbf8ycQ9A7y4IsTMi 4tAg== 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=yx4XEQPLPrhx/0ZC7QuPfqxkRIrwqbWbj56fu2tqSnQ=; fh=Sw1rtAM+hKyOoOQVYiiLzcdjc4spg79Z/tN6UmWUAKs=; b=DQNUoRZjJ47610LmhDdVwQr8UOCjVgWAagJtH6EmkD3brXBweqo17+Loop3eCstjrS akp9S9KVyMJAPqg3zZMwtT8ZUhsFblpy1Tb9pwnkY69LeapyuoHO7Kg/MSjO5RLW/NIr rDfqfhKjdZ9bWW0NVl27S4szCC48kynvunoQLS+qQXHYH1DplPV+/1pcmU0U+GnfETXo Z5yc9POUSMFBGPvLedaeBQJKvkzjwkeSiryK08+lBUdGKqpVPUsWxHBQGV92F4SnqdfC IoSKBbe/18GlLNkXhEEMfgaecS17CBRcYbfhb2NXIiZA59iRC8LF5+f6SC3FyXMPXEau t6QQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=iFQ8W0Es; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 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 snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id x64-20020a638643000000b005b9066580d1si6335004pgd.754.2023.11.19.14.14.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 19 Nov 2023 14:14:55 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=iFQ8W0Es; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 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 snail.vger.email (Postfix) with ESMTP id EF106802C8F4; Sun, 19 Nov 2023 14:14:52 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231624AbjKSWOw (ORCPT + 28 others); Sun, 19 Nov 2023 17:14:52 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56692 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231633AbjKSWOu (ORCPT ); Sun, 19 Nov 2023 17:14:50 -0500 Received: from mail-wr1-x435.google.com (mail-wr1-x435.google.com [IPv6:2a00:1450:4864:20::435]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1922812D for ; Sun, 19 Nov 2023 14:14:46 -0800 (PST) Received: by mail-wr1-x435.google.com with SMTP id ffacd0b85a97d-32f9baca5bcso894188f8f.0 for ; Sun, 19 Nov 2023 14:14:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700432084; x=1701036884; 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=yx4XEQPLPrhx/0ZC7QuPfqxkRIrwqbWbj56fu2tqSnQ=; b=iFQ8W0Esi/fdhX30AmOQzspnlL1Wty1RXgurUYUUghQQkcQgC3DN3d67txHG7hs+D+ BC9V56WaChmcqNVxoNyiQVNjVc7SotXzONStbOpaAaqRe245JRu4uhRaUyhWexm0X5aX eXQz1rEtyNC7Ndn4lO+0HXHKJFU30N+Dm/S5jVC+ZDDrnkaCw0R/iGdd+2+hxiO9/vFe E/yl4mkyM7uryVhrTrKgXwv8+k2kaN3WTJwzC4l/HBbdahssn6P70Njy7+fIkAuL1DoT SXOKw9f/UAfuPiHNGBhu4VktROFokL11qt5MYYnrwSMn+ym3GIzFifsYI6l259XAbUe6 Q7eg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700432084; x=1701036884; 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=yx4XEQPLPrhx/0ZC7QuPfqxkRIrwqbWbj56fu2tqSnQ=; b=i4WVmMcGM5cbPjT8M6D9Oh598l498SL+lcqGG7vgbz3EszNFftjdCnCnUgpT0mGIf+ xrdRSjnCAmeLwiOg/u79Q0lzhc0yG5Pla3PNB0Ms0nzfSzUThi8FA1JLN8w36AEYepzs +mWPaYdBOuGwYJaJXwoOa83idee8ypAAsmWnm4vqV1My6myQ7QLJghFjBgM1iPUeu5gu asImwyPQjkgo3ypSdpq7sWmwe3yS/HknfLE5vnbMNWHwih+04GdXTZ2HZcStym+vkSvt l1veFhwcD7OG5Bn96phQuI7+nBMdA13XBie8YJFKicc+9VYGACerPKDMQl2CARm15igh vYVw== X-Gm-Message-State: AOJu0YzTGjsKE0NPWS/bGZqIKgMENP226sAkKoyBbUOG6H0+dt4riwWP BYRl0w1zVpffsmRLWVwBako= X-Received: by 2002:a05:600c:1d18:b0:404:72f9:d59a with SMTP id l24-20020a05600c1d1800b0040472f9d59amr4921697wms.0.1700432083647; Sun, 19 Nov 2023 14:14:43 -0800 (PST) Received: from matrix-ESPRIMO-P710 (p54a07fa0.dip0.t-ipconnect.de. [84.160.127.160]) by smtp.gmail.com with ESMTPSA id n18-20020a05600c3b9200b00407efbc4361sm16033038wms.9.2023.11.19.14.14.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 19 Nov 2023 14:14:43 -0800 (PST) Date: Sun, 19 Nov 2023 23:14:42 +0100 From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH 02/14] staging: rtl8192e: Remove unused function dot11d_update_country() Message-ID: <364462eae2271f3925b362a439ec27d50dd899ef.1700431464.git.philipp.g.hortmann@gmail.com> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham 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-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Sun, 19 Nov 2023 14:14:53 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1783032284844862467 X-GMAIL-MSGID: 1783032284844862467 Remove unused function dot11d_update_country(). Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8192e/dot11d.c | 44 ------------------------------- drivers/staging/rtl8192e/dot11d.h | 2 -- 2 files changed, 46 deletions(-) diff --git a/drivers/staging/rtl8192e/dot11d.c b/drivers/staging/rtl8192e/dot11d.c index fdc39e6e7abb..fc65a63a4de6 100644 --- a/drivers/staging/rtl8192e/dot11d.c +++ b/drivers/staging/rtl8192e/dot11d.c @@ -61,50 +61,6 @@ void dot11d_reset(struct rtllib_device *ieee) RESET_CIE_WATCHDOG(ieee); } -void dot11d_update_country(struct rtllib_device *dev, u8 *address, - u16 country_len, u8 *country) -{ - struct rt_dot11d_info *dot11d_info = GET_DOT11D_INFO(dev); - u8 i, j, number_of_triples, max_channel_number; - struct chnl_txpow_triple *triple; - - memset(dot11d_info->channel_map, 0, MAX_CHANNEL_NUMBER + 1); - memset(dot11d_info->max_tx_power_list, 0xFF, MAX_CHANNEL_NUMBER + 1); - max_channel_number = 0; - number_of_triples = (country_len - 3) / 3; - triple = (struct chnl_txpow_triple *)(country + 3); - for (i = 0; i < number_of_triples; i++) { - if (max_channel_number >= triple->first_channel) { - netdev_info(dev->dev, - "%s: Invalid country IE, skip it......1\n", - __func__); - return; - } - if (MAX_CHANNEL_NUMBER < (triple->first_channel + - triple->num_channels)) { - netdev_info(dev->dev, - "%s: Invalid country IE, skip it......2\n", - __func__); - return; - } - - for (j = 0; j < triple->num_channels; j++) { - dot11d_info->channel_map[triple->first_channel + j] = 1; - dot11d_info->max_tx_power_list[triple->first_channel + j] = - triple->max_tx_power; - max_channel_number = triple->first_channel + j; - } - - triple = (struct chnl_txpow_triple *)((u8 *)triple + 3); - } - - UPDATE_CIE_SRC(dev, address); - - dot11d_info->country_len = country_len; - memcpy(dot11d_info->country_buffer, country, country_len); - dot11d_info->state = DOT11D_STATE_LEARNED; -} - void dot11d_scan_complete(struct rtllib_device *dev) { struct rt_dot11d_info *dot11d_info = GET_DOT11D_INFO(dev); diff --git a/drivers/staging/rtl8192e/dot11d.h b/drivers/staging/rtl8192e/dot11d.h index 78d1ca1e7743..39bda2f94eed 100644 --- a/drivers/staging/rtl8192e/dot11d.h +++ b/drivers/staging/rtl8192e/dot11d.h @@ -77,8 +77,6 @@ static inline void RESET_CIE_WATCHDOG(struct rtllib_device *__ieee_dev) void dot11d_init(struct rtllib_device *dev); void dot11d_channel_map(struct rtllib_device *ieee); void dot11d_reset(struct rtllib_device *dev); -void dot11d_update_country(struct rtllib_device *dev, u8 *address, - u16 country_len, u8 *country); void dot11d_scan_complete(struct rtllib_device *dev); #endif