@@ -1101,18 +1101,20 @@ ieee80211_copy_rnr_beacon(u8 *pos, struct cfg80211_rnr_elems *dst,
1101
1101
return offset ;
1102
1102
}
1103
1103
1104
- static int ieee80211_assign_beacon (struct ieee80211_sub_if_data * sdata ,
1105
- struct ieee80211_link_data * link ,
1106
- struct cfg80211_beacon_data * params ,
1107
- const struct ieee80211_csa_settings * csa ,
1108
- const struct ieee80211_color_change_settings * cca )
1104
+ static int
1105
+ ieee80211_assign_beacon (struct ieee80211_sub_if_data * sdata ,
1106
+ struct ieee80211_link_data * link ,
1107
+ struct cfg80211_beacon_data * params ,
1108
+ const struct ieee80211_csa_settings * csa ,
1109
+ const struct ieee80211_color_change_settings * cca ,
1110
+ u64 * changed )
1109
1111
{
1110
1112
struct cfg80211_mbssid_elems * mbssid = NULL ;
1111
1113
struct cfg80211_rnr_elems * rnr = NULL ;
1112
1114
struct beacon_data * new , * old ;
1113
1115
int new_head_len , new_tail_len ;
1114
1116
int size , err ;
1115
- u32 changed = BSS_CHANGED_BEACON ;
1117
+ u64 _changed = BSS_CHANGED_BEACON ;
1116
1118
struct ieee80211_bss_conf * link_conf = link -> conf ;
1117
1119
1118
1120
old = sdata_dereference (link -> u .ap .beacon , sdata );
@@ -1219,7 +1221,7 @@ static int ieee80211_assign_beacon(struct ieee80211_sub_if_data *sdata,
1219
1221
return err ;
1220
1222
}
1221
1223
if (err == 0 )
1222
- changed |= BSS_CHANGED_AP_PROBE_RESP ;
1224
+ _changed |= BSS_CHANGED_AP_PROBE_RESP ;
1223
1225
1224
1226
if (params -> ftm_responder != -1 ) {
1225
1227
link_conf -> ftm_responder = params -> ftm_responder ;
@@ -1235,7 +1237,7 @@ static int ieee80211_assign_beacon(struct ieee80211_sub_if_data *sdata,
1235
1237
return err ;
1236
1238
}
1237
1239
1238
- changed |= BSS_CHANGED_FTM_RESPONDER ;
1240
+ _changed |= BSS_CHANGED_FTM_RESPONDER ;
1239
1241
}
1240
1242
1241
1243
rcu_assign_pointer (link -> u .ap .beacon , new );
@@ -1244,7 +1246,8 @@ static int ieee80211_assign_beacon(struct ieee80211_sub_if_data *sdata,
1244
1246
if (old )
1245
1247
kfree_rcu (old , rcu_head );
1246
1248
1247
- return changed ;
1249
+ * changed |= _changed ;
1250
+ return 0 ;
1248
1251
}
1249
1252
1250
1253
static int ieee80211_start_ap (struct wiphy * wiphy , struct net_device * dev ,
@@ -1446,10 +1449,10 @@ static int ieee80211_start_ap(struct wiphy *wiphy, struct net_device *dev,
1446
1449
if (ieee80211_hw_check (& local -> hw , HAS_RATE_CONTROL ))
1447
1450
link_conf -> beacon_tx_rate = params -> beacon_rate ;
1448
1451
1449
- err = ieee80211_assign_beacon (sdata , link , & params -> beacon , NULL , NULL );
1452
+ err = ieee80211_assign_beacon (sdata , link , & params -> beacon , NULL , NULL ,
1453
+ & changed );
1450
1454
if (err < 0 )
1451
1455
goto error ;
1452
- changed |= err ;
1453
1456
1454
1457
if (params -> fils_discovery .max_interval ) {
1455
1458
err = ieee80211_set_fils_discovery (sdata ,
@@ -1506,6 +1509,7 @@ static int ieee80211_change_beacon(struct wiphy *wiphy, struct net_device *dev,
1506
1509
struct beacon_data * old ;
1507
1510
int err ;
1508
1511
struct ieee80211_bss_conf * link_conf ;
1512
+ u64 changed = 0 ;
1509
1513
1510
1514
sdata_assert_lock (sdata );
1511
1515
@@ -1525,17 +1529,18 @@ static int ieee80211_change_beacon(struct wiphy *wiphy, struct net_device *dev,
1525
1529
if (!old )
1526
1530
return - ENOENT ;
1527
1531
1528
- err = ieee80211_assign_beacon (sdata , link , params , NULL , NULL );
1532
+ err = ieee80211_assign_beacon (sdata , link , params , NULL , NULL ,
1533
+ & changed );
1529
1534
if (err < 0 )
1530
1535
return err ;
1531
1536
1532
1537
if (params -> he_bss_color_valid &&
1533
1538
params -> he_bss_color .enabled != link_conf -> he_bss_color .enabled ) {
1534
1539
link_conf -> he_bss_color .enabled = params -> he_bss_color .enabled ;
1535
- err |= BSS_CHANGED_HE_BSS_COLOR ;
1540
+ changed |= BSS_CHANGED_HE_BSS_COLOR ;
1536
1541
}
1537
1542
1538
- ieee80211_link_info_change_notify (sdata , link , err );
1543
+ ieee80211_link_info_change_notify (sdata , link , changed );
1539
1544
return 0 ;
1540
1545
}
1541
1546
@@ -1717,7 +1722,7 @@ static void sta_apply_mesh_params(struct ieee80211_local *local,
1717
1722
{
1718
1723
#ifdef CONFIG_MAC80211_MESH
1719
1724
struct ieee80211_sub_if_data * sdata = sta -> sdata ;
1720
- u32 changed = 0 ;
1725
+ u64 changed = 0 ;
1721
1726
1722
1727
if (params -> sta_modify_mask & STATION_PARAM_APPLY_PLINK_STATE ) {
1723
1728
switch (params -> plink_state ) {
@@ -2664,7 +2669,7 @@ static int ieee80211_change_bss(struct wiphy *wiphy,
2664
2669
struct ieee80211_sub_if_data * sdata = IEEE80211_DEV_TO_SUB_IF (dev );
2665
2670
struct ieee80211_link_data * link ;
2666
2671
struct ieee80211_supported_band * sband ;
2667
- u32 changed = 0 ;
2672
+ u64 changed = 0 ;
2668
2673
2669
2674
link = ieee80211_link_or_deflink (sdata , params -> link_id , true);
2670
2675
if (IS_ERR (link ))
@@ -3589,7 +3594,7 @@ void ieee80211_channel_switch_disconnect(struct ieee80211_vif *vif, bool block_t
3589
3594
EXPORT_SYMBOL (ieee80211_channel_switch_disconnect );
3590
3595
3591
3596
static int ieee80211_set_after_csa_beacon (struct ieee80211_sub_if_data * sdata ,
3592
- u32 * changed )
3597
+ u64 * changed )
3593
3598
{
3594
3599
int err ;
3595
3600
@@ -3600,25 +3605,22 @@ static int ieee80211_set_after_csa_beacon(struct ieee80211_sub_if_data *sdata,
3600
3605
3601
3606
err = ieee80211_assign_beacon (sdata , & sdata -> deflink ,
3602
3607
sdata -> deflink .u .ap .next_beacon ,
3603
- NULL , NULL );
3608
+ NULL , NULL , changed );
3604
3609
ieee80211_free_next_beacon (& sdata -> deflink );
3605
3610
3606
3611
if (err < 0 )
3607
3612
return err ;
3608
- * changed |= err ;
3609
3613
break ;
3610
3614
case NL80211_IFTYPE_ADHOC :
3611
- err = ieee80211_ibss_finish_csa (sdata );
3615
+ err = ieee80211_ibss_finish_csa (sdata , changed );
3612
3616
if (err < 0 )
3613
3617
return err ;
3614
- * changed |= err ;
3615
3618
break ;
3616
3619
#ifdef CONFIG_MAC80211_MESH
3617
3620
case NL80211_IFTYPE_MESH_POINT :
3618
- err = ieee80211_mesh_finish_csa (sdata );
3621
+ err = ieee80211_mesh_finish_csa (sdata , changed );
3619
3622
if (err < 0 )
3620
3623
return err ;
3621
- * changed |= err ;
3622
3624
break ;
3623
3625
#endif
3624
3626
default :
@@ -3632,7 +3634,7 @@ static int ieee80211_set_after_csa_beacon(struct ieee80211_sub_if_data *sdata,
3632
3634
static int __ieee80211_csa_finalize (struct ieee80211_sub_if_data * sdata )
3633
3635
{
3634
3636
struct ieee80211_local * local = sdata -> local ;
3635
- u32 changed = 0 ;
3637
+ u64 changed = 0 ;
3636
3638
int err ;
3637
3639
3638
3640
sdata_assert_lock (sdata );
@@ -3729,7 +3731,7 @@ void ieee80211_csa_finalize_work(struct work_struct *work)
3729
3731
3730
3732
static int ieee80211_set_csa_beacon (struct ieee80211_sub_if_data * sdata ,
3731
3733
struct cfg80211_csa_settings * params ,
3732
- u32 * changed )
3734
+ u64 * changed )
3733
3735
{
3734
3736
struct ieee80211_csa_settings csa = {};
3735
3737
int err ;
@@ -3776,12 +3778,11 @@ static int ieee80211_set_csa_beacon(struct ieee80211_sub_if_data *sdata,
3776
3778
3777
3779
err = ieee80211_assign_beacon (sdata , & sdata -> deflink ,
3778
3780
& params -> beacon_csa , & csa ,
3779
- NULL );
3781
+ NULL , changed );
3780
3782
if (err < 0 ) {
3781
3783
ieee80211_free_next_beacon (& sdata -> deflink );
3782
3784
return err ;
3783
3785
}
3784
- * changed |= err ;
3785
3786
3786
3787
break ;
3787
3788
case NL80211_IFTYPE_ADHOC :
@@ -3813,10 +3814,9 @@ static int ieee80211_set_csa_beacon(struct ieee80211_sub_if_data *sdata,
3813
3814
3814
3815
/* see comments in the NL80211_IFTYPE_AP block */
3815
3816
if (params -> count > 1 ) {
3816
- err = ieee80211_ibss_csa_beacon (sdata , params );
3817
+ err = ieee80211_ibss_csa_beacon (sdata , params , changed );
3817
3818
if (err < 0 )
3818
3819
return err ;
3819
- * changed |= err ;
3820
3820
}
3821
3821
3822
3822
ieee80211_send_action_csa (sdata , params );
@@ -3841,12 +3841,11 @@ static int ieee80211_set_csa_beacon(struct ieee80211_sub_if_data *sdata,
3841
3841
3842
3842
/* see comments in the NL80211_IFTYPE_AP block */
3843
3843
if (params -> count > 1 ) {
3844
- err = ieee80211_mesh_csa_beacon (sdata , params );
3844
+ err = ieee80211_mesh_csa_beacon (sdata , params , changed );
3845
3845
if (err < 0 ) {
3846
3846
ifmsh -> csa_role = IEEE80211_MESH_CSA_ROLE_NONE ;
3847
3847
return err ;
3848
3848
}
3849
- * changed |= err ;
3850
3849
}
3851
3850
3852
3851
if (ifmsh -> csa_role == IEEE80211_MESH_CSA_ROLE_INIT )
@@ -3880,7 +3879,7 @@ __ieee80211_channel_switch(struct wiphy *wiphy, struct net_device *dev,
3880
3879
struct ieee80211_channel_switch ch_switch ;
3881
3880
struct ieee80211_chanctx_conf * conf ;
3882
3881
struct ieee80211_chanctx * chanctx ;
3883
- u32 changed = 0 ;
3882
+ u64 changed = 0 ;
3884
3883
int err ;
3885
3884
3886
3885
sdata_assert_lock (sdata );
@@ -4613,7 +4612,7 @@ static int ieee80211_set_sar_specs(struct wiphy *wiphy,
4613
4612
4614
4613
static int
4615
4614
ieee80211_set_after_color_change_beacon (struct ieee80211_sub_if_data * sdata ,
4616
- u32 * changed )
4615
+ u64 * changed )
4617
4616
{
4618
4617
switch (sdata -> vif .type ) {
4619
4618
case NL80211_IFTYPE_AP : {
@@ -4624,13 +4623,12 @@ ieee80211_set_after_color_change_beacon(struct ieee80211_sub_if_data *sdata,
4624
4623
4625
4624
ret = ieee80211_assign_beacon (sdata , & sdata -> deflink ,
4626
4625
sdata -> deflink .u .ap .next_beacon ,
4627
- NULL , NULL );
4626
+ NULL , NULL , changed );
4628
4627
ieee80211_free_next_beacon (& sdata -> deflink );
4629
4628
4630
4629
if (ret < 0 )
4631
4630
return ret ;
4632
4631
4633
- * changed |= ret ;
4634
4632
break ;
4635
4633
}
4636
4634
default :
@@ -4644,7 +4642,7 @@ ieee80211_set_after_color_change_beacon(struct ieee80211_sub_if_data *sdata,
4644
4642
static int
4645
4643
ieee80211_set_color_change_beacon (struct ieee80211_sub_if_data * sdata ,
4646
4644
struct cfg80211_color_change_settings * params ,
4647
- u32 * changed )
4645
+ u64 * changed )
4648
4646
{
4649
4647
struct ieee80211_color_change_settings color_change = {};
4650
4648
int err ;
@@ -4667,12 +4665,11 @@ ieee80211_set_color_change_beacon(struct ieee80211_sub_if_data *sdata,
4667
4665
4668
4666
err = ieee80211_assign_beacon (sdata , & sdata -> deflink ,
4669
4667
& params -> beacon_color_change ,
4670
- NULL , & color_change );
4668
+ NULL , & color_change , changed );
4671
4669
if (err < 0 ) {
4672
4670
ieee80211_free_next_beacon (& sdata -> deflink );
4673
4671
return err ;
4674
4672
}
4675
- * changed |= err ;
4676
4673
break ;
4677
4674
default :
4678
4675
return - EOPNOTSUPP ;
@@ -4683,7 +4680,7 @@ ieee80211_set_color_change_beacon(struct ieee80211_sub_if_data *sdata,
4683
4680
4684
4681
static void
4685
4682
ieee80211_color_change_bss_config_notify (struct ieee80211_sub_if_data * sdata ,
4686
- u8 color , int enable , u32 changed )
4683
+ u8 color , int enable , u64 changed )
4687
4684
{
4688
4685
sdata -> vif .bss_conf .he_bss_color .color = color ;
4689
4686
sdata -> vif .bss_conf .he_bss_color .enabled = enable ;
@@ -4711,7 +4708,7 @@ ieee80211_color_change_bss_config_notify(struct ieee80211_sub_if_data *sdata,
4711
4708
static int ieee80211_color_change_finalize (struct ieee80211_sub_if_data * sdata )
4712
4709
{
4713
4710
struct ieee80211_local * local = sdata -> local ;
4714
- u32 changed = 0 ;
4711
+ u64 changed = 0 ;
4715
4712
int err ;
4716
4713
4717
4714
sdata_assert_lock (sdata );
@@ -4808,7 +4805,7 @@ ieee80211_color_change(struct wiphy *wiphy, struct net_device *dev,
4808
4805
{
4809
4806
struct ieee80211_sub_if_data * sdata = IEEE80211_DEV_TO_SUB_IF (dev );
4810
4807
struct ieee80211_local * local = sdata -> local ;
4811
- u32 changed = 0 ;
4808
+ u64 changed = 0 ;
4812
4809
int err ;
4813
4810
4814
4811
sdata_assert_lock (sdata );
0 commit comments