aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/work.c
diff options
context:
space:
mode:
authorKalle Valo <kalle.valo@nokia.com>2009-12-30 07:42:20 -0500
committerJohn W. Linville <linville@tuxdriver.com>2010-01-05 17:13:14 -0500
commit1990ca6113399be9249433d5ab377a2a444f1dd8 (patch)
treec671dbe0ac45522646a7c5a61fc2a5e6d7d3db98 /net/mac80211/work.c
parent29401f6630c02ce996561bf2667d84ecdfacb823 (diff)
mac80211: fix a warning related to pointer conversion to u64 cookie
On a 32 bit system (in this case an omap 3430 system) gcc warned about pointer conversion: net/mac80211/work.c: In function 'ieee80211_remain_on_channel_timeout': net/mac80211/work.c:534: warning: cast from pointer to integer of different size net/mac80211/work.c: In function 'ieee80211_remain_done': net/mac80211/work.c:1030: warning: cast from pointer to integer of different size net/mac80211/work.c: In function 'ieee80211_wk_remain_on_channel': net/mac80211/work.c:1056: warning: cast from pointer to integer of different size net/mac80211/work.c: In function 'ieee80211_wk_cancel_remain_on_channel': net/mac80211/work.c:1072: warning: cast from pointer to integer of different size Fix it by casting the pointers to unsigned long instead. This makes the compiler happy again. Compile-tested only. Cc: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: Kalle Valo <kalle.valo@nokia.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/work.c')
-rw-r--r--net/mac80211/work.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/net/mac80211/work.c b/net/mac80211/work.c
index ea89ed70734d..5ba75990c9fd 100644
--- a/net/mac80211/work.c
+++ b/net/mac80211/work.c
@@ -531,9 +531,9 @@ ieee80211_remain_on_channel_timeout(struct ieee80211_work *wk)
531 wk->remain.started = true; 531 wk->remain.started = true;
532 wk->timeout = jiffies + msecs_to_jiffies(wk->remain.duration); 532 wk->timeout = jiffies + msecs_to_jiffies(wk->remain.duration);
533 533
534 cfg80211_ready_on_channel(wk->sdata->dev, (u64)wk, wk->chan, 534 cfg80211_ready_on_channel(wk->sdata->dev, (unsigned long) wk,
535 wk->chan_type, wk->remain.duration, 535 wk->chan, wk->chan_type,
536 GFP_KERNEL); 536 wk->remain.duration, GFP_KERNEL);
537 537
538 return WORK_ACT_NONE; 538 return WORK_ACT_NONE;
539 } 539 }
@@ -1027,7 +1027,7 @@ static enum work_done_result ieee80211_remain_done(struct ieee80211_work *wk,
1027 /* 1027 /*
1028 * We are done serving the remain-on-channel command. 1028 * We are done serving the remain-on-channel command.
1029 */ 1029 */
1030 cfg80211_remain_on_channel_expired(wk->sdata->dev, (u64)wk, 1030 cfg80211_remain_on_channel_expired(wk->sdata->dev, (unsigned long) wk,
1031 wk->chan, wk->chan_type, 1031 wk->chan, wk->chan_type,
1032 GFP_KERNEL); 1032 GFP_KERNEL);
1033 1033
@@ -1053,7 +1053,7 @@ int ieee80211_wk_remain_on_channel(struct ieee80211_sub_if_data *sdata,
1053 1053
1054 wk->remain.duration = duration; 1054 wk->remain.duration = duration;
1055 1055
1056 *cookie = (u64)wk; 1056 *cookie = (unsigned long) wk;
1057 1057
1058 ieee80211_add_work(wk); 1058 ieee80211_add_work(wk);
1059 1059
@@ -1069,7 +1069,7 @@ int ieee80211_wk_cancel_remain_on_channel(struct ieee80211_sub_if_data *sdata,
1069 1069
1070 mutex_lock(&local->work_mtx); 1070 mutex_lock(&local->work_mtx);
1071 list_for_each_entry_safe(wk, tmp, &local->work_list, list) { 1071 list_for_each_entry_safe(wk, tmp, &local->work_list, list) {
1072 if ((u64)wk == cookie) { 1072 if ((unsigned long) wk == cookie) {
1073 wk->timeout = jiffies; 1073 wk->timeout = jiffies;
1074 found = true; 1074 found = true;
1075 break; 1075 break;