Re: [PATCH 01/12] staging: wilc1000: pass vif to hostIFthread

2015-12-18 Thread Greg KH
On Mon, Dec 14, 2015 at 02:46:52PM +0900, Glen Lee wrote:
> We will pass vif, which is currently being used as net_device, instead of
> hif_dev. This is the first step to use index of vif to pass to the driver.
> Add new argument vif to all the functions that send message to hostIFthread 
> and
> set vif to msg.vif. As a result, hostIfthread will get vif.
> In later patch, we will remove drv of host_if_msg and use vif instead of it.
> 
> Signed-off-by: Glen Lee 

Series did not apply :(

Please rebase all of your pending patches against my staging-testing
branch now and resend what I did not apply.

thanks,

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 01/12] staging: wilc1000: pass vif to hostIFthread

2015-12-13 Thread Glen Lee
We will pass vif, which is currently being used as net_device, instead of
hif_dev. This is the first step to use index of vif to pass to the driver.
Add new argument vif to all the functions that send message to hostIFthread and
set vif to msg.vif. As a result, hostIfthread will get vif.
In later patch, we will remove drv of host_if_msg and use vif instead of it.

Signed-off-by: Glen Lee 
---
 drivers/staging/wilc1000/host_interface.c | 235 ++
 drivers/staging/wilc1000/host_interface.h | 165 +++
 drivers/staging/wilc1000/linux_wlan.c |  22 +-
 drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 166 ---
 4 files changed, 342 insertions(+), 246 deletions(-)

diff --git a/drivers/staging/wilc1000/host_interface.c 
b/drivers/staging/wilc1000/host_interface.c
index f7e560e..c52a8e1 100644
--- a/drivers/staging/wilc1000/host_interface.c
+++ b/drivers/staging/wilc1000/host_interface.c
@@ -194,6 +194,7 @@ struct host_if_msg {
u16 id;
union message_body body;
struct host_if_drv *drv;
+   struct wilc_vif *vif;
 };
 
 struct join_bss_param {
@@ -389,9 +390,13 @@ static s32 handle_set_operation_mode(struct host_if_drv 
*hif_drv,
return result;
 }
 
-static s32 host_int_get_ipaddress(struct host_if_drv *hif_drv, u8 *u16ipadd, 
u8 idx);
+static s32 host_int_get_ipaddress(struct wilc_vif *vif,
+ struct host_if_drv *hif_drv,
+ u8 *u16ipadd, u8 idx);
 
-static s32 handle_set_ip_address(struct host_if_drv *hif_drv, u8 *ip_addr, u8 
idx)
+static s32 handle_set_ip_address(struct wilc_vif *vif,
+struct host_if_drv *hif_drv, u8 *ip_addr,
+u8 idx)
 {
s32 result = 0;
struct wid wid;
@@ -413,7 +418,7 @@ static s32 handle_set_ip_address(struct host_if_drv 
*hif_drv, u8 *ip_addr, u8 id
result = wilc_send_config_pkt(hif_drv->wilc, SET_CFG, , 1,
 get_id_from_handler(hif_drv));
 
-   host_int_get_ipaddress(hif_drv, firmware_ip_addr, idx);
+   host_int_get_ipaddress(vif, hif_drv, firmware_ip_addr, idx);
 
if (result) {
PRINT_ER("Failed to set IP address\n");
@@ -425,7 +430,8 @@ static s32 handle_set_ip_address(struct host_if_drv 
*hif_drv, u8 *ip_addr, u8 id
return result;
 }
 
-static s32 handle_get_ip_address(struct host_if_drv *hif_drv, u8 idx)
+static s32 handle_get_ip_address(struct wilc_vif *vif,
+struct host_if_drv *hif_drv, u8 idx)
 {
s32 result = 0;
struct wid wid;
@@ -445,7 +451,7 @@ static s32 handle_get_ip_address(struct host_if_drv 
*hif_drv, u8 idx)
kfree(wid.val);
 
if (memcmp(get_ip[idx], set_ip[idx], IP_ALEN) != 0)
-   wilc_setup_ipaddress(hif_drv, set_ip[idx], idx);
+   wilc_setup_ipaddress(vif, hif_drv, set_ip[idx], idx);
 
if (result != 0) {
PRINT_ER("Failed to get IP address\n");
@@ -1490,7 +1496,8 @@ static s32 host_int_get_assoc_res_info(struct host_if_drv 
*hif_drv,
   u32 u32MaxAssocRespInfoLen,
   u32 *pu32RcvdAssocRespInfoLen);
 
-static s32 Handle_RcvdGnrlAsyncInfo(struct host_if_drv *hif_drv,
+static s32 Handle_RcvdGnrlAsyncInfo(struct wilc_vif *vif,
+   struct host_if_drv *hif_drv,
struct rcvd_async_info 
*pstrRcvdGnrlAsyncInfo)
 {
s32 result = 0;
@@ -1619,7 +1626,7 @@ static s32 Handle_RcvdGnrlAsyncInfo(struct host_if_drv 
*hif_drv,
 
if ((u8MacStatus == MAC_CONNECTED) &&
(strConnectInfo.u16ConnectStatus == 
SUCCESSFUL_STATUSCODE)) {
-   wilc_set_power_mgmt(hif_drv, 0, 0);
+   wilc_set_power_mgmt(vif, hif_drv, 0, 0);
 
PRINT_D(HOSTINF_DBG, "MAC status : CONNECTED 
and Connect Status : Successful\n");
hif_drv->hif_state = HOST_IF_CONNECTED;
@@ -1662,7 +1669,7 @@ static s32 Handle_RcvdGnrlAsyncInfo(struct host_if_drv 
*hif_drv,
 
if (hif_drv->usr_conn_req.conn_result) {
wilc_optaining_ip = false;
-   wilc_set_power_mgmt(hif_drv, 0, 0);
+   wilc_set_power_mgmt(vif, hif_drv, 0, 0);
 

hif_drv->usr_conn_req.conn_result(CONN_DISCONN_EVENT_DISCONN_NOTIF,
  NULL,
@@ -1984,7 +1991,8 @@ _WPAPtk_end_case_:
return result;
 }
 
-static void Handle_Disconnect(struct host_if_drv *hif_drv)
+static void Handle_Disconnect(struct wilc_vif *vif,
+ struct host_if_drv *hif_drv)
 {
struct wid wid;
 
@@ -1999,7