~indicator-network-developers/wpasupplicant/trunk

« back to all changes in this revision

Viewing changes to src/ap/beacon.c

  • Committer: Jouni Malinen
  • Author(s): Aleti Nageshwar Reddy
  • Date: 2022-06-20 11:39:18 UTC
  • Revision ID: git-v1:bafe35df0351cd42323cf0b9d24d90db87cadd60
Move CHANWIDTH_* definitions from ieee80211_defs.h to defs.h

Move most of CHANWIDTH_* definitions from ieee80211_defs.h to defs.h as
the definitions are getting used mostly for internal purpose only. Also
change prefix of the definitions to CONF_OPER_CHWIDTH_* and update in
all the files accordingly.

Leave the couple of VHT-specific exceptions to use the old defines (the
reason why they were originally added as VHT values), to avoid use of
clearly marked configuration values in information elements. In
addition, use the defines instead of magic values where appropriate.

Signed-off-by: Aleti Nageshwar Reddy <quic_anageshw@quicinc.com>

Show diffs side-by-side

added added

removed removed

Lines of Context:
1280
1280
                }
1281
1281
        } else {
1282
1282
                switch (hostapd_get_oper_chwidth(hapd->iconf)) {
1283
 
                case CHANWIDTH_80P80MHZ:
 
1283
                case CONF_OPER_CHWIDTH_80P80MHZ:
1284
1284
                        mcs_nss_size += 4;
1285
1285
                        /* fallthrough */
1286
 
                case CHANWIDTH_160MHZ:
 
1286
                case CONF_OPER_CHWIDTH_160MHZ:
1287
1287
                        mcs_nss_size += 4;
1288
1288
                        chwidth = FD_CAP_BSS_CHWIDTH_160_80_80;
1289
1289
                        break;
1290
 
                case CHANWIDTH_80MHZ:
 
1290
                case CONF_OPER_CHWIDTH_80MHZ:
1291
1291
                        chwidth = FD_CAP_BSS_CHWIDTH_80;
1292
1292
                        break;
1293
 
                case CHANWIDTH_USE_HT:
 
1293
                case CONF_OPER_CHWIDTH_USE_HT:
1294
1294
                        if (hapd->iconf->secondary_channel)
1295
1295
                                chwidth = FD_CAP_BSS_CHWIDTH_40;
1296
1296
                        else
1297
1297
                                chwidth = FD_CAP_BSS_CHWIDTH_20;
1298
1298
                        break;
 
1299
                default:
 
1300
                        break;
1299
1301
                }
1300
1302
 
1301
1303
#ifdef CONFIG_IEEE80211AX