Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
bug2833
cloud-kernel
提交
d61bdbf1
cloud-kernel
项目概览
bug2833
/
cloud-kernel
与 Fork 源项目一致
Fork自
openanolis / cloud-kernel
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
cloud-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
d61bdbf1
编写于
5月 28, 2013
作者:
J
John W. Linville
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'for-john' of
git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211
上级
86c157b3
ac20976d
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
47 addition
and
14 deletion
+47
-14
net/mac80211/iface.c
net/mac80211/iface.c
+37
-7
net/mac80211/mlme.c
net/mac80211/mlme.c
+6
-6
net/wireless/nl80211.c
net/wireless/nl80211.c
+1
-1
net/wireless/sme.c
net/wireless/sme.c
+3
-0
未找到文件。
net/mac80211/iface.c
浏览文件 @
d61bdbf1
...
...
@@ -159,9 +159,10 @@ static int ieee80211_change_mtu(struct net_device *dev, int new_mtu)
return
0
;
}
static
int
ieee80211_verify_mac
(
struct
ieee80211_
local
*
local
,
u8
*
addr
)
static
int
ieee80211_verify_mac
(
struct
ieee80211_
sub_if_data
*
sdata
,
u8
*
addr
)
{
struct
ieee80211_sub_if_data
*
sdata
;
struct
ieee80211_local
*
local
=
sdata
->
local
;
struct
ieee80211_sub_if_data
*
iter
;
u64
new
,
mask
,
tmp
;
u8
*
m
;
int
ret
=
0
;
...
...
@@ -181,11 +182,14 @@ static int ieee80211_verify_mac(struct ieee80211_local *local, u8 *addr)
mutex_lock
(
&
local
->
iflist_mtx
);
list_for_each_entry
(
sdata
,
&
local
->
interfaces
,
list
)
{
if
(
sdata
->
vif
.
type
==
NL80211_IFTYPE_MONITOR
)
list_for_each_entry
(
iter
,
&
local
->
interfaces
,
list
)
{
if
(
iter
==
sdata
)
continue
;
if
(
iter
->
vif
.
type
==
NL80211_IFTYPE_MONITOR
)
continue
;
m
=
sdata
->
vif
.
addr
;
m
=
iter
->
vif
.
addr
;
tmp
=
((
u64
)
m
[
0
]
<<
5
*
8
)
|
((
u64
)
m
[
1
]
<<
4
*
8
)
|
((
u64
)
m
[
2
]
<<
3
*
8
)
|
((
u64
)
m
[
3
]
<<
2
*
8
)
|
((
u64
)
m
[
4
]
<<
1
*
8
)
|
((
u64
)
m
[
5
]
<<
0
*
8
);
...
...
@@ -209,7 +213,7 @@ static int ieee80211_change_mac(struct net_device *dev, void *addr)
if
(
ieee80211_sdata_running
(
sdata
))
return
-
EBUSY
;
ret
=
ieee80211_verify_mac
(
sdata
->
local
,
sa
->
sa_data
);
ret
=
ieee80211_verify_mac
(
sdata
,
sa
->
sa_data
);
if
(
ret
)
return
ret
;
...
...
@@ -474,6 +478,9 @@ int ieee80211_do_open(struct wireless_dev *wdev, bool coming_up)
master
->
control_port_protocol
;
sdata
->
control_port_no_encrypt
=
master
->
control_port_no_encrypt
;
sdata
->
vif
.
cab_queue
=
master
->
vif
.
cab_queue
;
memcpy
(
sdata
->
vif
.
hw_queue
,
master
->
vif
.
hw_queue
,
sizeof
(
sdata
->
vif
.
hw_queue
));
break
;
}
case
NL80211_IFTYPE_AP
:
...
...
@@ -653,7 +660,11 @@ int ieee80211_do_open(struct wireless_dev *wdev, bool coming_up)
ieee80211_recalc_ps
(
local
,
-
1
);
if
(
dev
)
{
if
(
sdata
->
vif
.
type
==
NL80211_IFTYPE_MONITOR
||
sdata
->
vif
.
type
==
NL80211_IFTYPE_AP_VLAN
)
{
/* XXX: for AP_VLAN, actually track AP queues */
netif_tx_start_all_queues
(
dev
);
}
else
if
(
dev
)
{
unsigned
long
flags
;
int
n_acs
=
IEEE80211_NUM_ACS
;
int
ac
;
...
...
@@ -1479,7 +1490,17 @@ static void ieee80211_assign_perm_addr(struct ieee80211_local *local,
break
;
}
/*
* Pick address of existing interface in case user changed
* MAC address manually, default to perm_addr.
*/
m
=
local
->
hw
.
wiphy
->
perm_addr
;
list_for_each_entry
(
sdata
,
&
local
->
interfaces
,
list
)
{
if
(
sdata
->
vif
.
type
==
NL80211_IFTYPE_MONITOR
)
continue
;
m
=
sdata
->
vif
.
addr
;
break
;
}
start
=
((
u64
)
m
[
0
]
<<
5
*
8
)
|
((
u64
)
m
[
1
]
<<
4
*
8
)
|
((
u64
)
m
[
2
]
<<
3
*
8
)
|
((
u64
)
m
[
3
]
<<
2
*
8
)
|
((
u64
)
m
[
4
]
<<
1
*
8
)
|
((
u64
)
m
[
5
]
<<
0
*
8
);
...
...
@@ -1696,6 +1717,15 @@ void ieee80211_remove_interfaces(struct ieee80211_local *local)
ASSERT_RTNL
();
/*
* Close all AP_VLAN interfaces first, as otherwise they
* might be closed while the AP interface they belong to
* is closed, causing unregister_netdevice_many() to crash.
*/
list_for_each_entry
(
sdata
,
&
local
->
interfaces
,
list
)
if
(
sdata
->
vif
.
type
==
NL80211_IFTYPE_AP_VLAN
)
dev_close
(
sdata
->
dev
);
mutex_lock
(
&
local
->
iflist_mtx
);
list_for_each_entry_safe
(
sdata
,
tmp
,
&
local
->
interfaces
,
list
)
{
list_del
(
&
sdata
->
list
);
...
...
net/mac80211/mlme.c
浏览文件 @
d61bdbf1
...
...
@@ -3321,10 +3321,6 @@ static int ieee80211_probe_auth(struct ieee80211_sub_if_data *sdata)
if
(
WARN_ON_ONCE
(
!
auth_data
))
return
-
EINVAL
;
if
(
local
->
hw
.
flags
&
IEEE80211_HW_REPORTS_TX_ACK_STATUS
)
tx_flags
=
IEEE80211_TX_CTL_REQ_TX_STATUS
|
IEEE80211_TX_INTFL_MLME_CONN_TX
;
auth_data
->
tries
++
;
if
(
auth_data
->
tries
>
IEEE80211_AUTH_MAX_TRIES
)
{
...
...
@@ -3358,6 +3354,10 @@ static int ieee80211_probe_auth(struct ieee80211_sub_if_data *sdata)
auth_data
->
expected_transaction
=
trans
;
}
if
(
local
->
hw
.
flags
&
IEEE80211_HW_REPORTS_TX_ACK_STATUS
)
tx_flags
=
IEEE80211_TX_CTL_REQ_TX_STATUS
|
IEEE80211_TX_INTFL_MLME_CONN_TX
;
ieee80211_send_auth
(
sdata
,
trans
,
auth_data
->
algorithm
,
status
,
auth_data
->
data
,
auth_data
->
data_len
,
auth_data
->
bss
->
bssid
,
...
...
@@ -3381,12 +3381,12 @@ static int ieee80211_probe_auth(struct ieee80211_sub_if_data *sdata)
* will not answer to direct packet in unassociated state.
*/
ieee80211_send_probe_req
(
sdata
,
NULL
,
ssidie
+
2
,
ssidie
[
1
],
NULL
,
0
,
(
u32
)
-
1
,
true
,
tx_flags
,
NULL
,
0
,
(
u32
)
-
1
,
true
,
0
,
auth_data
->
bss
->
channel
,
false
);
rcu_read_unlock
();
}
if
(
!
(
local
->
hw
.
flags
&
IEEE80211_HW_REPORTS_TX_ACK_STATUS
)
)
{
if
(
tx_flags
==
0
)
{
auth_data
->
timeout
=
jiffies
+
IEEE80211_AUTH_TIMEOUT
;
ifmgd
->
auth_data
->
timeout_started
=
true
;
run_again
(
ifmgd
,
auth_data
->
timeout
);
...
...
net/wireless/nl80211.c
浏览文件 @
d61bdbf1
...
...
@@ -3411,7 +3411,7 @@ static int nl80211_send_station(struct sk_buff *msg, u32 portid, u32 seq,
(
u32
)
sinfo
->
rx_bytes
))
goto
nla_put_failure
;
if
((
sinfo
->
filled
&
(
STATION_INFO_TX_BYTES
|
NL80211_STA
_INFO_TX_BYTES64
))
&&
STATION
_INFO_TX_BYTES64
))
&&
nla_put_u32
(
msg
,
NL80211_STA_INFO_TX_BYTES
,
(
u32
)
sinfo
->
tx_bytes
))
goto
nla_put_failure
;
...
...
net/wireless/sme.c
浏览文件 @
d61bdbf1
...
...
@@ -231,6 +231,9 @@ void cfg80211_conn_work(struct work_struct *work)
mutex_lock
(
&
rdev
->
sched_scan_mtx
);
list_for_each_entry
(
wdev
,
&
rdev
->
wdev_list
,
list
)
{
if
(
!
wdev
->
netdev
)
continue
;
wdev_lock
(
wdev
);
if
(
!
netif_running
(
wdev
->
netdev
))
{
wdev_unlock
(
wdev
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录