summaryrefslogtreecommitdiff
path: root/drivers/staging/cw1200/sta.c
diff options
context:
space:
mode:
authorDmitry Tarnyagin <dmitry.tarnyagin@stericsson.com>2011-05-03 22:25:16 +0200
committerRobert Marklund <robert.marklund@stericsson.com>2011-10-05 11:17:23 +0200
commit70d2c2696ccbf911533f52fb4a6c584caae51402 (patch)
tree3ed79b2a59f69e3c298e0b889a0bb88205d68f3d /drivers/staging/cw1200/sta.c
parentf30d6091c11504a5f962c15d815dda21edf85b19 (diff)
WLAN: CW1200: Support for HREF/HREFV60/Snowball.
1. Added support for HREF/HREFV60/Snowball platforms. 2. Configuration cleanup. Signed-off-by: Dmitry Tarnyagin <dmitry.tarnyagin@stericsson.com>
Diffstat (limited to 'drivers/staging/cw1200/sta.c')
-rw-r--r--drivers/staging/cw1200/sta.c36
1 files changed, 18 insertions, 18 deletions
diff --git a/drivers/staging/cw1200/sta.c b/drivers/staging/cw1200/sta.c
index 0ae58e7bc02..9a99f032d3f 100644
--- a/drivers/staging/cw1200/sta.c
+++ b/drivers/staging/cw1200/sta.c
@@ -18,7 +18,7 @@
#include "fwio.h"
#include "bh.h"
-#ifdef CW1200_DEBUG_ENABLE_STA_LOGS
+#if defined(CONFIG_CW1200_STA_DEBUG)
#define sta_printk(...) printk(__VA_ARGS__)
#else
#define sta_printk(...)
@@ -107,9 +107,9 @@ void cw1200_stop(struct ieee80211_hw *dev)
cancel_delayed_work_sync(&priv->join_timeout);
cancel_delayed_work_sync(&priv->bss_loss_work);
cancel_delayed_work_sync(&priv->connection_loss_work);
-#ifdef CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE
+#if defined(CONFIG_CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE)
cancel_delayed_work_sync(&priv->keep_alive_work);
-#endif
+#endif /* CONFIG_CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE */
switch (priv->join_status) {
case CW1200_JOIN_STATUS_STA:
queue_work(priv->workqueue, &priv->unjoin_work);
@@ -728,9 +728,9 @@ void cw1200_bss_loss_work(struct work_struct *work)
sta_printk(KERN_DEBUG "[CQM] Beacon loss.\n");
if (timeout <= 0)
timeout = 0;
-#ifdef USE_STE_EXTENSIONS
+#if defined(CONFIG_CW1200_USE_STE_EXTENSIONS)
ieee80211_cqm_beacon_miss_notify(priv->vif, GFP_KERNEL);
-#endif
+#endif /* CONFIG_CW1200_USE_STE_EXTENSIONS */
} else {
timeout = 0;
}
@@ -750,7 +750,7 @@ void cw1200_connection_loss_work(struct work_struct *work)
ieee80211_connection_loss(priv->vif);
}
-#ifdef CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE
+#if defined(CONFIG_CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE)
void cw1200_keep_alive_work(struct work_struct *work)
{
struct cw1200_common *priv =
@@ -770,18 +770,18 @@ void cw1200_keep_alive_work(struct work_struct *work)
queue_delayed_work(priv->workqueue,
&priv->keep_alive_work, tmo);
}
-#endif
+#endif /* CONFIG_CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE */
void cw1200_tx_failure_work(struct work_struct *work)
{
struct cw1200_common *priv =
container_of(work, struct cw1200_common, tx_failure_work);
sta_printk(KERN_DEBUG "[CQM] Reporting TX failure.\n");
-#ifdef USE_STE_EXTENSIONS
+#if defined(CONFIG_CW1200_USE_STE_EXTENSIONS)
ieee80211_cqm_tx_fail_notify(priv->vif, GFP_KERNEL);
-#else
+#else /* CONFIG_CW1200_USE_STE_EXTENSIONS */
(void)priv;
-#endif
+#endif /* CONFIG_CW1200_USE_STE_EXTENSIONS */
}
/* ******************************************************************** */
@@ -944,12 +944,12 @@ void cw1200_join_work(struct work_struct *work)
* if necessary. */
WARN_ON(wsm_set_block_ack_policy(priv, 0x00, 0x3F));
-#ifdef CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE
+#if defined(CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE)
priv->last_activity_time = jiffies;
/* Queue keep-alive ping avery 30 sec. */
queue_delayed_work(priv->workqueue,
&priv->keep_alive_work, 30 * HZ);
-#endif
+#endif /* CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE */
/* Queue unjoin if not associated in 3 sec. */
queue_delayed_work(priv->workqueue,
&priv->join_timeout, 3 * HZ);
@@ -960,14 +960,14 @@ void cw1200_join_work(struct work_struct *work)
cw1200_queue_remove(&priv->tx_queue[queueId],
priv, __le32_to_cpu(wsm->packetID));
cancel_delayed_work_sync(&priv->join_timeout);
-#ifdef CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE
+#if defined(CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE)
cancel_delayed_work_sync(&priv->keep_alive_work);
-#endif
+#endif /* CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE */
} else {
WARN_ON(cw1200_upload_keys(priv));
-#ifndef CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE
+#if !defined(CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE)
WARN_ON(wsm_keep_alive_period(priv, 30 /* sec */));
-#endif
+#endif /* CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE */
cw1200_queue_requeue(&priv->tx_queue[queueId],
__le32_to_cpu(wsm->packetID));
}
@@ -1009,9 +1009,9 @@ void cw1200_unjoin_work(struct work_struct *work)
cw1200_free_event_queue(priv);
cancel_work_sync(&priv->event_handler);
cancel_delayed_work_sync(&priv->connection_loss_work);
-#ifdef CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE
+#if defined(CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE)
cancel_delayed_work_sync(&priv->keep_alive_work);
-#endif
+#endif /* CW1200_FIRMWARE_DOES_NOT_SUPPORT_KEEPALIVE */
sta_printk(KERN_DEBUG "[STA] Unjoin.\n");
}
mutex_unlock(&priv->conf_mutex);