MCPcopy Index your code
hub / github.com/F-Stack/f-stack / list_capabilities

Function list_capabilities

tools/ifconfig/ifieee80211.c:4244–4277  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4242}
4243
4244static void
4245list_capabilities(int s)
4246{
4247 struct ieee80211_devcaps_req *dc;
4248
4249 if (verbose)
4250 dc = malloc(IEEE80211_DEVCAPS_SIZE(MAXCHAN));
4251 else
4252 dc = malloc(IEEE80211_DEVCAPS_SIZE(1));
4253 if (dc == NULL)
4254 errx(1, "no space for device capabilities");
4255 dc->dc_chaninfo.ic_nchans = verbose ? MAXCHAN : 1;
4256 getdevcaps(s, dc);
4257 printb("drivercaps", dc->dc_drivercaps, IEEE80211_C_BITS);
4258 if (dc->dc_cryptocaps != 0 || verbose) {
4259 putchar('\n');
4260 printb("cryptocaps", dc->dc_cryptocaps, IEEE80211_CRYPTO_BITS);
4261 }
4262 if (dc->dc_htcaps != 0 || verbose) {
4263 putchar('\n');
4264 printb("htcaps", dc->dc_htcaps, IEEE80211_HTCAP_BITS);
4265 }
4266 if (dc->dc_vhtcaps != 0 || verbose) {
4267 putchar('\n');
4268 printb("vhtcaps", dc->dc_vhtcaps, IEEE80211_VHTCAP_BITS);
4269 }
4270
4271 putchar('\n');
4272 if (verbose) {
4273 chaninfo = &dc->dc_chaninfo; /* XXX */
4274 print_channels(s, &dc->dc_chaninfo, 1/*allchans*/, verbose);
4275 }
4276 free(dc);
4277}
4278
4279static int
4280get80211wme(int s, int param, int ac, int *val)

Callers 1

ifieee80211.cFile · 0.85

Calls 6

mallocFunction · 0.85
getdevcapsFunction · 0.85
putcharFunction · 0.85
print_channelsFunction · 0.85
printbFunction · 0.70
freeFunction · 0.50

Tested by

no test coverage detected