linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: <Adham.Abozaeid@microchip.com>
To: <linux-wireless@vger.kernel.org>
Cc: <devel@driverdev.osuosl.org>, <gregkh@linuxfoundation.org>,
	<johannes@sipsolutions.net>, <Ajay.Kathat@microchip.com>,
	<Adham.Abozaeid@microchip.com>
Subject: [PATCH 3/6] staging: wilc1000: remove unused members
Date: Thu, 25 Jul 2019 21:31:34 +0000	[thread overview]
Message-ID: <20190725213125.2810-4-adham.abozaeid@microchip.com> (raw)
In-Reply-To: <20190725213125.2810-1-adham.abozaeid@microchip.com>

From: Adham Abozaeid <adham.abozaeid@microchip.com>

remove obtaining_ip from struct wilc_vif

Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
---
 drivers/staging/wilc1000/wilc_hif.c               | 9 ++-------
 drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 3 ---
 drivers/staging/wilc1000/wilc_wfi_netdevice.h     | 1 -
 3 files changed, 2 insertions(+), 11 deletions(-)

diff --git a/drivers/staging/wilc1000/wilc_hif.c b/drivers/staging/wilc1000/wilc_hif.c
index 9bd2d14ad610..611f842d2836 100644
--- a/drivers/staging/wilc1000/wilc_hif.c
+++ b/drivers/staging/wilc1000/wilc_hif.c
@@ -248,7 +248,7 @@ int wilc_scan(struct wilc_vif *vif, u8 scan_source, u8 scan_type,
 		goto error;
 	}
 
-	if (vif->obtaining_ip || vif->connecting) {
+	if (vif->connecting) {
 		netdev_err(vif->ndev, "Don't do obss scan\n");
 		result = -EBUSY;
 		goto error;
@@ -682,8 +682,6 @@ static inline void host_int_parse_assoc_resp_info(struct wilc_vif *vif,
 		wilc_set_power_mgmt(vif, 0, 0);
 
 		hif_drv->hif_state = HOST_IF_CONNECTED;
-
-		vif->obtaining_ip = true;
 	} else {
 		hif_drv->hif_state = HOST_IF_IDLE;
 	}
@@ -707,7 +705,6 @@ static inline void host_int_handle_disconnect(struct wilc_vif *vif)
 	}
 
 	if (hif_drv->conn_info.conn_result) {
-		vif->obtaining_ip = false;
 		wilc_set_power_mgmt(vif, 0, 0);
 
 		hif_drv->conn_info.conn_result(CONN_DISCONN_EVENT_DISCONN_NOTIF,
@@ -770,7 +767,6 @@ int wilc_disconnect(struct wilc_vif *vif)
 	wid.val = (s8 *)&dummy_reason_code;
 	wid.size = sizeof(char);
 
-	vif->obtaining_ip = false;
 	wilc_set_power_mgmt(vif, 0, 0);
 
 	result = wilc_send_config_pkt(vif, WILC_SET_CFG, &wid, 1);
@@ -922,7 +918,7 @@ static int handle_remain_on_chan(struct wilc_vif *vif,
 	if (hif_drv->hif_state == HOST_IF_WAITING_CONN_RESP)
 		return -EBUSY;
 
-	if (vif->obtaining_ip || vif->connecting)
+	if (vif->connecting)
 		return -EBUSY;
 
 	remain_on_chan_flag = true;
@@ -1608,7 +1604,6 @@ int wilc_init(struct net_device *dev, struct host_if_drv **hif_drv_handler)
 	*hif_drv_handler = hif_drv;
 
 	vif->hif_drv = hif_drv;
-	vif->obtaining_ip = false;
 
 	if (wilc->clients_count == 0)
 		mutex_init(&wilc->deinit_lock);
diff --git a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
index 5559f27c8e24..6ac0fe58ceed 100644
--- a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
+++ b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
@@ -167,7 +167,6 @@ static void cfg_connect_result(enum conn_event conn_disconn_evt, u8 mac_status,
 	} else if (conn_disconn_evt == CONN_DISCONN_EVENT_DISCONN_NOTIF) {
 		u16 reason = 0;
 
-		vif->obtaining_ip = false;
 		priv->p2p.local_random = 0x01;
 		priv->p2p.recv_random = 0x00;
 		priv->p2p.is_wilc_ie = false;
@@ -1412,7 +1411,6 @@ static int change_virtual_intf(struct wiphy *wiphy, struct net_device *dev,
 	priv->p2p.local_random = 0x01;
 	priv->p2p.recv_random = 0x00;
 	priv->p2p.is_wilc_ie = false;
-	vif->obtaining_ip = false;
 
 	switch (type) {
 	case NL80211_IFTYPE_STATION:
@@ -1459,7 +1457,6 @@ static int change_virtual_intf(struct wiphy *wiphy, struct net_device *dev,
 		break;
 
 	case NL80211_IFTYPE_P2P_GO:
-		vif->obtaining_ip = true;
 		wilc_set_operation_mode(vif, WILC_AP_MODE);
 		dev->ieee80211_ptr->iftype = type;
 		priv->wdev.iftype = type;
diff --git a/drivers/staging/wilc1000/wilc_wfi_netdevice.h b/drivers/staging/wilc1000/wilc_wfi_netdevice.h
index 1e74a08e7cf1..704e4d572695 100644
--- a/drivers/staging/wilc1000/wilc_wfi_netdevice.h
+++ b/drivers/staging/wilc1000/wilc_wfi_netdevice.h
@@ -203,7 +203,6 @@ struct wilc_vif {
 	struct net_device *ndev;
 	u8 mode;
 	struct timer_list during_ip_timer;
-	bool obtaining_ip;
 	struct timer_list periodic_rssi;
 	struct rf_info periodic_stat;
 	struct tcp_ack_filter ack_filter;
-- 
2.17.1


  parent reply	other threads:[~2019-07-25 21:31 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-25 21:31 [PATCH 0/6] staging: wilc1000: don't override user power management selection Adham.Abozaeid
2019-07-25 21:31 ` [PATCH 1/6] staging: wilc1000: remove inetaddr notifier Adham.Abozaeid
2019-07-25 21:31 ` [PATCH 2/6] staging: wilc1000: remove ip timeout timer Adham.Abozaeid
2019-07-25 21:31 ` Adham.Abozaeid [this message]
2019-08-06 12:46   ` [PATCH 3/6] staging: wilc1000: remove unused members Dan Carpenter
2019-08-06 19:32     ` Adham.Abozaeid
2019-08-07 11:03       ` Dan Carpenter
2019-08-08 18:14         ` Adham.Abozaeid
2019-08-08 18:16         ` Adham.Abozaeid
2019-07-25 21:31 ` [PATCH 4/6] staging: wilc1000: avoid overriding powersave state Adham.Abozaeid
2019-07-25 21:31 ` [PATCH 5/6] staging: wilc1000: apply power management regardless of open interfaces Adham.Abozaeid
2019-07-25 21:31 ` [PATCH 6/6] staging: wilc1000: remove manual sleep mode Adham.Abozaeid

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=20190725213125.2810-4-adham.abozaeid@microchip.com \
    --to=adham.abozaeid@microchip.com \
    --cc=Ajay.Kathat@microchip.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).