From: Michael Straube <straube.linux@gmail.com>
To: gregkh@linuxfoundation.org
Cc: Larry.Finger@lwfinger.net, phil@philpotter.co.uk,
martin@kaiser.cx, fmdefrancesco@gmail.com,
linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org,
Michael Straube <straube.linux@gmail.com>
Subject: [PATCH 2/6] staging: r8188eu: remove rtw_acl_add_sta()
Date: Sun, 19 Sep 2021 17:36:55 +0200 [thread overview]
Message-ID: <20210919153659.20826-3-straube.linux@gmail.com> (raw)
In-Reply-To: <20210919153659.20826-1-straube.linux@gmail.com>
Function rtw_acl_add_sta() is not used, remove it.
Signed-off-by: Michael Straube <straube.linux@gmail.com>
---
drivers/staging/r8188eu/core/rtw_ap.c | 65 ------------------------
drivers/staging/r8188eu/include/rtw_ap.h | 1 -
2 files changed, 66 deletions(-)
diff --git a/drivers/staging/r8188eu/core/rtw_ap.c b/drivers/staging/r8188eu/core/rtw_ap.c
index 49d65d5b3bac..60ef8092c40b 100644
--- a/drivers/staging/r8188eu/core/rtw_ap.c
+++ b/drivers/staging/r8188eu/core/rtw_ap.c
@@ -995,71 +995,6 @@ void rtw_set_macaddr_acl(struct adapter *padapter, int mode)
pacl_list->mode = mode;
}
-int rtw_acl_add_sta(struct adapter *padapter, u8 *addr)
-{
- struct list_head *plist, *phead;
- u8 added = false;
- int i, ret = 0;
- struct rtw_wlan_acl_node *paclnode;
- struct sta_priv *pstapriv = &padapter->stapriv;
- struct wlan_acl_pool *pacl_list = &pstapriv->acl_list;
- struct __queue *pacl_node_q = &pacl_list->acl_node_q;
-
- DBG_88E("%s(acl_num =%d) =%pM\n", __func__, pacl_list->num, (addr));
-
- if ((NUM_ACL - 1) < pacl_list->num)
- return -1;
-
- spin_lock_bh(&pacl_node_q->lock);
-
- phead = get_list_head(pacl_node_q);
- plist = phead->next;
-
- while (phead != plist) {
- paclnode = container_of(plist, struct rtw_wlan_acl_node, list);
- plist = plist->next;
-
- if (!memcmp(paclnode->addr, addr, ETH_ALEN)) {
- if (paclnode->valid) {
- added = true;
- DBG_88E("%s, sta has been added\n", __func__);
- break;
- }
- }
- }
-
- spin_unlock_bh(&pacl_node_q->lock);
-
- if (added)
- return ret;
-
- spin_lock_bh(&pacl_node_q->lock);
-
- for (i = 0; i < NUM_ACL; i++) {
- paclnode = &pacl_list->aclnode[i];
-
- if (!paclnode->valid) {
- INIT_LIST_HEAD(&paclnode->list);
-
- memcpy(paclnode->addr, addr, ETH_ALEN);
-
- paclnode->valid = true;
-
- list_add_tail(&paclnode->list, get_list_head(pacl_node_q));
-
- pacl_list->num++;
-
- break;
- }
- }
-
- DBG_88E("%s, acl_num =%d\n", __func__, pacl_list->num);
-
- spin_unlock_bh(&pacl_node_q->lock);
-
- return ret;
-}
-
int rtw_acl_remove_sta(struct adapter *padapter, u8 *addr)
{
struct list_head *plist, *phead;
diff --git a/drivers/staging/r8188eu/include/rtw_ap.h b/drivers/staging/r8188eu/include/rtw_ap.h
index 11e6f799d577..d0d1f3834bd6 100644
--- a/drivers/staging/r8188eu/include/rtw_ap.h
+++ b/drivers/staging/r8188eu/include/rtw_ap.h
@@ -23,7 +23,6 @@ void update_sta_info_apmode(struct adapter *padapter, struct sta_info *psta);
int rtw_check_beacon_data(struct adapter *padapter, u8 *pbuf, int len);
void rtw_ap_restore_network(struct adapter *padapter);
void rtw_set_macaddr_acl(struct adapter *padapter, int mode);
-int rtw_acl_add_sta(struct adapter *padapter, u8 *addr);
int rtw_acl_remove_sta(struct adapter *padapter, u8 *addr);
void associated_clients_update(struct adapter *padapter, u8 updated);
--
2.33.0
next prev parent reply other threads:[~2021-09-19 15:37 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-19 15:36 [PATCH 0/6] staging: r8188eu: remove unused functions from rtw_ap.c Michael Straube
2021-09-19 15:36 ` [PATCH 1/6] staging: r8188eu: remove ap_sta_info_defer_update() Michael Straube
2021-09-19 15:36 ` Michael Straube [this message]
2021-09-19 15:36 ` [PATCH 3/6] staging: r8188eu: remove rtw_acl_remove_sta() Michael Straube
2021-09-19 15:36 ` [PATCH 4/6] staging: r8188eu: remove rtw_ap_inform_ch_switch() Michael Straube
2021-09-19 15:36 ` [PATCH 5/6] staging: r8188eu: remove rtw_check_beacon_data() Michael Straube
2021-09-19 15:36 ` [PATCH 6/6] staging: r8188eu: remove rtw_set_macaddr_acl() Michael Straube
2021-09-19 20:27 ` [PATCH 0/6] staging: r8188eu: remove unused functions from rtw_ap.c Phillip Potter
2021-09-20 10:34 ` Greg KH
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210919153659.20826-3-straube.linux@gmail.com \
--to=straube.linux@gmail.com \
--cc=Larry.Finger@lwfinger.net \
--cc=fmdefrancesco@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-staging@lists.linux.dev \
--cc=martin@kaiser.cx \
--cc=phil@philpotter.co.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.