summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xdrivers/staging/cw1200/ap.c3
-rw-r--r--drivers/staging/cw1200/sta.c3
2 files changed, 5 insertions, 1 deletions
diff --git a/drivers/staging/cw1200/ap.c b/drivers/staging/cw1200/ap.c
index 20a1d61690e..494403dd28d 100755
--- a/drivers/staging/cw1200/ap.c
+++ b/drivers/staging/cw1200/ap.c
@@ -698,7 +698,8 @@ static int cw1200_start_ap(struct cw1200_common *priv)
int ret;
struct ieee80211_bss_conf *conf = &priv->vif->bss_conf;
struct wsm_start start = {
- .mode = WSM_START_MODE_AP,
+ .mode = priv->vif->p2p ?
+ WSM_START_MODE_P2P_GO : WSM_START_MODE_AP,
.band = (priv->channel->band == IEEE80211_BAND_5GHZ) ?
WSM_PHY_BAND_5G : WSM_PHY_BAND_2_4G,
.channelNumber = priv->channel->hw_value,
diff --git a/drivers/staging/cw1200/sta.c b/drivers/staging/cw1200/sta.c
index f6227833248..3da13d597ef 100644
--- a/drivers/staging/cw1200/sta.c
+++ b/drivers/staging/cw1200/sta.c
@@ -1114,6 +1114,9 @@ void cw1200_join_work(struct work_struct *work)
memcpy(&join.ssid[0], &ssidie[2], join.ssidLength);
}
+ if (priv->vif->p2p)
+ join.flags |= WSM_JOIN_FLAGS_P2P_GO;
+
wsm_flush_tx(priv);
WARN_ON(wsm_set_block_ack_policy(priv,