diff options
-rw-r--r-- | net/mac80211/debugfs.c | 35 | ||||
-rw-r--r-- | net/mac80211/ieee80211_i.h | 1 | ||||
-rw-r--r-- | net/mac80211/tx.c | 10 | ||||
-rw-r--r-- | net/mac80211/wme.c | 3 |
4 files changed, 2 insertions, 47 deletions
diff --git a/net/mac80211/debugfs.c b/net/mac80211/debugfs.c index 00cefcb493eb..90baea53e7c5 100644 --- a/net/mac80211/debugfs.c +++ b/net/mac80211/debugfs.c | |||
@@ -97,40 +97,6 @@ static const struct file_operations reset_ops = { | |||
97 | .llseek = noop_llseek, | 97 | .llseek = noop_llseek, |
98 | }; | 98 | }; |
99 | 99 | ||
100 | static ssize_t noack_read(struct file *file, char __user *user_buf, | ||
101 | size_t count, loff_t *ppos) | ||
102 | { | ||
103 | struct ieee80211_local *local = file->private_data; | ||
104 | |||
105 | return mac80211_format_buffer(user_buf, count, ppos, "%d\n", | ||
106 | local->wifi_wme_noack_test); | ||
107 | } | ||
108 | |||
109 | static ssize_t noack_write(struct file *file, | ||
110 | const char __user *user_buf, | ||
111 | size_t count, loff_t *ppos) | ||
112 | { | ||
113 | struct ieee80211_local *local = file->private_data; | ||
114 | char buf[10]; | ||
115 | size_t len; | ||
116 | |||
117 | len = min(count, sizeof(buf) - 1); | ||
118 | if (copy_from_user(buf, user_buf, len)) | ||
119 | return -EFAULT; | ||
120 | buf[len] = '\0'; | ||
121 | |||
122 | local->wifi_wme_noack_test = !!simple_strtoul(buf, NULL, 0); | ||
123 | |||
124 | return count; | ||
125 | } | ||
126 | |||
127 | static const struct file_operations noack_ops = { | ||
128 | .read = noack_read, | ||
129 | .write = noack_write, | ||
130 | .open = mac80211_open_file_generic, | ||
131 | .llseek = default_llseek, | ||
132 | }; | ||
133 | |||
134 | static ssize_t uapsd_queues_read(struct file *file, char __user *user_buf, | 100 | static ssize_t uapsd_queues_read(struct file *file, char __user *user_buf, |
135 | size_t count, loff_t *ppos) | 101 | size_t count, loff_t *ppos) |
136 | { | 102 | { |
@@ -398,7 +364,6 @@ void debugfs_hw_add(struct ieee80211_local *local) | |||
398 | DEBUGFS_ADD(wep_iv); | 364 | DEBUGFS_ADD(wep_iv); |
399 | DEBUGFS_ADD(queues); | 365 | DEBUGFS_ADD(queues); |
400 | DEBUGFS_ADD_MODE(reset, 0200); | 366 | DEBUGFS_ADD_MODE(reset, 0200); |
401 | DEBUGFS_ADD(noack); | ||
402 | DEBUGFS_ADD(uapsd_queues); | 367 | DEBUGFS_ADD(uapsd_queues); |
403 | DEBUGFS_ADD(uapsd_max_sp_len); | 368 | DEBUGFS_ADD(uapsd_max_sp_len); |
404 | DEBUGFS_ADD(channel_type); | 369 | DEBUGFS_ADD(channel_type); |
diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h index 762243e469df..b1aa2e172d1d 100644 --- a/net/mac80211/ieee80211_i.h +++ b/net/mac80211/ieee80211_i.h | |||
@@ -961,7 +961,6 @@ struct ieee80211_local { | |||
961 | int total_ps_buffered; /* total number of all buffered unicast and | 961 | int total_ps_buffered; /* total number of all buffered unicast and |
962 | * multicast packets for power saving stations | 962 | * multicast packets for power saving stations |
963 | */ | 963 | */ |
964 | int wifi_wme_noack_test; | ||
965 | unsigned int wmm_acm; /* bit field of ACM bits (BIT(802.1D tag)) */ | 964 | unsigned int wmm_acm; /* bit field of ACM bits (BIT(802.1D tag)) */ |
966 | 965 | ||
967 | /* | 966 | /* |
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c index 8d31933abe6a..205fdcb70fff 100644 --- a/net/mac80211/tx.c +++ b/net/mac80211/tx.c | |||
@@ -1173,16 +1173,8 @@ ieee80211_tx_prepare(struct ieee80211_sub_if_data *sdata, | |||
1173 | if (is_multicast_ether_addr(hdr->addr1)) { | 1173 | if (is_multicast_ether_addr(hdr->addr1)) { |
1174 | tx->flags &= ~IEEE80211_TX_UNICAST; | 1174 | tx->flags &= ~IEEE80211_TX_UNICAST; |
1175 | info->flags |= IEEE80211_TX_CTL_NO_ACK; | 1175 | info->flags |= IEEE80211_TX_CTL_NO_ACK; |
1176 | } else { | 1176 | } else |
1177 | tx->flags |= IEEE80211_TX_UNICAST; | 1177 | tx->flags |= IEEE80211_TX_UNICAST; |
1178 | if (unlikely(local->wifi_wme_noack_test)) | ||
1179 | info->flags |= IEEE80211_TX_CTL_NO_ACK; | ||
1180 | /* | ||
1181 | * Flags are initialized to 0. Hence, no need to | ||
1182 | * explicitly unset IEEE80211_TX_CTL_NO_ACK since | ||
1183 | * it might already be set for injected frames. | ||
1184 | */ | ||
1185 | } | ||
1186 | 1178 | ||
1187 | if (!(info->flags & IEEE80211_TX_CTL_DONTFRAG)) { | 1179 | if (!(info->flags & IEEE80211_TX_CTL_DONTFRAG)) { |
1188 | if (!(tx->flags & IEEE80211_TX_UNICAST) || | 1180 | if (!(tx->flags & IEEE80211_TX_UNICAST) || |
diff --git a/net/mac80211/wme.c b/net/mac80211/wme.c index 43327115b490..74b3d1008445 100644 --- a/net/mac80211/wme.c +++ b/net/mac80211/wme.c | |||
@@ -150,8 +150,7 @@ void ieee80211_set_qos_hdr(struct ieee80211_sub_if_data *sdata, | |||
150 | /* preserve EOSP bit */ | 150 | /* preserve EOSP bit */ |
151 | ack_policy = *p & IEEE80211_QOS_CTL_EOSP; | 151 | ack_policy = *p & IEEE80211_QOS_CTL_EOSP; |
152 | 152 | ||
153 | if (unlikely(sdata->local->wifi_wme_noack_test) || | 153 | if (is_multicast_ether_addr(hdr->addr1)) |
154 | is_multicast_ether_addr(hdr->addr1)) | ||
155 | ack_policy |= IEEE80211_QOS_CTL_ACK_POLICY_NOACK; | 154 | ack_policy |= IEEE80211_QOS_CTL_ACK_POLICY_NOACK; |
156 | /* qos header is 2 bytes */ | 155 | /* qos header is 2 bytes */ |
157 | *p++ = ack_policy | tid; | 156 | *p++ = ack_policy | tid; |