From 03785387e1c6b236a04d595f98b014b78e585202 Mon Sep 17 00:00:00 2001 From: Avinash Patil Date: Tue, 8 May 2012 18:30:14 -0700 Subject: mwifiex: handle station specific commands on STA interface only Commands like IBSS coalescing status, power save, 11D should be handled only when bss_type is STA. Signed-off-by: Avinash Patil Signed-off-by: Yogesh Ashok Powar Signed-off-by: Kiran Divekar Signed-off-by: Bing Zhao Signed-off-by: John W. Linville --- drivers/net/wireless/mwifiex/cmdevt.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'drivers/net/wireless/mwifiex/cmdevt.c') diff --git a/drivers/net/wireless/mwifiex/cmdevt.c b/drivers/net/wireless/mwifiex/cmdevt.c index 1710beffb93a..d9f30c5fb16d 100644 --- a/drivers/net/wireless/mwifiex/cmdevt.c +++ b/drivers/net/wireless/mwifiex/cmdevt.c @@ -440,6 +440,11 @@ int mwifiex_process_event(struct mwifiex_adapter *adapter) do_gettimeofday(&tstamp); dev_dbg(adapter->dev, "event: %lu.%lu: cause: %#x\n", tstamp.tv_sec, tstamp.tv_usec, eventcause); + } else { + /* Handle PS_SLEEP/AWAKE events on STA */ + priv = mwifiex_get_priv(adapter, MWIFIEX_BSS_ROLE_STA); + if (!priv) + priv = mwifiex_get_priv(adapter, MWIFIEX_BSS_ROLE_ANY); } ret = mwifiex_process_sta_event(priv); -- cgit v1.2.3 From 40d07030625840156bffe2da3e9f14f87d7a4a99 Mon Sep 17 00:00:00 2001 From: Avinash Patil Date: Tue, 8 May 2012 18:30:19 -0700 Subject: mwifiex: add bss start and bss stop commands for AP 1. separate file for preparing uAP command buffer 2. definition of bss_start and bss_stop commands being sent to firmware Signed-off-by: Avinash Patil Signed-off-by: Yogesh Ashok Powar Signed-off-by: Kiran Divekar Signed-off-by: Bing Zhao Signed-off-by: John W. Linville --- drivers/net/wireless/mwifiex/cmdevt.c | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'drivers/net/wireless/mwifiex/cmdevt.c') diff --git a/drivers/net/wireless/mwifiex/cmdevt.c b/drivers/net/wireless/mwifiex/cmdevt.c index d9f30c5fb16d..51e023ec1de4 100644 --- a/drivers/net/wireless/mwifiex/cmdevt.c +++ b/drivers/net/wireless/mwifiex/cmdevt.c @@ -545,8 +545,20 @@ int mwifiex_send_cmd_async(struct mwifiex_private *priv, uint16_t cmd_no, /* Prepare command */ if (cmd_no) { - ret = mwifiex_sta_prepare_cmd(priv, cmd_no, cmd_action, - cmd_oid, data_buf, cmd_ptr); + switch (cmd_no) { + case HostCmd_CMD_UAP_SYS_CONFIG: + case HostCmd_CMD_UAP_BSS_START: + case HostCmd_CMD_UAP_BSS_STOP: + ret = mwifiex_uap_prepare_cmd(priv, cmd_no, cmd_action, + cmd_oid, data_buf, + cmd_ptr); + break; + default: + ret = mwifiex_sta_prepare_cmd(priv, cmd_no, cmd_action, + cmd_oid, data_buf, + cmd_ptr); + break; + } } else { ret = mwifiex_cmd_host_cmd(priv, cmd_ptr, data_buf); cmd_node->cmd_flag |= CMD_F_HOSTCMD; -- cgit v1.2.3