* [patch 1/5] d80211: Fix overflow when creating AVS header
[not found] <20061003181118.537800000@devicescape.com>
@ 2006-10-03 18:12 ` David Kimdon
2006-10-03 18:12 ` [patch 2/5] d80211: remove unused xr structure members, interface, etc David Kimdon
` (3 subsequent siblings)
4 siblings, 0 replies; 12+ messages in thread
From: David Kimdon @ 2006-10-03 18:12 UTC (permalink / raw)
To: netdev; +Cc: John W. Linville, Jiri Benc, David Kimdon
[-- Attachment #1: hosttime.patch --]
[-- Type: text/plain, Size: 1048 bytes --]
Fix overflow when converting timespec to microseconds. Without this patch you
can get an overflow during the multiplication which can result in a negative number.
hostime is define here:
4.4 hosttime
The hosttime field is set to the current value of the host maintained
clock variable when the frame is received.
(from http://www.locustworld.com/tracker/getfile/prism2drivers/doc/capturefrm.txt)
it is a u64.
Signed-off-by: David Kimdon <david.kimdon@devicescape.com>
Index: wireless-dev/net/d80211/ieee80211.c
===================================================================
--- wireless-dev.orig/net/d80211/ieee80211.c
+++ wireless-dev/net/d80211/ieee80211.c
@@ -2573,7 +2573,7 @@ ieee80211_rx_mgmt(struct net_device *dev
struct ieee80211_rate *rate;
jiffies_to_timespec(status->hosttime, &ts);
- fi->hosttime = cpu_to_be64(ts.tv_sec * 1000000 +
+ fi->hosttime = cpu_to_be64((u64) ts.tv_sec * 1000000 +
ts.tv_nsec / 1000);
fi->mactime = cpu_to_be64(status->mactime);
switch (status->phymode) {
--
^ permalink raw reply [flat|nested] 12+ messages in thread
* [patch 2/5] d80211: remove unused xr structure members, interface, etc.
[not found] <20061003181118.537800000@devicescape.com>
2006-10-03 18:12 ` [patch 1/5] d80211: Fix overflow when creating AVS header David Kimdon
@ 2006-10-03 18:12 ` David Kimdon
2006-10-03 18:12 ` [patch 3/5] d80211: remove rate limit code David Kimdon
` (2 subsequent siblings)
4 siblings, 0 replies; 12+ messages in thread
From: David Kimdon @ 2006-10-03 18:12 UTC (permalink / raw)
To: netdev; +Cc: John W. Linville, Jiri Benc, Elliot Schwartz
[-- Attachment #1: xr-removal.patch --]
[-- Type: text/plain, Size: 4871 bytes --]
From: Elliot Schwartz <elliot.schwartz@devicescape.com>
This is all unused.
Signed-off-by: Elliot Schwartz <elliot.schwartz@devicescape.com>
Index: wireless-dev/include/net/d80211.h
===================================================================
--- wireless-dev.orig/include/net/d80211.h
+++ wireless-dev/include/net/d80211.h
@@ -82,7 +82,6 @@ struct ieee80211_hw_modes {
struct ieee80211_channel *channels;
int num_rates;
struct ieee80211_rate *rates;
- int xr_end; /* only used with Atheros XR */
};
struct ieee80211_tx_queue_params {
@@ -166,8 +165,6 @@ struct ieee80211_tx_control {
* transmission */
unsigned int fast_frame:1;
- unsigned int atheros_xr:1; /* only used with Atheros XR */
-
unsigned int power_level:8; /* per-packet transmit power level, in dBm
*/
unsigned int antenna_sel:4; /* 0 = default/diversity,
@@ -193,7 +190,6 @@ struct ieee80211_tx_control {
#define RX_FLAG_MMIC_ERROR 0x1
#define RX_FLAG_DECRYPTED 0x2
-#define RX_FLAG_XR_DOUBLE_CHIRP 0x4
/* Receive status. The low-level driver should provide this information
* (the subset supported by hardware) to the 802.11 code with each received
@@ -276,8 +272,6 @@ struct ieee80211_conf {
int atheros_super_ag_turbo_g;
int atheros_super_ag_turbo_prime;
- int atheros_xr;
-
/* Following five fields are used for IEEE 802.11H */
unsigned int radar_detect;
unsigned int spect_mgmt;
@@ -679,9 +673,6 @@ struct ieee80211_hw {
* needed only for IBSS mode and the result of this function is used to
* determine whether to reply to Probe Requests. */
int (*tx_last_beacon)(struct net_device *dev);
-
- /* Optional handler for XR-in-use notification. */
- int (*atheros_xr_in_use)(struct net_device *dev, int in_use);
};
/* Allocate a new hardware device. This must be called once for each
Index: wireless-dev/include/net/d80211_mgmt.h
===================================================================
--- wireless-dev.orig/include/net/d80211_mgmt.h
+++ wireless-dev/include/net/d80211_mgmt.h
@@ -220,8 +220,4 @@ enum ieee80211_eid {
WLAN_EID_QOS_PARAMETER = 222
};
-
-
-#define ATHEROS_INFO_USEXR BIT(3)
-
#endif /* D802_11_MGMT_H */
Index: wireless-dev/include/net/d80211_shared.h
===================================================================
--- wireless-dev.orig/include/net/d80211_shared.h
+++ wireless-dev/include/net/d80211_shared.h
@@ -21,8 +21,7 @@ enum {
MODE_ATHEROS_TURBOG = 4 /* Atheros Turbo mode (2x.11g at 2.4 GHz) */,
MODE_ATHEROS_PRIME = 5 /* Atheros Dynamic Turbo mode */,
MODE_ATHEROS_PRIMEG = 6 /* Atheros Dynamic Turbo mode G */,
- MODE_ATHEROS_XR = 7 /* Atheros XR mode */,
- NUM_IEEE80211_MODES = 8
+ NUM_IEEE80211_MODES = 7
};
#define IEEE80211_CHAN_W_SCAN 0x00000001
@@ -40,7 +39,6 @@ enum {
#define IEEE80211_RATE_CCK 0x00000040
#define IEEE80211_RATE_TURBO 0x00000080
#define IEEE80211_RATE_MANDATORY 0x00000100
-#define IEEE80211_RATE_XR 0x00000200
#define IEEE80211_RATE_CCK_2 (IEEE80211_RATE_CCK | IEEE80211_RATE_PREAMBLE2)
#define IEEE80211_RATE_MODULATION(f) \
Index: wireless-dev/net/d80211/hostapd_ioctl.h
===================================================================
--- wireless-dev.orig/net/d80211/hostapd_ioctl.h
+++ wireless-dev/net/d80211/hostapd_ioctl.h
@@ -186,7 +186,6 @@ struct prism2_hostapd_param {
* IEEE80211_ATHEROS_SUPER_AG
*/
u8 atheros_super_ag;
- u8 atheros_xr_mode;
u8 wds_flags;
#define IEEE80211_STA_DYNAMIC_ENC BIT(0)
u8 enc_flags;
Index: wireless-dev/net/d80211/ieee80211_sysfs_sta.c
===================================================================
--- wireless-dev.orig/net/d80211/ieee80211_sysfs_sta.c
+++ wireless-dev/net/d80211/ieee80211_sysfs_sta.c
@@ -77,7 +77,7 @@ STA_ATTR(wep_weak_iv_count, wep_weak_iv_
static ssize_t show_sta_flags(const struct sta_info *sta, char *buf)
{
- return sprintf(buf, "%s%s%s%s%s%s%s%s%s%s",
+ return sprintf(buf, "%s%s%s%s%s%s%s%s%s",
sta->flags & WLAN_STA_AUTH ? "AUTH\n" : "",
sta->flags & WLAN_STA_ASSOC ? "ASSOC\n" : "",
sta->flags & WLAN_STA_PS ? "PS\n" : "",
@@ -87,8 +87,7 @@ static ssize_t show_sta_flags(const stru
sta->flags & WLAN_STA_SHORT_PREAMBLE ?
"SHORT PREAMBLE\n" : "",
sta->flags & WLAN_STA_WME ? "WME\n" : "",
- sta->flags & WLAN_STA_WDS ? "WDS\n" : "",
- sta->flags & WLAN_STA_XR ? "XR\n" : "");
+ sta->flags & WLAN_STA_WDS ? "WDS\n" : "");
}
__STA_ATTR(flags);
Index: wireless-dev/net/d80211/sta_info.h
===================================================================
--- wireless-dev.orig/net/d80211/sta_info.h
+++ wireless-dev/net/d80211/sta_info.h
@@ -26,7 +26,6 @@
*/
#define WLAN_STA_SHORT_PREAMBLE BIT(7)
#define WLAN_STA_WME BIT(9)
-#define WLAN_STA_XR BIT(26)
#define WLAN_STA_WDS BIT(27)
--
^ permalink raw reply [flat|nested] 12+ messages in thread
* [patch 3/5] d80211: remove rate limit code
[not found] <20061003181118.537800000@devicescape.com>
2006-10-03 18:12 ` [patch 1/5] d80211: Fix overflow when creating AVS header David Kimdon
2006-10-03 18:12 ` [patch 2/5] d80211: remove unused xr structure members, interface, etc David Kimdon
@ 2006-10-03 18:12 ` David Kimdon
2006-10-03 18:12 ` [patch 4/5] d80211: retain PS frames for at least STA listen interval David Kimdon
2006-10-03 18:12 ` [patch 5/5] d80211: allow wireless vlan interface to have same MAC an AP interface David Kimdon
4 siblings, 0 replies; 12+ messages in thread
From: David Kimdon @ 2006-10-03 18:12 UTC (permalink / raw)
To: netdev; +Cc: John W. Linville, Jiri Benc, Elliot Schwartz
[-- Attachment #1: rate-limit-removal.patch --]
[-- Type: text/plain, Size: 6896 bytes --]
From: Elliot Schwartz <elliot.schwartz@devicescape.com>
Remove unused and more or less pointless rate limiting code. This
would have just dropped multicast frames arbitrarily when the limit is
reached which is quite useless and does not really belong to 802.11
code.
Signed-off-by: Elliot Schwartz <elliot.schwartz@devicescape.com>
Index: wireless-dev/net/d80211/hostapd_ioctl.h
===================================================================
--- wireless-dev.orig/net/d80211/hostapd_ioctl.h
+++ wireless-dev/net/d80211/hostapd_ioctl.h
@@ -58,8 +58,8 @@ enum {
PRISM2_PARAM_CTS_PROTECT_ERP_FRAMES = 1001,
PRISM2_PARAM_DROP_UNENCRYPTED = 1002,
PRISM2_PARAM_PREAMBLE = 1003,
- PRISM2_PARAM_RATE_LIMIT = 1004,
- PRISM2_PARAM_RATE_LIMIT_BURST = 1005,
+ PRISM2_PARAM_RATE_LIMIT = 1004, /* no longer used */
+ PRISM2_PARAM_RATE_LIMIT_BURST = 1005, /* no longer used */
PRISM2_PARAM_SHORT_SLOT_TIME = 1006,
PRISM2_PARAM_TEST_MODE = 1007,
PRISM2_PARAM_NEXT_MODE = 1008,
Index: wireless-dev/net/d80211/ieee80211.c
===================================================================
--- wireless-dev.orig/net/d80211/ieee80211.c
+++ wireless-dev/net/d80211/ieee80211.c
@@ -843,38 +843,6 @@ ieee80211_tx_h_misc(struct ieee80211_txr
}
-static void ieee80211_rate_limit(unsigned long data)
-{
- struct ieee80211_local *local = (struct ieee80211_local *) data;
-
- if (local->rate_limit) {
- local->rate_limit_bucket += local->rate_limit;
- if (local->rate_limit_bucket > local->rate_limit_burst)
- local->rate_limit_bucket = local->rate_limit_burst;
- local->rate_limit_timer.expires = jiffies + HZ;
- add_timer(&local->rate_limit_timer);
- }
-}
-
-
-static ieee80211_txrx_result
-ieee80211_tx_h_rate_limit(struct ieee80211_txrx_data *tx)
-{
-
- if (likely(!tx->local->rate_limit || tx->u.tx.unicast))
- return TXRX_CONTINUE;
-
- /* rate limit */
- if (tx->local->rate_limit_bucket) {
- tx->local->rate_limit_bucket--;
- return TXRX_CONTINUE;
- }
-
- I802_DEBUG_INC(tx->local->tx_handlers_drop_rate_limit);
- return TXRX_DROP;
-}
-
-
static ieee80211_txrx_result
ieee80211_tx_h_check_assoc(struct ieee80211_txrx_data *tx)
{
@@ -4206,7 +4174,6 @@ static ieee80211_rx_handler ieee80211_rx
static ieee80211_tx_handler ieee80211_tx_handlers[] =
{
- ieee80211_tx_h_rate_limit,
ieee80211_tx_h_check_assoc,
ieee80211_tx_h_ps_buf,
ieee80211_tx_h_select_key,
@@ -4369,9 +4336,6 @@ struct net_device *ieee80211_alloc_hw(si
init_timer(&local->scan.timer); /* clear it out */
spin_lock_init(&local->generic_lock);
- init_timer(&local->rate_limit_timer);
- local->rate_limit_timer.function = ieee80211_rate_limit;
- local->rate_limit_timer.data = (unsigned long) local;
init_timer(&local->stat_timer);
local->stat_timer.function = ieee80211_stat_refresh;
local->stat_timer.data = (unsigned long) local;
@@ -4582,8 +4546,6 @@ void ieee80211_unregister_hw(struct net_
}
rtnl_unlock();
- if (local->rate_limit)
- del_timer_sync(&local->rate_limit_timer);
if (local->stat_time)
del_timer_sync(&local->stat_timer);
if (local->scan_work.data) {
Index: wireless-dev/net/d80211/ieee80211_i.h
===================================================================
--- wireless-dev.orig/net/d80211/ieee80211_i.h
+++ wireless-dev/net/d80211/ieee80211_i.h
@@ -470,10 +470,6 @@ struct ieee80211_local {
u32 stat_time;
struct timer_list stat_timer;
- struct timer_list rate_limit_timer;
- u32 rate_limit;
- u32 rate_limit_burst;
- u32 rate_limit_bucket;
struct proc_dir_entry *proc, *proc_sta, *proc_iface;
struct work_struct sta_proc_add;
@@ -493,7 +489,6 @@ struct ieee80211_local {
unsigned int tx_handlers_drop_unencrypted;
unsigned int tx_handlers_drop_fragment;
unsigned int tx_handlers_drop_wep;
- unsigned int tx_handlers_drop_rate_limit;
unsigned int tx_handlers_drop_not_assoc;
unsigned int tx_handlers_drop_unauth_port;
unsigned int rx_handlers_drop;
Index: wireless-dev/net/d80211/ieee80211_ioctl.c
===================================================================
--- wireless-dev.orig/net/d80211/ieee80211_ioctl.c
+++ wireless-dev/net/d80211/ieee80211_ioctl.c
@@ -2405,25 +2405,6 @@ static int ieee80211_ioctl_prism2_param(
local->short_preamble = value;
break;
- case PRISM2_PARAM_RATE_LIMIT_BURST:
- local->rate_limit_burst = value;
- local->rate_limit_bucket = value;
- break;
-
- case PRISM2_PARAM_RATE_LIMIT:
- /* number of packets (tokens) allowed per second */
- if (!local->rate_limit && value) {
- if (!local->rate_limit_burst) local->rate_limit_burst =
- value;
- local->rate_limit_bucket = local->rate_limit_burst;
- local->rate_limit_timer.expires = jiffies + HZ;
- add_timer(&local->rate_limit_timer);
- } else if (local->rate_limit && !value) {
- del_timer_sync(&local->rate_limit_timer);
- }
- local->rate_limit = value;
- break;
-
case PRISM2_PARAM_STAT_TIME:
if (!local->stat_time && value) {
local->stat_timer.expires = jiffies + HZ * value / 100;
@@ -2656,14 +2637,6 @@ static int ieee80211_ioctl_get_prism2_pa
*param = local->short_preamble;
break;
- case PRISM2_PARAM_RATE_LIMIT_BURST:
- *param = local->rate_limit_burst;
- break;
-
- case PRISM2_PARAM_RATE_LIMIT:
- *param = local->rate_limit;
- break;
-
case PRISM2_PARAM_STAT_TIME:
*param = local->stat_time;
break;
Index: wireless-dev/net/d80211/ieee80211_sysfs.c
===================================================================
--- wireless-dev.orig/net/d80211/ieee80211_sysfs.c
+++ wireless-dev/net/d80211/ieee80211_sysfs.c
@@ -241,7 +241,6 @@ IEEE80211_LOCAL_ATTR(tx_handlers_queued,
IEEE80211_LOCAL_ATTR(tx_handlers_drop_unencrypted, tx_handlers_drop_unencrypted, "%u");
IEEE80211_LOCAL_ATTR(tx_handlers_drop_fragment, tx_handlers_drop_fragment, "%u");
IEEE80211_LOCAL_ATTR(tx_handlers_drop_wep, tx_handlers_drop_wep, "%u");
-IEEE80211_LOCAL_ATTR(tx_handlers_drop_rate_limit, tx_handlers_drop_rate_limit, "%u");
IEEE80211_LOCAL_ATTR(tx_handlers_drop_not_assoc, tx_handlers_drop_not_assoc, "%u");
IEEE80211_LOCAL_ATTR(tx_handlers_drop_unauth_port, tx_handlers_drop_unauth_port, "%u");
IEEE80211_LOCAL_ATTR(rx_handlers_drop, rx_handlers_drop, "%u");
@@ -352,7 +351,6 @@ static struct attribute *ieee80211_stats
&class_device_attr_tx_handlers_drop_unencrypted.attr,
&class_device_attr_tx_handlers_drop_fragment.attr,
&class_device_attr_tx_handlers_drop_wep.attr,
- &class_device_attr_tx_handlers_drop_rate_limit.attr,
&class_device_attr_tx_handlers_drop_not_assoc.attr,
&class_device_attr_tx_handlers_drop_unauth_port.attr,
&class_device_attr_rx_handlers_drop.attr,
--
^ permalink raw reply [flat|nested] 12+ messages in thread
* [patch 4/5] d80211: retain PS frames for at least STA listen interval
[not found] <20061003181118.537800000@devicescape.com>
` (2 preceding siblings ...)
2006-10-03 18:12 ` [patch 3/5] d80211: remove rate limit code David Kimdon
@ 2006-10-03 18:12 ` David Kimdon
2006-10-03 18:12 ` [patch 5/5] d80211: allow wireless vlan interface to have same MAC an AP interface David Kimdon
4 siblings, 0 replies; 12+ messages in thread
From: David Kimdon @ 2006-10-03 18:12 UTC (permalink / raw)
To: netdev; +Cc: John W. Linville, Jiri Benc, Jouni Malinen
[-- Attachment #1: listen-interval.patch --]
[-- Type: text/plain, Size: 3858 bytes --]
From: Jouni Malinen <jkm@devicescape.com>
Start using 2 * listen_int * beacon_int as a timeout for PS buffered
unicast frames if that is longer than 10 seconds. Previously, we used
fixed 10 second limit regardless of the listen interval.
This fixes power saving for STAs that request very long listen
interval (over 10 seconds).
This was reported by UNH IOL 802.11 AP Base MAC Test Suite v2.4
Test #1.3.2 Part e.
While we are at it, remove the station from the TIM when the PS buffer is
empty.
Signed-off-by: Jouni Malinen <jkm@devicescape.com>
Index: wireless-dev/net/d80211/hostapd_ioctl.h
===================================================================
--- wireless-dev.orig/net/d80211/hostapd_ioctl.h
+++ wireless-dev/net/d80211/hostapd_ioctl.h
@@ -189,6 +189,7 @@ struct prism2_hostapd_param {
u8 wds_flags;
#define IEEE80211_STA_DYNAMIC_ENC BIT(0)
u8 enc_flags;
+ u16 listen_interval;
} add_sta;
struct {
u32 inactive_msec;
Index: wireless-dev/net/d80211/ieee80211_ioctl.c
===================================================================
--- wireless-dev.orig/net/d80211/ieee80211_ioctl.c
+++ wireless-dev/net/d80211/ieee80211_ioctl.c
@@ -296,6 +296,7 @@ static int ieee80211_ioctl_add_sta(struc
sta->aid = param->u.add_sta.aid;
if (sta->aid > IEEE80211_MAX_AID)
sta->aid = 0;
+ sta->listen_interval = param->u.add_sta.listen_interval;
rates = 0;
for (i = 0; i < sizeof(param->u.add_sta.supp_rates); i++) {
Index: wireless-dev/net/d80211/sta_info.c
===================================================================
--- wireless-dev.orig/net/d80211/sta_info.c
+++ wireless-dev/net/d80211/sta_info.c
@@ -269,18 +269,24 @@ void sta_info_free(struct sta_info *sta,
}
-static inline int sta_info_buffer_expired(struct sk_buff *skb)
+static inline int sta_info_buffer_expired(struct ieee80211_local *local,
+ struct sta_info *sta,
+ struct sk_buff *skb)
{
struct ieee80211_tx_packet_data *pkt_data;
+ int timeout;
+
if (!skb)
return 0;
- /* TODO: this could be improved by passing STA listen interval into
- * the kernel driver and expiring frames after 2 x listen_interval x
- * beacon interval */
-
pkt_data = (struct ieee80211_tx_packet_data *) skb->cb;
- return time_after(jiffies, pkt_data->jiffies + STA_TX_BUFFER_EXPIRE);
+
+ /* Timeout: (2 * listen_interval * beacon_int * 1024 / 1000000) sec */
+ timeout = (sta->listen_interval * local->conf.beacon_int * 32 /
+ 15625) * HZ;
+ if (timeout < STA_TX_BUFFER_EXPIRE)
+ timeout = STA_TX_BUFFER_EXPIRE;
+ return time_after(jiffies, pkt_data->jiffies + timeout);
}
@@ -296,9 +302,11 @@ static void sta_info_cleanup_expire_buff
for (;;) {
spin_lock_irqsave(&sta->ps_tx_buf.lock, flags);
skb = skb_peek(&sta->ps_tx_buf);
- if (sta_info_buffer_expired(skb))
+ if (sta_info_buffer_expired(local, sta, skb)) {
skb = __skb_dequeue(&sta->ps_tx_buf);
- else
+ if (skb_queue_empty(&sta->ps_tx_buf))
+ sta->flags &= ~WLAN_STA_TIM;
+ } else
skb = NULL;
spin_unlock_irqrestore(&sta->ps_tx_buf.lock, flags);
Index: wireless-dev/net/d80211/sta_info.h
===================================================================
--- wireless-dev.orig/net/d80211/sta_info.h
+++ wireless-dev/net/d80211/sta_info.h
@@ -107,6 +107,8 @@ struct sta_info {
#endif /* CONFIG_D80211_DEBUG_COUNTERS */
int vlan_id;
+
+ u16 listen_interval;
};
@@ -120,7 +122,8 @@ struct sta_info {
/* Maximum number of frames to buffer per power saving station */
#define STA_MAX_TX_BUFFER 128
-/* Buffered frame expiry time */
+/* Minimum buffered frame expiry time. If STA uses listen interval that is
+ * smaller than this value, the minimum value here is used instead. */
#define STA_TX_BUFFER_EXPIRE (10 * HZ)
/* How often station data is cleaned up (e.g., expiration of buffered frames)
--
^ permalink raw reply [flat|nested] 12+ messages in thread
* [patch 5/5] d80211: allow wireless vlan interface to have same MAC an AP interface
[not found] <20061003181118.537800000@devicescape.com>
` (3 preceding siblings ...)
2006-10-03 18:12 ` [patch 4/5] d80211: retain PS frames for at least STA listen interval David Kimdon
@ 2006-10-03 18:12 ` David Kimdon
2006-10-04 16:47 ` Jiri Benc
2006-10-08 21:32 ` Johannes Berg
4 siblings, 2 replies; 12+ messages in thread
From: David Kimdon @ 2006-10-03 18:12 UTC (permalink / raw)
To: netdev; +Cc: John W. Linville, Jiri Benc, David Kimdon
[-- Attachment #1: vlan-macaddr.patch --]
[-- Type: text/plain, Size: 1044 bytes --]
Wireless vlan interfaces need to have the same mac address as
AP interfaces. The STA must not see the change when it is bound to
a specific vlan, so the address of the vlan interface must be the same
as the address of the AP interface the station associated with.
Signed-off-by: David Kimdon <david.kimdon@devicescape.com>
Index: wireless-dev/net/d80211/ieee80211.c
===================================================================
--- wireless-dev.orig/net/d80211/ieee80211.c
+++ wireless-dev/net/d80211/ieee80211.c
@@ -2092,7 +2092,12 @@ static inline int identical_mac_addr_all
type2 == IEEE80211_IF_TYPE_WDS) ||
(type1 == IEEE80211_IF_TYPE_WDS &&
(type2 == IEEE80211_IF_TYPE_WDS ||
- type2 == IEEE80211_IF_TYPE_AP)));
+ type2 == IEEE80211_IF_TYPE_AP)) ||
+ (type1 == IEEE80211_IF_TYPE_AP &&
+ type2 == IEEE80211_IF_TYPE_VLAN) ||
+ (type1 == IEEE80211_IF_TYPE_VLAN &&
+ (type2 == IEEE80211_IF_TYPE_AP ||
+ type2 == IEEE80211_IF_TYPE_VLAN)));
}
static int ieee80211_master_open(struct net_device *dev)
--
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch 5/5] d80211: allow wireless vlan interface to have same MAC an AP interface
2006-10-03 18:12 ` [patch 5/5] d80211: allow wireless vlan interface to have same MAC an AP interface David Kimdon
@ 2006-10-04 16:47 ` Jiri Benc
2006-10-08 21:32 ` Johannes Berg
1 sibling, 0 replies; 12+ messages in thread
From: Jiri Benc @ 2006-10-04 16:47 UTC (permalink / raw)
To: David Kimdon; +Cc: netdev, John W. Linville
All patches have been applied to my tree, thanks!
Jiri
--
Jiri Benc
SUSE Labs
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch 5/5] d80211: allow wireless vlan interface to have same MAC an AP interface
2006-10-03 18:12 ` [patch 5/5] d80211: allow wireless vlan interface to have same MAC an AP interface David Kimdon
2006-10-04 16:47 ` Jiri Benc
@ 2006-10-08 21:32 ` Johannes Berg
2006-10-09 21:38 ` [patch 5/5] d80211: allow wireless vlan interface to have sameMAC " Jouni Malinen
1 sibling, 1 reply; 12+ messages in thread
From: Johannes Berg @ 2006-10-08 21:32 UTC (permalink / raw)
To: David Kimdon; +Cc: netdev, John W. Linville, Jiri Benc
[-- Attachment #1: Type: text/plain, Size: 891 bytes --]
On Tue, 2006-10-03 at 11:12 -0700, David Kimdon wrote:
> Wireless vlan interfaces need to have the same mac address as
> AP interfaces. The STA must not see the change when it is bound to
> a specific vlan, so the address of the vlan interface must be the same
> as the address of the AP interface the station associated with.
Hm. Now I finally understand the vlan interface type. Neat. How do you
bind stas to one vlan interface? Is it possible to do on the fly after
EAP or similar?
Anyway. Wouldn't it make more sense to not even allow setting a MAC
address different from all AP interfaces, i.e. require that the VLAN
interface have the same MAC as one of the AP interfaces that exist?
And then there probably should be a check that prohibits binding a sta
to a vlan interface that has a different MAC than the AP interface it
is/was on... or something.
johannes
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 828 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch 5/5] d80211: allow wireless vlan interface to have sameMAC an AP interface
2006-10-08 21:32 ` Johannes Berg
@ 2006-10-09 21:38 ` Jouni Malinen
2006-10-09 21:49 ` Johannes Berg
2006-10-10 10:50 ` Johannes Berg
0 siblings, 2 replies; 12+ messages in thread
From: Jouni Malinen @ 2006-10-09 21:38 UTC (permalink / raw)
To: Johannes Berg; +Cc: David Kimdon, netdev, John W. Linville, Jiri Benc
On Sun, Oct 08, 2006 at 11:32:08PM +0200, Johannes Berg wrote:
> Hm. Now I finally understand the vlan interface type. Neat. How do you
> bind stas to one vlan interface? Is it possible to do on the fly after
> EAP or similar?
Yes, I just merged in support for this (dynamic VLANs) into hostapd.
RADIUS Access-Accept is used select VLAN is being used and the STA is
bound at that point to another virtual interface, if needed.
> Anyway. Wouldn't it make more sense to not even allow setting a MAC
> address different from all AP interfaces, i.e. require that the VLAN
> interface have the same MAC as one of the AP interfaces that exist?
That would be fine, too, but maybe not necessary.
> And then there probably should be a check that prohibits binding a sta
> to a vlan interface that has a different MAC than the AP interface it
> is/was on... or something.
Well, that would probably be correct for most (all?) cases, but then
again, I would probably not bother with this level of validation in
kernel. Whatever is taking care of binding the STA in user space (e.g.,
hostapd) can do the validation.
--
Jouni Malinen PGP id EFC895FA
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch 5/5] d80211: allow wireless vlan interface to have sameMAC an AP interface
2006-10-09 21:38 ` [patch 5/5] d80211: allow wireless vlan interface to have sameMAC " Jouni Malinen
@ 2006-10-09 21:49 ` Johannes Berg
2006-10-10 10:50 ` Johannes Berg
1 sibling, 0 replies; 12+ messages in thread
From: Johannes Berg @ 2006-10-09 21:49 UTC (permalink / raw)
To: Jouni Malinen; +Cc: David Kimdon, netdev, John W. Linville, Jiri Benc
[-- Attachment #1: Type: text/plain, Size: 730 bytes --]
On Mon, 2006-10-09 at 14:38 -0700, Jouni Malinen wrote:
> Yes, I just merged in support for this (dynamic VLANs) into hostapd.
> RADIUS Access-Accept is used select VLAN is being used and the STA is
> bound at that point to another virtual interface, if needed.
Cool.
> Well, that would probably be correct for most (all?) cases, but then
> again, I would probably not bother with this level of validation in
> kernel. Whatever is taking care of binding the STA in user space (e.g.,
> hostapd) can do the validation.
Yeah, I guess it's always possible to mess with STAs from the hostapd
since, well, it's the AP :)
[but this also means that I understood the point, so thanks for your
reply :) ]
johannes
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 828 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch 5/5] d80211: allow wireless vlan interface to have sameMAC an AP interface
2006-10-09 21:38 ` [patch 5/5] d80211: allow wireless vlan interface to have sameMAC " Jouni Malinen
2006-10-09 21:49 ` Johannes Berg
@ 2006-10-10 10:50 ` Johannes Berg
2006-10-10 13:42 ` [patch 5/5] d80211: allow wireless vlan interface to havesameMAC " David Kimdon
1 sibling, 1 reply; 12+ messages in thread
From: Johannes Berg @ 2006-10-10 10:50 UTC (permalink / raw)
To: Jouni Malinen; +Cc: David Kimdon, netdev, John W. Linville, Jiri Benc
On Mon, 2006-10-09 at 14:38 -0700, Jouni Malinen wrote:
> Yes, I just merged in support for this (dynamic VLANs) into hostapd.
> RADIUS Access-Accept is used select VLAN is being used and the STA is
> bound at that point to another virtual interface, if needed.
Different question. How do broadcasts to a vlan interface work? Are they
rewritten to unicasts to all vlan stations? You obviously can't get
perfect separation anyway since it all travels over the shared medium
and stations can always sniff the packets, but ...
johannes
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch 5/5] d80211: allow wireless vlan interface to havesameMAC an AP interface
2006-10-10 10:50 ` Johannes Berg
@ 2006-10-10 13:42 ` David Kimdon
2006-10-10 13:47 ` Johannes Berg
0 siblings, 1 reply; 12+ messages in thread
From: David Kimdon @ 2006-10-10 13:42 UTC (permalink / raw)
To: Johannes Berg
Cc: Jouni Malinen, David Kimdon, netdev, John W. Linville, Jiri Benc
On Tue, Oct 10, 2006 at 12:50:27PM +0200, Johannes Berg wrote:
> On Mon, 2006-10-09 at 14:38 -0700, Jouni Malinen wrote:
>
> > Yes, I just merged in support for this (dynamic VLANs) into hostapd.
> > RADIUS Access-Accept is used select VLAN is being used and the STA is
> > bound at that point to another virtual interface, if needed.
>
> Different question. How do broadcasts to a vlan interface work? Are they
> rewritten to unicasts to all vlan stations?
no, still broadcasts, but in a typical deployment some for of encryption
is used. Each vlan has a unique broadcast key so stations on one vlan
cannot decrypt packets from another vlan.
-David
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch 5/5] d80211: allow wireless vlan interface to havesameMAC an AP interface
2006-10-10 13:42 ` [patch 5/5] d80211: allow wireless vlan interface to havesameMAC " David Kimdon
@ 2006-10-10 13:47 ` Johannes Berg
0 siblings, 0 replies; 12+ messages in thread
From: Johannes Berg @ 2006-10-10 13:47 UTC (permalink / raw)
To: David Kimdon; +Cc: Jouni Malinen, netdev, John W. Linville, Jiri Benc
On Tue, 2006-10-10 at 06:42 -0700, David Kimdon wrote:
> no, still broadcasts, but in a typical deployment some for of encryption
> is used. Each vlan has a unique broadcast key so stations on one vlan
> cannot decrypt packets from another vlan.
Oh ok, that makes sense. Thanks.
johannes
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2006-10-10 13:47 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20061003181118.537800000@devicescape.com>
2006-10-03 18:12 ` [patch 1/5] d80211: Fix overflow when creating AVS header David Kimdon
2006-10-03 18:12 ` [patch 2/5] d80211: remove unused xr structure members, interface, etc David Kimdon
2006-10-03 18:12 ` [patch 3/5] d80211: remove rate limit code David Kimdon
2006-10-03 18:12 ` [patch 4/5] d80211: retain PS frames for at least STA listen interval David Kimdon
2006-10-03 18:12 ` [patch 5/5] d80211: allow wireless vlan interface to have same MAC an AP interface David Kimdon
2006-10-04 16:47 ` Jiri Benc
2006-10-08 21:32 ` Johannes Berg
2006-10-09 21:38 ` [patch 5/5] d80211: allow wireless vlan interface to have sameMAC " Jouni Malinen
2006-10-09 21:49 ` Johannes Berg
2006-10-10 10:50 ` Johannes Berg
2006-10-10 13:42 ` [patch 5/5] d80211: allow wireless vlan interface to havesameMAC " David Kimdon
2006-10-10 13:47 ` Johannes Berg
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).