1 /* SPDX-License-Identifier: GPL-2.0 */ 2 /* 3 * Portions of this file 4 * Copyright(c) 2016-2017 Intel Deutschland GmbH 5 * Copyright (C) 2018, 2020-2024 Intel Corporation 6 */ 7 #undef TRACE_SYSTEM 8 #define TRACE_SYSTEM cfg80211 9 10 #if !defined(__RDEV_OPS_TRACE) || defined(TRACE_HEADER_MULTI_READ) 11 #define __RDEV_OPS_TRACE 12 13 #include <linux/tracepoint.h> 14 15 #include <linux/rtnetlink.h> 16 #include <linux/etherdevice.h> 17 #include <net/cfg80211.h> 18 #include "core.h" 19 20 #define MAC_ENTRY(entry_mac) __array(u8, entry_mac, ETH_ALEN) 21 #define MAC_ASSIGN(entry_mac, given_mac) do { \ 22 if (given_mac) \ 23 memcpy(__entry->entry_mac, given_mac, ETH_ALEN); \ 24 else \ 25 eth_zero_addr(__entry->entry_mac); \ 26 } while (0) 27 28 #define MAXNAME 32 29 #define WIPHY_ENTRY __array(char, wiphy_name, 32) 30 #define WIPHY_ASSIGN strscpy(__entry->wiphy_name, wiphy_name(wiphy), MAXNAME) 31 #define WIPHY_PR_FMT "%s" 32 #define WIPHY_PR_ARG __entry->wiphy_name 33 34 #define WDEV_ENTRY __field(u32, id) 35 #define WDEV_ASSIGN (__entry->id) = (!IS_ERR_OR_NULL(wdev) \ 36 ? wdev->identifier : 0) 37 #define WDEV_PR_FMT "wdev(%u)" 38 #define WDEV_PR_ARG (__entry->id) 39 40 #define NETDEV_ENTRY __array(char, name, IFNAMSIZ) \ 41 __field(int, ifindex) 42 #define NETDEV_ASSIGN \ 43 do { \ 44 memcpy(__entry->name, netdev->name, IFNAMSIZ); \ 45 (__entry->ifindex) = (netdev->ifindex); \ 46 } while (0) 47 #define NETDEV_PR_FMT "netdev:%s(%d)" 48 #define NETDEV_PR_ARG __entry->name, __entry->ifindex 49 50 #define MESH_CFG_ENTRY __field(u16, dot11MeshRetryTimeout) \ 51 __field(u16, dot11MeshConfirmTimeout) \ 52 __field(u16, dot11MeshHoldingTimeout) \ 53 __field(u16, dot11MeshMaxPeerLinks) \ 54 __field(u8, dot11MeshMaxRetries) \ 55 __field(u8, dot11MeshTTL) \ 56 __field(u8, element_ttl) \ 57 __field(bool, auto_open_plinks) \ 58 __field(u32, dot11MeshNbrOffsetMaxNeighbor) \ 59 __field(u8, dot11MeshHWMPmaxPREQretries) \ 60 __field(u32, path_refresh_time) \ 61 __field(u32, dot11MeshHWMPactivePathTimeout) \ 62 __field(u16, min_discovery_timeout) \ 63 __field(u16, dot11MeshHWMPpreqMinInterval) \ 64 __field(u16, dot11MeshHWMPperrMinInterval) \ 65 __field(u16, dot11MeshHWMPnetDiameterTraversalTime) \ 66 __field(u8, dot11MeshHWMPRootMode) \ 67 __field(u16, dot11MeshHWMPRannInterval) \ 68 __field(bool, dot11MeshGateAnnouncementProtocol) \ 69 __field(bool, dot11MeshForwarding) \ 70 __field(s32, rssi_threshold) \ 71 __field(u16, ht_opmode) \ 72 __field(u32, dot11MeshHWMPactivePathToRootTimeout) \ 73 __field(u16, dot11MeshHWMProotInterval) \ 74 __field(u16, dot11MeshHWMPconfirmationInterval) \ 75 __field(bool, dot11MeshNolearn) 76 #define MESH_CFG_ASSIGN \ 77 do { \ 78 __entry->dot11MeshRetryTimeout = conf->dot11MeshRetryTimeout; \ 79 __entry->dot11MeshConfirmTimeout = \ 80 conf->dot11MeshConfirmTimeout; \ 81 __entry->dot11MeshHoldingTimeout = \ 82 conf->dot11MeshHoldingTimeout; \ 83 __entry->dot11MeshMaxPeerLinks = conf->dot11MeshMaxPeerLinks; \ 84 __entry->dot11MeshMaxRetries = conf->dot11MeshMaxRetries; \ 85 __entry->dot11MeshTTL = conf->dot11MeshTTL; \ 86 __entry->element_ttl = conf->element_ttl; \ 87 __entry->auto_open_plinks = conf->auto_open_plinks; \ 88 __entry->dot11MeshNbrOffsetMaxNeighbor = \ 89 conf->dot11MeshNbrOffsetMaxNeighbor; \ 90 __entry->dot11MeshHWMPmaxPREQretries = \ 91 conf->dot11MeshHWMPmaxPREQretries; \ 92 __entry->path_refresh_time = conf->path_refresh_time; \ 93 __entry->dot11MeshHWMPactivePathTimeout = \ 94 conf->dot11MeshHWMPactivePathTimeout; \ 95 __entry->min_discovery_timeout = conf->min_discovery_timeout; \ 96 __entry->dot11MeshHWMPpreqMinInterval = \ 97 conf->dot11MeshHWMPpreqMinInterval; \ 98 __entry->dot11MeshHWMPperrMinInterval = \ 99 conf->dot11MeshHWMPperrMinInterval; \ 100 __entry->dot11MeshHWMPnetDiameterTraversalTime = \ 101 conf->dot11MeshHWMPnetDiameterTraversalTime; \ 102 __entry->dot11MeshHWMPRootMode = conf->dot11MeshHWMPRootMode; \ 103 __entry->dot11MeshHWMPRannInterval = \ 104 conf->dot11MeshHWMPRannInterval; \ 105 __entry->dot11MeshGateAnnouncementProtocol = \ 106 conf->dot11MeshGateAnnouncementProtocol; \ 107 __entry->dot11MeshForwarding = conf->dot11MeshForwarding; \ 108 __entry->rssi_threshold = conf->rssi_threshold; \ 109 __entry->ht_opmode = conf->ht_opmode; \ 110 __entry->dot11MeshHWMPactivePathToRootTimeout = \ 111 conf->dot11MeshHWMPactivePathToRootTimeout; \ 112 __entry->dot11MeshHWMProotInterval = \ 113 conf->dot11MeshHWMProotInterval; \ 114 __entry->dot11MeshHWMPconfirmationInterval = \ 115 conf->dot11MeshHWMPconfirmationInterval; \ 116 __entry->dot11MeshNolearn = conf->dot11MeshNolearn; \ 117 } while (0) 118 119 #define CHAN_ENTRY __field(enum nl80211_band, band) \ 120 __field(u32, center_freq) \ 121 __field(u16, freq_offset) 122 #define CHAN_ASSIGN(chan) \ 123 do { \ 124 if (chan) { \ 125 __entry->band = chan->band; \ 126 __entry->center_freq = chan->center_freq; \ 127 __entry->freq_offset = chan->freq_offset; \ 128 } else { \ 129 __entry->band = 0; \ 130 __entry->center_freq = 0; \ 131 __entry->freq_offset = 0; \ 132 } \ 133 } while (0) 134 #define CHAN_PR_FMT "band: %d, freq: %u.%03u" 135 #define CHAN_PR_ARG __entry->band, __entry->center_freq, __entry->freq_offset 136 137 #define CHAN_DEF_ENTRY __field(enum nl80211_band, band) \ 138 __field(u32, control_freq) \ 139 __field(u32, freq_offset) \ 140 __field(u32, width) \ 141 __field(u32, center_freq1) \ 142 __field(u32, freq1_offset) \ 143 __field(u32, center_freq2) \ 144 __field(u16, punctured) 145 #define CHAN_DEF_ASSIGN(chandef) \ 146 do { \ 147 if ((chandef) && (chandef)->chan) { \ 148 __entry->band = (chandef)->chan->band; \ 149 __entry->control_freq = \ 150 (chandef)->chan->center_freq; \ 151 __entry->freq_offset = \ 152 (chandef)->chan->freq_offset; \ 153 __entry->width = (chandef)->width; \ 154 __entry->center_freq1 = (chandef)->center_freq1;\ 155 __entry->freq1_offset = (chandef)->freq1_offset;\ 156 __entry->center_freq2 = (chandef)->center_freq2;\ 157 __entry->punctured = (chandef)->punctured; \ 158 } else { \ 159 __entry->band = 0; \ 160 __entry->control_freq = 0; \ 161 __entry->freq_offset = 0; \ 162 __entry->width = 0; \ 163 __entry->center_freq1 = 0; \ 164 __entry->freq1_offset = 0; \ 165 __entry->center_freq2 = 0; \ 166 __entry->punctured = 0; \ 167 } \ 168 } while (0) 169 #define CHAN_DEF_PR_FMT \ 170 "band: %d, control freq: %u.%03u, width: %d, cf1: %u.%03u, cf2: %u, punct: 0x%x" 171 #define CHAN_DEF_PR_ARG __entry->band, __entry->control_freq, \ 172 __entry->freq_offset, __entry->width, \ 173 __entry->center_freq1, __entry->freq1_offset, \ 174 __entry->center_freq2, __entry->punctured 175 176 #define FILS_AAD_ASSIGN(fa) \ 177 do { \ 178 if (fa) { \ 179 ether_addr_copy(__entry->macaddr, fa->macaddr); \ 180 __entry->kek_len = fa->kek_len; \ 181 } else { \ 182 eth_zero_addr(__entry->macaddr); \ 183 __entry->kek_len = 0; \ 184 } \ 185 } while (0) 186 #define FILS_AAD_PR_FMT \ 187 "macaddr: %pM, kek_len: %d" 188 189 #define SINFO_ENTRY __field(int, generation) \ 190 __field(u32, connected_time) \ 191 __field(u32, inactive_time) \ 192 __field(u32, rx_bytes) \ 193 __field(u32, tx_bytes) \ 194 __field(u32, rx_packets) \ 195 __field(u32, tx_packets) \ 196 __field(u32, tx_retries) \ 197 __field(u32, tx_failed) \ 198 __field(u32, rx_dropped_misc) \ 199 __field(u32, beacon_loss_count) \ 200 __field(u16, llid) \ 201 __field(u16, plid) \ 202 __field(u8, plink_state) 203 #define SINFO_ASSIGN \ 204 do { \ 205 __entry->generation = sinfo->generation; \ 206 __entry->connected_time = sinfo->connected_time; \ 207 __entry->inactive_time = sinfo->inactive_time; \ 208 __entry->rx_bytes = sinfo->rx_bytes; \ 209 __entry->tx_bytes = sinfo->tx_bytes; \ 210 __entry->rx_packets = sinfo->rx_packets; \ 211 __entry->tx_packets = sinfo->tx_packets; \ 212 __entry->tx_retries = sinfo->tx_retries; \ 213 __entry->tx_failed = sinfo->tx_failed; \ 214 __entry->rx_dropped_misc = sinfo->rx_dropped_misc; \ 215 __entry->beacon_loss_count = sinfo->beacon_loss_count; \ 216 __entry->llid = sinfo->llid; \ 217 __entry->plid = sinfo->plid; \ 218 __entry->plink_state = sinfo->plink_state; \ 219 } while (0) 220 221 #define BOOL_TO_STR(bo) (bo) ? "true" : "false" 222 223 #define QOS_MAP_ENTRY __field(u8, num_des) \ 224 __array(u8, dscp_exception, \ 225 2 * IEEE80211_QOS_MAP_MAX_EX) \ 226 __array(u8, up, IEEE80211_QOS_MAP_LEN_MIN) 227 #define QOS_MAP_ASSIGN(qos_map) \ 228 do { \ 229 if ((qos_map)) { \ 230 __entry->num_des = (qos_map)->num_des; \ 231 memcpy(__entry->dscp_exception, \ 232 &(qos_map)->dscp_exception, \ 233 2 * IEEE80211_QOS_MAP_MAX_EX); \ 234 memcpy(__entry->up, &(qos_map)->up, \ 235 IEEE80211_QOS_MAP_LEN_MIN); \ 236 } else { \ 237 __entry->num_des = 0; \ 238 memset(__entry->dscp_exception, 0, \ 239 2 * IEEE80211_QOS_MAP_MAX_EX); \ 240 memset(__entry->up, 0, \ 241 IEEE80211_QOS_MAP_LEN_MIN); \ 242 } \ 243 } while (0) 244 245 /************************************************************* 246 * wiphy work traces * 247 *************************************************************/ 248 249 DECLARE_EVENT_CLASS(wiphy_work_event, 250 TP_PROTO(struct wiphy *wiphy, struct wiphy_work *work), 251 TP_ARGS(wiphy, work), 252 TP_STRUCT__entry( 253 WIPHY_ENTRY 254 __field(void *, instance) 255 __field(void *, func) 256 ), 257 TP_fast_assign( 258 WIPHY_ASSIGN; 259 __entry->instance = work; 260 __entry->func = work ? work->func : NULL; 261 ), 262 TP_printk(WIPHY_PR_FMT " instance=%p func=%pS", 263 WIPHY_PR_ARG, __entry->instance, __entry->func) 264 ); 265 266 DEFINE_EVENT(wiphy_work_event, wiphy_work_queue, 267 TP_PROTO(struct wiphy *wiphy, struct wiphy_work *work), 268 TP_ARGS(wiphy, work) 269 ); 270 271 DEFINE_EVENT(wiphy_work_event, wiphy_work_run, 272 TP_PROTO(struct wiphy *wiphy, struct wiphy_work *work), 273 TP_ARGS(wiphy, work) 274 ); 275 276 DEFINE_EVENT(wiphy_work_event, wiphy_work_cancel, 277 TP_PROTO(struct wiphy *wiphy, struct wiphy_work *work), 278 TP_ARGS(wiphy, work) 279 ); 280 281 DEFINE_EVENT(wiphy_work_event, wiphy_work_flush, 282 TP_PROTO(struct wiphy *wiphy, struct wiphy_work *work), 283 TP_ARGS(wiphy, work) 284 ); 285 286 TRACE_EVENT(wiphy_delayed_work_queue, 287 TP_PROTO(struct wiphy *wiphy, struct wiphy_work *work, 288 unsigned long delay), 289 TP_ARGS(wiphy, work, delay), 290 TP_STRUCT__entry( 291 WIPHY_ENTRY 292 __field(void *, instance) 293 __field(void *, func) 294 __field(unsigned long, delay) 295 ), 296 TP_fast_assign( 297 WIPHY_ASSIGN; 298 __entry->instance = work; 299 __entry->func = work->func; 300 __entry->delay = delay; 301 ), 302 TP_printk(WIPHY_PR_FMT " instance=%p func=%pS delay=%ld", 303 WIPHY_PR_ARG, __entry->instance, __entry->func, 304 __entry->delay) 305 ); 306 307 TRACE_EVENT(wiphy_work_worker_start, 308 TP_PROTO(struct wiphy *wiphy), 309 TP_ARGS(wiphy), 310 TP_STRUCT__entry( 311 WIPHY_ENTRY 312 ), 313 TP_fast_assign( 314 WIPHY_ASSIGN; 315 ), 316 TP_printk(WIPHY_PR_FMT, WIPHY_PR_ARG) 317 ); 318 319 /************************************************************* 320 * rdev->ops traces * 321 *************************************************************/ 322 323 TRACE_EVENT(rdev_suspend, 324 TP_PROTO(struct wiphy *wiphy, struct cfg80211_wowlan *wow), 325 TP_ARGS(wiphy, wow), 326 TP_STRUCT__entry( 327 WIPHY_ENTRY 328 __field(bool, any) 329 __field(bool, disconnect) 330 __field(bool, magic_pkt) 331 __field(bool, gtk_rekey_failure) 332 __field(bool, eap_identity_req) 333 __field(bool, four_way_handshake) 334 __field(bool, rfkill_release) 335 __field(bool, valid_wow) 336 ), 337 TP_fast_assign( 338 WIPHY_ASSIGN; 339 if (wow) { 340 __entry->any = wow->any; 341 __entry->disconnect = wow->disconnect; 342 __entry->magic_pkt = wow->magic_pkt; 343 __entry->gtk_rekey_failure = wow->gtk_rekey_failure; 344 __entry->eap_identity_req = wow->eap_identity_req; 345 __entry->four_way_handshake = wow->four_way_handshake; 346 __entry->rfkill_release = wow->rfkill_release; 347 __entry->valid_wow = true; 348 } else { 349 __entry->valid_wow = false; 350 } 351 ), 352 TP_printk(WIPHY_PR_FMT ", wow%s - any: %d, disconnect: %d, " 353 "magic pkt: %d, gtk rekey failure: %d, eap identify req: %d, " 354 "four way handshake: %d, rfkill release: %d.", 355 WIPHY_PR_ARG, __entry->valid_wow ? "" : "(Not configured!)", 356 __entry->any, __entry->disconnect, __entry->magic_pkt, 357 __entry->gtk_rekey_failure, __entry->eap_identity_req, 358 __entry->four_way_handshake, __entry->rfkill_release) 359 ); 360 361 TRACE_EVENT(rdev_return_int, 362 TP_PROTO(struct wiphy *wiphy, int ret), 363 TP_ARGS(wiphy, ret), 364 TP_STRUCT__entry( 365 WIPHY_ENTRY 366 __field(int, ret) 367 ), 368 TP_fast_assign( 369 WIPHY_ASSIGN; 370 __entry->ret = ret; 371 ), 372 TP_printk(WIPHY_PR_FMT ", returned: %d", WIPHY_PR_ARG, __entry->ret) 373 ); 374 375 TRACE_EVENT(rdev_scan, 376 TP_PROTO(struct wiphy *wiphy, struct cfg80211_scan_request *request), 377 TP_ARGS(wiphy, request), 378 TP_STRUCT__entry( 379 WIPHY_ENTRY 380 ), 381 TP_fast_assign( 382 WIPHY_ASSIGN; 383 ), 384 TP_printk(WIPHY_PR_FMT, WIPHY_PR_ARG) 385 ); 386 387 DECLARE_EVENT_CLASS(wiphy_only_evt, 388 TP_PROTO(struct wiphy *wiphy), 389 TP_ARGS(wiphy), 390 TP_STRUCT__entry( 391 WIPHY_ENTRY 392 ), 393 TP_fast_assign( 394 WIPHY_ASSIGN; 395 ), 396 TP_printk(WIPHY_PR_FMT, WIPHY_PR_ARG) 397 ); 398 399 DEFINE_EVENT(wiphy_only_evt, rdev_resume, 400 TP_PROTO(struct wiphy *wiphy), 401 TP_ARGS(wiphy) 402 ); 403 404 DEFINE_EVENT(wiphy_only_evt, rdev_return_void, 405 TP_PROTO(struct wiphy *wiphy), 406 TP_ARGS(wiphy) 407 ); 408 409 DEFINE_EVENT(wiphy_only_evt, rdev_get_antenna, 410 TP_PROTO(struct wiphy *wiphy), 411 TP_ARGS(wiphy) 412 ); 413 414 DEFINE_EVENT(wiphy_only_evt, rdev_rfkill_poll, 415 TP_PROTO(struct wiphy *wiphy), 416 TP_ARGS(wiphy) 417 ); 418 419 DECLARE_EVENT_CLASS(wiphy_enabled_evt, 420 TP_PROTO(struct wiphy *wiphy, bool enabled), 421 TP_ARGS(wiphy, enabled), 422 TP_STRUCT__entry( 423 WIPHY_ENTRY 424 __field(bool, enabled) 425 ), 426 TP_fast_assign( 427 WIPHY_ASSIGN; 428 __entry->enabled = enabled; 429 ), 430 TP_printk(WIPHY_PR_FMT ", %senabled ", 431 WIPHY_PR_ARG, __entry->enabled ? "" : "not ") 432 ); 433 434 DEFINE_EVENT(wiphy_enabled_evt, rdev_set_wakeup, 435 TP_PROTO(struct wiphy *wiphy, bool enabled), 436 TP_ARGS(wiphy, enabled) 437 ); 438 439 TRACE_EVENT(rdev_add_virtual_intf, 440 TP_PROTO(struct wiphy *wiphy, char *name, enum nl80211_iftype type), 441 TP_ARGS(wiphy, name, type), 442 TP_STRUCT__entry( 443 WIPHY_ENTRY 444 __string(vir_intf_name, name ? name : "<noname>") 445 __field(enum nl80211_iftype, type) 446 ), 447 TP_fast_assign( 448 WIPHY_ASSIGN; 449 __assign_str(vir_intf_name); 450 __entry->type = type; 451 ), 452 TP_printk(WIPHY_PR_FMT ", virtual intf name: %s, type: %d", 453 WIPHY_PR_ARG, __get_str(vir_intf_name), __entry->type) 454 ); 455 456 DECLARE_EVENT_CLASS(wiphy_wdev_evt, 457 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 458 TP_ARGS(wiphy, wdev), 459 TP_STRUCT__entry( 460 WIPHY_ENTRY 461 WDEV_ENTRY 462 ), 463 TP_fast_assign( 464 WIPHY_ASSIGN; 465 WDEV_ASSIGN; 466 ), 467 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT, WIPHY_PR_ARG, WDEV_PR_ARG) 468 ); 469 470 DECLARE_EVENT_CLASS(wiphy_wdev_cookie_evt, 471 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, u64 cookie), 472 TP_ARGS(wiphy, wdev, cookie), 473 TP_STRUCT__entry( 474 WIPHY_ENTRY 475 WDEV_ENTRY 476 __field(u64, cookie) 477 ), 478 TP_fast_assign( 479 WIPHY_ASSIGN; 480 WDEV_ASSIGN; 481 __entry->cookie = cookie; 482 ), 483 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", cookie: %lld", 484 WIPHY_PR_ARG, WDEV_PR_ARG, 485 (unsigned long long)__entry->cookie) 486 ); 487 488 DEFINE_EVENT(wiphy_wdev_evt, rdev_return_wdev, 489 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 490 TP_ARGS(wiphy, wdev) 491 ); 492 493 DEFINE_EVENT(wiphy_wdev_evt, rdev_del_virtual_intf, 494 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 495 TP_ARGS(wiphy, wdev) 496 ); 497 498 TRACE_EVENT(rdev_change_virtual_intf, 499 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 500 enum nl80211_iftype type), 501 TP_ARGS(wiphy, netdev, type), 502 TP_STRUCT__entry( 503 WIPHY_ENTRY 504 NETDEV_ENTRY 505 __field(enum nl80211_iftype, type) 506 ), 507 TP_fast_assign( 508 WIPHY_ASSIGN; 509 NETDEV_ASSIGN; 510 __entry->type = type; 511 ), 512 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", type: %d", 513 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->type) 514 ); 515 516 DECLARE_EVENT_CLASS(key_handle, 517 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int link_id, 518 u8 key_index, bool pairwise, const u8 *mac_addr), 519 TP_ARGS(wiphy, netdev, link_id, key_index, pairwise, mac_addr), 520 TP_STRUCT__entry( 521 WIPHY_ENTRY 522 NETDEV_ENTRY 523 MAC_ENTRY(mac_addr) 524 __field(int, link_id) 525 __field(u8, key_index) 526 __field(bool, pairwise) 527 ), 528 TP_fast_assign( 529 WIPHY_ASSIGN; 530 NETDEV_ASSIGN; 531 MAC_ASSIGN(mac_addr, mac_addr); 532 __entry->link_id = link_id; 533 __entry->key_index = key_index; 534 __entry->pairwise = pairwise; 535 ), 536 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", link_id: %d, " 537 "key_index: %u, pairwise: %s, mac addr: %pM", 538 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->link_id, 539 __entry->key_index, BOOL_TO_STR(__entry->pairwise), 540 __entry->mac_addr) 541 ); 542 543 DEFINE_EVENT(key_handle, rdev_get_key, 544 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int link_id, 545 u8 key_index, bool pairwise, const u8 *mac_addr), 546 TP_ARGS(wiphy, netdev, link_id, key_index, pairwise, mac_addr) 547 ); 548 549 DEFINE_EVENT(key_handle, rdev_del_key, 550 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int link_id, 551 u8 key_index, bool pairwise, const u8 *mac_addr), 552 TP_ARGS(wiphy, netdev, link_id, key_index, pairwise, mac_addr) 553 ); 554 555 TRACE_EVENT(rdev_add_key, 556 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int link_id, 557 u8 key_index, bool pairwise, const u8 *mac_addr, u8 mode), 558 TP_ARGS(wiphy, netdev, link_id, key_index, pairwise, mac_addr, mode), 559 TP_STRUCT__entry( 560 WIPHY_ENTRY 561 NETDEV_ENTRY 562 MAC_ENTRY(mac_addr) 563 __field(int, link_id) 564 __field(u8, key_index) 565 __field(bool, pairwise) 566 __field(u8, mode) 567 ), 568 TP_fast_assign( 569 WIPHY_ASSIGN; 570 NETDEV_ASSIGN; 571 MAC_ASSIGN(mac_addr, mac_addr); 572 __entry->link_id = link_id; 573 __entry->key_index = key_index; 574 __entry->pairwise = pairwise; 575 __entry->mode = mode; 576 ), 577 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", link_id: %d, " 578 "key_index: %u, mode: %u, pairwise: %s, " 579 "mac addr: %pM", 580 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->link_id, 581 __entry->key_index, __entry->mode, 582 BOOL_TO_STR(__entry->pairwise), __entry->mac_addr) 583 ); 584 585 TRACE_EVENT(rdev_set_default_key, 586 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int link_id, 587 u8 key_index, bool unicast, bool multicast), 588 TP_ARGS(wiphy, netdev, link_id, key_index, unicast, multicast), 589 TP_STRUCT__entry( 590 WIPHY_ENTRY 591 NETDEV_ENTRY 592 __field(int, link_id) 593 __field(u8, key_index) 594 __field(bool, unicast) 595 __field(bool, multicast) 596 ), 597 TP_fast_assign( 598 WIPHY_ASSIGN; 599 NETDEV_ASSIGN; 600 __entry->link_id = link_id; 601 __entry->key_index = key_index; 602 __entry->unicast = unicast; 603 __entry->multicast = multicast; 604 ), 605 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", link_id: %d, " 606 "key index: %u, unicast: %s, multicast: %s", 607 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->link_id, 608 __entry->key_index, BOOL_TO_STR(__entry->unicast), 609 BOOL_TO_STR(__entry->multicast)) 610 ); 611 612 TRACE_EVENT(rdev_set_default_mgmt_key, 613 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int link_id, 614 u8 key_index), 615 TP_ARGS(wiphy, netdev, link_id, key_index), 616 TP_STRUCT__entry( 617 WIPHY_ENTRY 618 NETDEV_ENTRY 619 __field(int, link_id) 620 __field(u8, key_index) 621 ), 622 TP_fast_assign( 623 WIPHY_ASSIGN; 624 NETDEV_ASSIGN; 625 __entry->link_id = link_id; 626 __entry->key_index = key_index; 627 ), 628 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", link_id: %d, " 629 "key index: %u", WIPHY_PR_ARG, NETDEV_PR_ARG, 630 __entry->link_id, __entry->key_index) 631 ); 632 633 TRACE_EVENT(rdev_set_default_beacon_key, 634 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int link_id, 635 u8 key_index), 636 TP_ARGS(wiphy, netdev, link_id, key_index), 637 TP_STRUCT__entry( 638 WIPHY_ENTRY 639 NETDEV_ENTRY 640 __field(int, link_id) 641 __field(u8, key_index) 642 ), 643 TP_fast_assign( 644 WIPHY_ASSIGN; 645 NETDEV_ASSIGN; 646 __entry->link_id = link_id; 647 __entry->key_index = key_index; 648 ), 649 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", link_id: %d, " 650 "key index: %u", WIPHY_PR_ARG, NETDEV_PR_ARG, 651 __entry->link_id, __entry->key_index) 652 ); 653 654 TRACE_EVENT(rdev_start_ap, 655 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 656 struct cfg80211_ap_settings *settings), 657 TP_ARGS(wiphy, netdev, settings), 658 TP_STRUCT__entry( 659 WIPHY_ENTRY 660 NETDEV_ENTRY 661 CHAN_DEF_ENTRY 662 __field(int, beacon_interval) 663 __field(int, dtim_period) 664 __array(char, ssid, IEEE80211_MAX_SSID_LEN + 1) 665 __field(enum nl80211_hidden_ssid, hidden_ssid) 666 __field(u32, wpa_ver) 667 __field(bool, privacy) 668 __field(enum nl80211_auth_type, auth_type) 669 __field(int, inactivity_timeout) 670 __field(unsigned int, link_id) 671 ), 672 TP_fast_assign( 673 WIPHY_ASSIGN; 674 NETDEV_ASSIGN; 675 CHAN_DEF_ASSIGN(&settings->chandef); 676 __entry->beacon_interval = settings->beacon_interval; 677 __entry->dtim_period = settings->dtim_period; 678 __entry->hidden_ssid = settings->hidden_ssid; 679 __entry->wpa_ver = settings->crypto.wpa_versions; 680 __entry->privacy = settings->privacy; 681 __entry->auth_type = settings->auth_type; 682 __entry->inactivity_timeout = settings->inactivity_timeout; 683 memset(__entry->ssid, 0, IEEE80211_MAX_SSID_LEN + 1); 684 memcpy(__entry->ssid, settings->ssid, settings->ssid_len); 685 __entry->link_id = settings->beacon.link_id; 686 ), 687 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", AP settings - ssid: %s, " 688 CHAN_DEF_PR_FMT ", beacon interval: %d, dtim period: %d, " 689 "hidden ssid: %d, wpa versions: %u, privacy: %s, " 690 "auth type: %d, inactivity timeout: %d, link_id: %d", 691 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->ssid, CHAN_DEF_PR_ARG, 692 __entry->beacon_interval, __entry->dtim_period, 693 __entry->hidden_ssid, __entry->wpa_ver, 694 BOOL_TO_STR(__entry->privacy), __entry->auth_type, 695 __entry->inactivity_timeout, __entry->link_id) 696 ); 697 698 TRACE_EVENT(rdev_change_beacon, 699 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 700 struct cfg80211_ap_update *info), 701 TP_ARGS(wiphy, netdev, info), 702 TP_STRUCT__entry( 703 WIPHY_ENTRY 704 NETDEV_ENTRY 705 __field(int, link_id) 706 __dynamic_array(u8, head, info->beacon.head_len) 707 __dynamic_array(u8, tail, info->beacon.tail_len) 708 __dynamic_array(u8, beacon_ies, info->beacon.beacon_ies_len) 709 __dynamic_array(u8, proberesp_ies, info->beacon.proberesp_ies_len) 710 __dynamic_array(u8, assocresp_ies, info->beacon.assocresp_ies_len) 711 __dynamic_array(u8, probe_resp, info->beacon.probe_resp_len) 712 ), 713 TP_fast_assign( 714 WIPHY_ASSIGN; 715 NETDEV_ASSIGN; 716 __entry->link_id = info->beacon.link_id; 717 if (info->beacon.head) 718 memcpy(__get_dynamic_array(head), 719 info->beacon.head, 720 info->beacon.head_len); 721 if (info->beacon.tail) 722 memcpy(__get_dynamic_array(tail), 723 info->beacon.tail, 724 info->beacon.tail_len); 725 if (info->beacon.beacon_ies) 726 memcpy(__get_dynamic_array(beacon_ies), 727 info->beacon.beacon_ies, 728 info->beacon.beacon_ies_len); 729 if (info->beacon.proberesp_ies) 730 memcpy(__get_dynamic_array(proberesp_ies), 731 info->beacon.proberesp_ies, 732 info->beacon.proberesp_ies_len); 733 if (info->beacon.assocresp_ies) 734 memcpy(__get_dynamic_array(assocresp_ies), 735 info->beacon.assocresp_ies, 736 info->beacon.assocresp_ies_len); 737 if (info->beacon.probe_resp) 738 memcpy(__get_dynamic_array(probe_resp), 739 info->beacon.probe_resp, 740 info->beacon.probe_resp_len); 741 ), 742 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", link_id:%d", 743 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->link_id) 744 ); 745 746 TRACE_EVENT(rdev_stop_ap, 747 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 748 unsigned int link_id), 749 TP_ARGS(wiphy, netdev, link_id), 750 TP_STRUCT__entry( 751 WIPHY_ENTRY 752 NETDEV_ENTRY 753 __field(unsigned int, link_id) 754 ), 755 TP_fast_assign( 756 WIPHY_ASSIGN; 757 NETDEV_ASSIGN; 758 __entry->link_id = link_id; 759 ), 760 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", link_id: %d", 761 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->link_id) 762 ); 763 764 DECLARE_EVENT_CLASS(wiphy_netdev_evt, 765 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev), 766 TP_ARGS(wiphy, netdev), 767 TP_STRUCT__entry( 768 WIPHY_ENTRY 769 NETDEV_ENTRY 770 ), 771 TP_fast_assign( 772 WIPHY_ASSIGN; 773 NETDEV_ASSIGN; 774 ), 775 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT, WIPHY_PR_ARG, NETDEV_PR_ARG) 776 ); 777 778 DEFINE_EVENT(wiphy_netdev_evt, rdev_set_rekey_data, 779 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev), 780 TP_ARGS(wiphy, netdev) 781 ); 782 783 DEFINE_EVENT(wiphy_netdev_evt, rdev_get_mesh_config, 784 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev), 785 TP_ARGS(wiphy, netdev) 786 ); 787 788 DEFINE_EVENT(wiphy_netdev_evt, rdev_leave_mesh, 789 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev), 790 TP_ARGS(wiphy, netdev) 791 ); 792 793 DEFINE_EVENT(wiphy_netdev_evt, rdev_leave_ibss, 794 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev), 795 TP_ARGS(wiphy, netdev) 796 ); 797 798 DEFINE_EVENT(wiphy_netdev_evt, rdev_leave_ocb, 799 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev), 800 TP_ARGS(wiphy, netdev) 801 ); 802 803 DEFINE_EVENT(wiphy_netdev_evt, rdev_flush_pmksa, 804 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev), 805 TP_ARGS(wiphy, netdev) 806 ); 807 808 DEFINE_EVENT(wiphy_netdev_evt, rdev_end_cac, 809 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev), 810 TP_ARGS(wiphy, netdev) 811 ); 812 813 DECLARE_EVENT_CLASS(station_add_change, 814 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u8 *mac, 815 struct station_parameters *params), 816 TP_ARGS(wiphy, netdev, mac, params), 817 TP_STRUCT__entry( 818 WIPHY_ENTRY 819 NETDEV_ENTRY 820 MAC_ENTRY(sta_mac) 821 __field(u32, sta_flags_mask) 822 __field(u32, sta_flags_set) 823 __field(u32, sta_modify_mask) 824 __field(int, listen_interval) 825 __field(u16, capability) 826 __field(u16, aid) 827 __field(u8, plink_action) 828 __field(u8, plink_state) 829 __field(u8, uapsd_queues) 830 __field(u8, max_sp) 831 __field(u8, opmode_notif) 832 __field(bool, opmode_notif_used) 833 __array(u8, ht_capa, (int)sizeof(struct ieee80211_ht_cap)) 834 __array(u8, vht_capa, (int)sizeof(struct ieee80211_vht_cap)) 835 __array(char, vlan, IFNAMSIZ) 836 __dynamic_array(u8, supported_rates, 837 params->link_sta_params.supported_rates_len) 838 __dynamic_array(u8, ext_capab, params->ext_capab_len) 839 __dynamic_array(u8, supported_channels, 840 params->supported_channels_len) 841 __dynamic_array(u8, supported_oper_classes, 842 params->supported_oper_classes_len) 843 ), 844 TP_fast_assign( 845 WIPHY_ASSIGN; 846 NETDEV_ASSIGN; 847 MAC_ASSIGN(sta_mac, mac); 848 __entry->sta_flags_mask = params->sta_flags_mask; 849 __entry->sta_flags_set = params->sta_flags_set; 850 __entry->sta_modify_mask = params->sta_modify_mask; 851 __entry->listen_interval = params->listen_interval; 852 __entry->aid = params->aid; 853 __entry->plink_action = params->plink_action; 854 __entry->plink_state = params->plink_state; 855 __entry->uapsd_queues = params->uapsd_queues; 856 memset(__entry->ht_capa, 0, sizeof(struct ieee80211_ht_cap)); 857 if (params->link_sta_params.ht_capa) 858 memcpy(__entry->ht_capa, 859 params->link_sta_params.ht_capa, 860 sizeof(struct ieee80211_ht_cap)); 861 memset(__entry->vht_capa, 0, sizeof(struct ieee80211_vht_cap)); 862 if (params->link_sta_params.vht_capa) 863 memcpy(__entry->vht_capa, 864 params->link_sta_params.vht_capa, 865 sizeof(struct ieee80211_vht_cap)); 866 memset(__entry->vlan, 0, sizeof(__entry->vlan)); 867 if (params->vlan) 868 memcpy(__entry->vlan, params->vlan->name, IFNAMSIZ); 869 if (params->link_sta_params.supported_rates && 870 params->link_sta_params.supported_rates_len) 871 memcpy(__get_dynamic_array(supported_rates), 872 params->link_sta_params.supported_rates, 873 params->link_sta_params.supported_rates_len); 874 if (params->ext_capab && params->ext_capab_len) 875 memcpy(__get_dynamic_array(ext_capab), 876 params->ext_capab, 877 params->ext_capab_len); 878 if (params->supported_channels && 879 params->supported_channels_len) 880 memcpy(__get_dynamic_array(supported_channels), 881 params->supported_channels, 882 params->supported_channels_len); 883 if (params->supported_oper_classes && 884 params->supported_oper_classes_len) 885 memcpy(__get_dynamic_array(supported_oper_classes), 886 params->supported_oper_classes, 887 params->supported_oper_classes_len); 888 __entry->max_sp = params->max_sp; 889 __entry->capability = params->capability; 890 __entry->opmode_notif = params->link_sta_params.opmode_notif; 891 __entry->opmode_notif_used = 892 params->link_sta_params.opmode_notif_used; 893 ), 894 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", station mac: %pM" 895 ", station flags mask: 0x%x, station flags set: 0x%x, " 896 "station modify mask: 0x%x, listen interval: %d, aid: %u, " 897 "plink action: %u, plink state: %u, uapsd queues: %u, vlan:%s", 898 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->sta_mac, 899 __entry->sta_flags_mask, __entry->sta_flags_set, 900 __entry->sta_modify_mask, __entry->listen_interval, 901 __entry->aid, __entry->plink_action, __entry->plink_state, 902 __entry->uapsd_queues, __entry->vlan) 903 ); 904 905 DEFINE_EVENT(station_add_change, rdev_add_station, 906 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u8 *mac, 907 struct station_parameters *params), 908 TP_ARGS(wiphy, netdev, mac, params) 909 ); 910 911 DEFINE_EVENT(station_add_change, rdev_change_station, 912 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u8 *mac, 913 struct station_parameters *params), 914 TP_ARGS(wiphy, netdev, mac, params) 915 ); 916 917 DECLARE_EVENT_CLASS(wiphy_netdev_mac_evt, 918 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, const u8 *mac), 919 TP_ARGS(wiphy, netdev, mac), 920 TP_STRUCT__entry( 921 WIPHY_ENTRY 922 NETDEV_ENTRY 923 MAC_ENTRY(sta_mac) 924 ), 925 TP_fast_assign( 926 WIPHY_ASSIGN; 927 NETDEV_ASSIGN; 928 MAC_ASSIGN(sta_mac, mac); 929 ), 930 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", mac: %pM", 931 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->sta_mac) 932 ); 933 934 DECLARE_EVENT_CLASS(station_del, 935 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 936 struct station_del_parameters *params), 937 TP_ARGS(wiphy, netdev, params), 938 TP_STRUCT__entry( 939 WIPHY_ENTRY 940 NETDEV_ENTRY 941 MAC_ENTRY(sta_mac) 942 __field(u8, subtype) 943 __field(u16, reason_code) 944 __field(int, link_id) 945 ), 946 TP_fast_assign( 947 WIPHY_ASSIGN; 948 NETDEV_ASSIGN; 949 MAC_ASSIGN(sta_mac, params->mac); 950 __entry->subtype = params->subtype; 951 __entry->reason_code = params->reason_code; 952 __entry->link_id = params->link_id; 953 ), 954 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", station mac: %pM" 955 ", subtype: %u, reason_code: %u, link_id: %d", 956 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->sta_mac, 957 __entry->subtype, __entry->reason_code, 958 __entry->link_id) 959 ); 960 961 DEFINE_EVENT(station_del, rdev_del_station, 962 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 963 struct station_del_parameters *params), 964 TP_ARGS(wiphy, netdev, params) 965 ); 966 967 DEFINE_EVENT(wiphy_netdev_mac_evt, rdev_get_station, 968 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, const u8 *mac), 969 TP_ARGS(wiphy, netdev, mac) 970 ); 971 972 DEFINE_EVENT(wiphy_netdev_mac_evt, rdev_del_mpath, 973 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, const u8 *mac), 974 TP_ARGS(wiphy, netdev, mac) 975 ); 976 977 TRACE_EVENT(rdev_dump_station, 978 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int _idx, 979 u8 *mac), 980 TP_ARGS(wiphy, netdev, _idx, mac), 981 TP_STRUCT__entry( 982 WIPHY_ENTRY 983 NETDEV_ENTRY 984 MAC_ENTRY(sta_mac) 985 __field(int, idx) 986 ), 987 TP_fast_assign( 988 WIPHY_ASSIGN; 989 NETDEV_ASSIGN; 990 MAC_ASSIGN(sta_mac, mac); 991 __entry->idx = _idx; 992 ), 993 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", station mac: %pM, idx: %d", 994 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->sta_mac, 995 __entry->idx) 996 ); 997 998 TRACE_EVENT(rdev_return_int_station_info, 999 TP_PROTO(struct wiphy *wiphy, int ret, struct station_info *sinfo), 1000 TP_ARGS(wiphy, ret, sinfo), 1001 TP_STRUCT__entry( 1002 WIPHY_ENTRY 1003 __field(int, ret) 1004 SINFO_ENTRY 1005 ), 1006 TP_fast_assign( 1007 WIPHY_ASSIGN; 1008 __entry->ret = ret; 1009 SINFO_ASSIGN; 1010 ), 1011 TP_printk(WIPHY_PR_FMT ", returned %d" , 1012 WIPHY_PR_ARG, __entry->ret) 1013 ); 1014 1015 DECLARE_EVENT_CLASS(mpath_evt, 1016 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u8 *dst, 1017 u8 *next_hop), 1018 TP_ARGS(wiphy, netdev, dst, next_hop), 1019 TP_STRUCT__entry( 1020 WIPHY_ENTRY 1021 NETDEV_ENTRY 1022 MAC_ENTRY(dst) 1023 MAC_ENTRY(next_hop) 1024 ), 1025 TP_fast_assign( 1026 WIPHY_ASSIGN; 1027 NETDEV_ASSIGN; 1028 MAC_ASSIGN(dst, dst); 1029 MAC_ASSIGN(next_hop, next_hop); 1030 ), 1031 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", destination: %pM, next hop: %pM", 1032 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->dst, 1033 __entry->next_hop) 1034 ); 1035 1036 DEFINE_EVENT(mpath_evt, rdev_add_mpath, 1037 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u8 *dst, 1038 u8 *next_hop), 1039 TP_ARGS(wiphy, netdev, dst, next_hop) 1040 ); 1041 1042 DEFINE_EVENT(mpath_evt, rdev_change_mpath, 1043 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u8 *dst, 1044 u8 *next_hop), 1045 TP_ARGS(wiphy, netdev, dst, next_hop) 1046 ); 1047 1048 DEFINE_EVENT(mpath_evt, rdev_get_mpath, 1049 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u8 *dst, 1050 u8 *next_hop), 1051 TP_ARGS(wiphy, netdev, dst, next_hop) 1052 ); 1053 1054 TRACE_EVENT(rdev_dump_mpath, 1055 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int _idx, 1056 u8 *dst, u8 *next_hop), 1057 TP_ARGS(wiphy, netdev, _idx, dst, next_hop), 1058 TP_STRUCT__entry( 1059 WIPHY_ENTRY 1060 NETDEV_ENTRY 1061 MAC_ENTRY(dst) 1062 MAC_ENTRY(next_hop) 1063 __field(int, idx) 1064 ), 1065 TP_fast_assign( 1066 WIPHY_ASSIGN; 1067 NETDEV_ASSIGN; 1068 MAC_ASSIGN(dst, dst); 1069 MAC_ASSIGN(next_hop, next_hop); 1070 __entry->idx = _idx; 1071 ), 1072 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", index: %d, destination: %pM, next hop: %pM", 1073 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->idx, __entry->dst, 1074 __entry->next_hop) 1075 ); 1076 1077 TRACE_EVENT(rdev_get_mpp, 1078 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1079 u8 *dst, u8 *mpp), 1080 TP_ARGS(wiphy, netdev, dst, mpp), 1081 TP_STRUCT__entry( 1082 WIPHY_ENTRY 1083 NETDEV_ENTRY 1084 MAC_ENTRY(dst) 1085 MAC_ENTRY(mpp) 1086 ), 1087 TP_fast_assign( 1088 WIPHY_ASSIGN; 1089 NETDEV_ASSIGN; 1090 MAC_ASSIGN(dst, dst); 1091 MAC_ASSIGN(mpp, mpp); 1092 ), 1093 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", destination: %pM" 1094 ", mpp: %pM", WIPHY_PR_ARG, NETDEV_PR_ARG, 1095 __entry->dst, __entry->mpp) 1096 ); 1097 1098 TRACE_EVENT(rdev_dump_mpp, 1099 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int _idx, 1100 u8 *dst, u8 *mpp), 1101 TP_ARGS(wiphy, netdev, _idx, dst, mpp), 1102 TP_STRUCT__entry( 1103 WIPHY_ENTRY 1104 NETDEV_ENTRY 1105 MAC_ENTRY(dst) 1106 MAC_ENTRY(mpp) 1107 __field(int, idx) 1108 ), 1109 TP_fast_assign( 1110 WIPHY_ASSIGN; 1111 NETDEV_ASSIGN; 1112 MAC_ASSIGN(dst, dst); 1113 MAC_ASSIGN(mpp, mpp); 1114 __entry->idx = _idx; 1115 ), 1116 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", index: %d, destination: %pM, mpp: %pM", 1117 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->idx, __entry->dst, 1118 __entry->mpp) 1119 ); 1120 1121 TRACE_EVENT(rdev_return_int_mpath_info, 1122 TP_PROTO(struct wiphy *wiphy, int ret, struct mpath_info *pinfo), 1123 TP_ARGS(wiphy, ret, pinfo), 1124 TP_STRUCT__entry( 1125 WIPHY_ENTRY 1126 __field(int, ret) 1127 __field(int, generation) 1128 __field(u32, filled) 1129 __field(u32, frame_qlen) 1130 __field(u32, sn) 1131 __field(u32, metric) 1132 __field(u32, exptime) 1133 __field(u32, discovery_timeout) 1134 __field(u8, discovery_retries) 1135 __field(u8, flags) 1136 ), 1137 TP_fast_assign( 1138 WIPHY_ASSIGN; 1139 __entry->ret = ret; 1140 __entry->generation = pinfo->generation; 1141 __entry->filled = pinfo->filled; 1142 __entry->frame_qlen = pinfo->frame_qlen; 1143 __entry->sn = pinfo->sn; 1144 __entry->metric = pinfo->metric; 1145 __entry->exptime = pinfo->exptime; 1146 __entry->discovery_timeout = pinfo->discovery_timeout; 1147 __entry->discovery_retries = pinfo->discovery_retries; 1148 __entry->flags = pinfo->flags; 1149 ), 1150 TP_printk(WIPHY_PR_FMT ", returned %d. mpath info - generation: %d, " 1151 "filled: %u, frame qlen: %u, sn: %u, metric: %u, exptime: %u," 1152 " discovery timeout: %u, discovery retries: %u, flags: 0x%x", 1153 WIPHY_PR_ARG, __entry->ret, __entry->generation, 1154 __entry->filled, __entry->frame_qlen, __entry->sn, 1155 __entry->metric, __entry->exptime, __entry->discovery_timeout, 1156 __entry->discovery_retries, __entry->flags) 1157 ); 1158 1159 TRACE_EVENT(rdev_return_int_mesh_config, 1160 TP_PROTO(struct wiphy *wiphy, int ret, struct mesh_config *conf), 1161 TP_ARGS(wiphy, ret, conf), 1162 TP_STRUCT__entry( 1163 WIPHY_ENTRY 1164 MESH_CFG_ENTRY 1165 __field(int, ret) 1166 ), 1167 TP_fast_assign( 1168 WIPHY_ASSIGN; 1169 MESH_CFG_ASSIGN; 1170 __entry->ret = ret; 1171 ), 1172 TP_printk(WIPHY_PR_FMT ", returned: %d", 1173 WIPHY_PR_ARG, __entry->ret) 1174 ); 1175 1176 TRACE_EVENT(rdev_update_mesh_config, 1177 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u32 mask, 1178 const struct mesh_config *conf), 1179 TP_ARGS(wiphy, netdev, mask, conf), 1180 TP_STRUCT__entry( 1181 WIPHY_ENTRY 1182 NETDEV_ENTRY 1183 MESH_CFG_ENTRY 1184 __field(u32, mask) 1185 ), 1186 TP_fast_assign( 1187 WIPHY_ASSIGN; 1188 NETDEV_ASSIGN; 1189 MESH_CFG_ASSIGN; 1190 __entry->mask = mask; 1191 ), 1192 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", mask: %u", 1193 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->mask) 1194 ); 1195 1196 TRACE_EVENT(rdev_join_mesh, 1197 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1198 const struct mesh_config *conf, 1199 const struct mesh_setup *setup), 1200 TP_ARGS(wiphy, netdev, conf, setup), 1201 TP_STRUCT__entry( 1202 WIPHY_ENTRY 1203 NETDEV_ENTRY 1204 MESH_CFG_ENTRY 1205 ), 1206 TP_fast_assign( 1207 WIPHY_ASSIGN; 1208 NETDEV_ASSIGN; 1209 MESH_CFG_ASSIGN; 1210 ), 1211 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT, 1212 WIPHY_PR_ARG, NETDEV_PR_ARG) 1213 ); 1214 1215 TRACE_EVENT(rdev_change_bss, 1216 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1217 struct bss_parameters *params), 1218 TP_ARGS(wiphy, netdev, params), 1219 TP_STRUCT__entry( 1220 WIPHY_ENTRY 1221 NETDEV_ENTRY 1222 __field(int, use_cts_prot) 1223 __field(int, use_short_preamble) 1224 __field(int, use_short_slot_time) 1225 __field(int, ap_isolate) 1226 __field(int, ht_opmode) 1227 ), 1228 TP_fast_assign( 1229 WIPHY_ASSIGN; 1230 NETDEV_ASSIGN; 1231 __entry->use_cts_prot = params->use_cts_prot; 1232 __entry->use_short_preamble = params->use_short_preamble; 1233 __entry->use_short_slot_time = params->use_short_slot_time; 1234 __entry->ap_isolate = params->ap_isolate; 1235 __entry->ht_opmode = params->ht_opmode; 1236 ), 1237 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", use cts prot: %d, " 1238 "use short preamble: %d, use short slot time: %d, " 1239 "ap isolate: %d, ht opmode: %d", 1240 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->use_cts_prot, 1241 __entry->use_short_preamble, __entry->use_short_slot_time, 1242 __entry->ap_isolate, __entry->ht_opmode) 1243 ); 1244 1245 TRACE_EVENT(rdev_inform_bss, 1246 TP_PROTO(struct wiphy *wiphy, struct cfg80211_bss *bss), 1247 TP_ARGS(wiphy, bss), 1248 TP_STRUCT__entry( 1249 WIPHY_ENTRY 1250 MAC_ENTRY(bssid) 1251 CHAN_ENTRY 1252 ), 1253 TP_fast_assign( 1254 WIPHY_ASSIGN; 1255 MAC_ASSIGN(bssid, bss->bssid); 1256 CHAN_ASSIGN(bss->channel); 1257 ), 1258 TP_printk(WIPHY_PR_FMT ", %pM, " CHAN_PR_FMT, 1259 WIPHY_PR_ARG, __entry->bssid, CHAN_PR_ARG) 1260 ); 1261 1262 TRACE_EVENT(rdev_set_txq_params, 1263 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1264 struct ieee80211_txq_params *params), 1265 TP_ARGS(wiphy, netdev, params), 1266 TP_STRUCT__entry( 1267 WIPHY_ENTRY 1268 NETDEV_ENTRY 1269 __field(enum nl80211_ac, ac) 1270 __field(u16, txop) 1271 __field(u16, cwmin) 1272 __field(u16, cwmax) 1273 __field(u8, aifs) 1274 ), 1275 TP_fast_assign( 1276 WIPHY_ASSIGN; 1277 NETDEV_ASSIGN; 1278 __entry->ac = params->ac; 1279 __entry->txop = params->txop; 1280 __entry->cwmin = params->cwmin; 1281 __entry->cwmax = params->cwmax; 1282 __entry->aifs = params->aifs; 1283 ), 1284 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", ac: %d, txop: %u, cwmin: %u, cwmax: %u, aifs: %u", 1285 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->ac, __entry->txop, 1286 __entry->cwmin, __entry->cwmax, __entry->aifs) 1287 ); 1288 1289 TRACE_EVENT(rdev_libertas_set_mesh_channel, 1290 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1291 struct ieee80211_channel *chan), 1292 TP_ARGS(wiphy, netdev, chan), 1293 TP_STRUCT__entry( 1294 WIPHY_ENTRY 1295 NETDEV_ENTRY 1296 CHAN_ENTRY 1297 ), 1298 TP_fast_assign( 1299 WIPHY_ASSIGN; 1300 NETDEV_ASSIGN; 1301 CHAN_ASSIGN(chan); 1302 ), 1303 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", " CHAN_PR_FMT, WIPHY_PR_ARG, 1304 NETDEV_PR_ARG, CHAN_PR_ARG) 1305 ); 1306 1307 TRACE_EVENT(rdev_set_monitor_channel, 1308 TP_PROTO(struct wiphy *wiphy, 1309 struct cfg80211_chan_def *chandef), 1310 TP_ARGS(wiphy, chandef), 1311 TP_STRUCT__entry( 1312 WIPHY_ENTRY 1313 CHAN_DEF_ENTRY 1314 ), 1315 TP_fast_assign( 1316 WIPHY_ASSIGN; 1317 CHAN_DEF_ASSIGN(chandef); 1318 ), 1319 TP_printk(WIPHY_PR_FMT ", " CHAN_DEF_PR_FMT, 1320 WIPHY_PR_ARG, CHAN_DEF_PR_ARG) 1321 ); 1322 1323 TRACE_EVENT(rdev_auth, 1324 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1325 struct cfg80211_auth_request *req), 1326 TP_ARGS(wiphy, netdev, req), 1327 TP_STRUCT__entry( 1328 WIPHY_ENTRY 1329 NETDEV_ENTRY 1330 MAC_ENTRY(bssid) 1331 __field(enum nl80211_auth_type, auth_type) 1332 ), 1333 TP_fast_assign( 1334 WIPHY_ASSIGN; 1335 NETDEV_ASSIGN; 1336 if (req->bss) 1337 MAC_ASSIGN(bssid, req->bss->bssid); 1338 else 1339 eth_zero_addr(__entry->bssid); 1340 __entry->auth_type = req->auth_type; 1341 ), 1342 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", auth type: %d, bssid: %pM", 1343 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->auth_type, 1344 __entry->bssid) 1345 ); 1346 1347 TRACE_EVENT(rdev_assoc, 1348 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1349 struct cfg80211_assoc_request *req), 1350 TP_ARGS(wiphy, netdev, req), 1351 TP_STRUCT__entry( 1352 WIPHY_ENTRY 1353 NETDEV_ENTRY 1354 MAC_ENTRY(bssid) 1355 MAC_ENTRY(prev_bssid) 1356 __field(bool, use_mfp) 1357 __field(u32, flags) 1358 __dynamic_array(u8, elements, req->ie_len) 1359 __array(u8, ht_capa, sizeof(struct ieee80211_ht_cap)) 1360 __array(u8, ht_capa_mask, sizeof(struct ieee80211_ht_cap)) 1361 __array(u8, vht_capa, sizeof(struct ieee80211_vht_cap)) 1362 __array(u8, vht_capa_mask, sizeof(struct ieee80211_vht_cap)) 1363 __dynamic_array(u8, fils_kek, req->fils_kek_len) 1364 __dynamic_array(u8, fils_nonces, 1365 req->fils_nonces ? 2 * FILS_NONCE_LEN : 0) 1366 ), 1367 TP_fast_assign( 1368 WIPHY_ASSIGN; 1369 NETDEV_ASSIGN; 1370 if (req->bss) 1371 MAC_ASSIGN(bssid, req->bss->bssid); 1372 else 1373 eth_zero_addr(__entry->bssid); 1374 MAC_ASSIGN(prev_bssid, req->prev_bssid); 1375 __entry->use_mfp = req->use_mfp; 1376 __entry->flags = req->flags; 1377 if (req->ie) 1378 memcpy(__get_dynamic_array(elements), 1379 req->ie, req->ie_len); 1380 memcpy(__entry->ht_capa, &req->ht_capa, sizeof(req->ht_capa)); 1381 memcpy(__entry->ht_capa_mask, &req->ht_capa_mask, 1382 sizeof(req->ht_capa_mask)); 1383 memcpy(__entry->vht_capa, &req->vht_capa, sizeof(req->vht_capa)); 1384 memcpy(__entry->vht_capa_mask, &req->vht_capa_mask, 1385 sizeof(req->vht_capa_mask)); 1386 if (req->fils_kek) 1387 memcpy(__get_dynamic_array(fils_kek), 1388 req->fils_kek, req->fils_kek_len); 1389 if (req->fils_nonces) 1390 memcpy(__get_dynamic_array(fils_nonces), 1391 req->fils_nonces, 2 * FILS_NONCE_LEN); 1392 ), 1393 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", bssid: %pM" 1394 ", previous bssid: %pM, use mfp: %s, flags: 0x%x", 1395 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->bssid, 1396 __entry->prev_bssid, BOOL_TO_STR(__entry->use_mfp), 1397 __entry->flags) 1398 ); 1399 1400 TRACE_EVENT(rdev_deauth, 1401 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1402 struct cfg80211_deauth_request *req), 1403 TP_ARGS(wiphy, netdev, req), 1404 TP_STRUCT__entry( 1405 WIPHY_ENTRY 1406 NETDEV_ENTRY 1407 MAC_ENTRY(bssid) 1408 __field(u16, reason_code) 1409 __field(bool, local_state_change) 1410 ), 1411 TP_fast_assign( 1412 WIPHY_ASSIGN; 1413 NETDEV_ASSIGN; 1414 MAC_ASSIGN(bssid, req->bssid); 1415 __entry->reason_code = req->reason_code; 1416 __entry->local_state_change = req->local_state_change; 1417 ), 1418 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", bssid: %pM, reason: %u, local_state_change:%d", 1419 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->bssid, 1420 __entry->reason_code, __entry->local_state_change) 1421 ); 1422 1423 TRACE_EVENT(rdev_disassoc, 1424 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1425 struct cfg80211_disassoc_request *req), 1426 TP_ARGS(wiphy, netdev, req), 1427 TP_STRUCT__entry( 1428 WIPHY_ENTRY 1429 NETDEV_ENTRY 1430 MAC_ENTRY(bssid) 1431 __field(u16, reason_code) 1432 __field(bool, local_state_change) 1433 ), 1434 TP_fast_assign( 1435 WIPHY_ASSIGN; 1436 NETDEV_ASSIGN; 1437 MAC_ASSIGN(bssid, req->ap_addr); 1438 __entry->reason_code = req->reason_code; 1439 __entry->local_state_change = req->local_state_change; 1440 ), 1441 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", bssid: %pM" 1442 ", reason: %u, local state change: %s", 1443 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->bssid, 1444 __entry->reason_code, 1445 BOOL_TO_STR(__entry->local_state_change)) 1446 ); 1447 1448 TRACE_EVENT(rdev_mgmt_tx_cancel_wait, 1449 TP_PROTO(struct wiphy *wiphy, 1450 struct wireless_dev *wdev, u64 cookie), 1451 TP_ARGS(wiphy, wdev, cookie), 1452 TP_STRUCT__entry( 1453 WIPHY_ENTRY 1454 WDEV_ENTRY 1455 __field(u64, cookie) 1456 ), 1457 TP_fast_assign( 1458 WIPHY_ASSIGN; 1459 WDEV_ASSIGN; 1460 __entry->cookie = cookie; 1461 ), 1462 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", cookie: %llu ", 1463 WIPHY_PR_ARG, WDEV_PR_ARG, __entry->cookie) 1464 ); 1465 1466 TRACE_EVENT(rdev_set_power_mgmt, 1467 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1468 bool enabled, int timeout), 1469 TP_ARGS(wiphy, netdev, enabled, timeout), 1470 TP_STRUCT__entry( 1471 WIPHY_ENTRY 1472 NETDEV_ENTRY 1473 __field(bool, enabled) 1474 __field(int, timeout) 1475 ), 1476 TP_fast_assign( 1477 WIPHY_ASSIGN; 1478 NETDEV_ASSIGN; 1479 __entry->enabled = enabled; 1480 __entry->timeout = timeout; 1481 ), 1482 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %senabled, timeout: %d ", 1483 WIPHY_PR_ARG, NETDEV_PR_ARG, 1484 __entry->enabled ? "" : "not ", __entry->timeout) 1485 ); 1486 1487 TRACE_EVENT(rdev_connect, 1488 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1489 struct cfg80211_connect_params *sme), 1490 TP_ARGS(wiphy, netdev, sme), 1491 TP_STRUCT__entry( 1492 WIPHY_ENTRY 1493 NETDEV_ENTRY 1494 MAC_ENTRY(bssid) 1495 __array(char, ssid, IEEE80211_MAX_SSID_LEN + 1) 1496 __field(enum nl80211_auth_type, auth_type) 1497 __field(bool, privacy) 1498 __field(u32, wpa_versions) 1499 __field(u32, flags) 1500 MAC_ENTRY(prev_bssid) 1501 ), 1502 TP_fast_assign( 1503 WIPHY_ASSIGN; 1504 NETDEV_ASSIGN; 1505 MAC_ASSIGN(bssid, sme->bssid); 1506 memset(__entry->ssid, 0, IEEE80211_MAX_SSID_LEN + 1); 1507 memcpy(__entry->ssid, sme->ssid, sme->ssid_len); 1508 __entry->auth_type = sme->auth_type; 1509 __entry->privacy = sme->privacy; 1510 __entry->wpa_versions = sme->crypto.wpa_versions; 1511 __entry->flags = sme->flags; 1512 MAC_ASSIGN(prev_bssid, sme->prev_bssid); 1513 ), 1514 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", bssid: %pM" 1515 ", ssid: %s, auth type: %d, privacy: %s, wpa versions: %u, " 1516 "flags: 0x%x, previous bssid: %pM", 1517 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->bssid, __entry->ssid, 1518 __entry->auth_type, BOOL_TO_STR(__entry->privacy), 1519 __entry->wpa_versions, __entry->flags, __entry->prev_bssid) 1520 ); 1521 1522 TRACE_EVENT(rdev_update_connect_params, 1523 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1524 struct cfg80211_connect_params *sme, u32 changed), 1525 TP_ARGS(wiphy, netdev, sme, changed), 1526 TP_STRUCT__entry( 1527 WIPHY_ENTRY 1528 NETDEV_ENTRY 1529 __field(u32, changed) 1530 ), 1531 TP_fast_assign( 1532 WIPHY_ASSIGN; 1533 NETDEV_ASSIGN; 1534 __entry->changed = changed; 1535 ), 1536 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", parameters changed: %u", 1537 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->changed) 1538 ); 1539 1540 TRACE_EVENT(rdev_set_cqm_rssi_config, 1541 TP_PROTO(struct wiphy *wiphy, 1542 struct net_device *netdev, s32 rssi_thold, 1543 u32 rssi_hyst), 1544 TP_ARGS(wiphy, netdev, rssi_thold, rssi_hyst), 1545 TP_STRUCT__entry( 1546 WIPHY_ENTRY 1547 NETDEV_ENTRY 1548 __field(s32, rssi_thold) 1549 __field(u32, rssi_hyst) 1550 ), 1551 TP_fast_assign( 1552 WIPHY_ASSIGN; 1553 NETDEV_ASSIGN; 1554 __entry->rssi_thold = rssi_thold; 1555 __entry->rssi_hyst = rssi_hyst; 1556 ), 1557 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT 1558 ", rssi_thold: %d, rssi_hyst: %u ", 1559 WIPHY_PR_ARG, NETDEV_PR_ARG, 1560 __entry->rssi_thold, __entry->rssi_hyst) 1561 ); 1562 1563 TRACE_EVENT(rdev_set_cqm_rssi_range_config, 1564 TP_PROTO(struct wiphy *wiphy, 1565 struct net_device *netdev, s32 low, s32 high), 1566 TP_ARGS(wiphy, netdev, low, high), 1567 TP_STRUCT__entry( 1568 WIPHY_ENTRY 1569 NETDEV_ENTRY 1570 __field(s32, rssi_low) 1571 __field(s32, rssi_high) 1572 ), 1573 TP_fast_assign( 1574 WIPHY_ASSIGN; 1575 NETDEV_ASSIGN; 1576 __entry->rssi_low = low; 1577 __entry->rssi_high = high; 1578 ), 1579 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT 1580 ", range: %d - %d ", 1581 WIPHY_PR_ARG, NETDEV_PR_ARG, 1582 __entry->rssi_low, __entry->rssi_high) 1583 ); 1584 1585 TRACE_EVENT(rdev_set_cqm_txe_config, 1586 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u32 rate, 1587 u32 pkts, u32 intvl), 1588 TP_ARGS(wiphy, netdev, rate, pkts, intvl), 1589 TP_STRUCT__entry( 1590 WIPHY_ENTRY 1591 NETDEV_ENTRY 1592 __field(u32, rate) 1593 __field(u32, pkts) 1594 __field(u32, intvl) 1595 ), 1596 TP_fast_assign( 1597 WIPHY_ASSIGN; 1598 NETDEV_ASSIGN; 1599 __entry->rate = rate; 1600 __entry->pkts = pkts; 1601 __entry->intvl = intvl; 1602 ), 1603 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", rate: %u, packets: %u, interval: %u", 1604 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->rate, __entry->pkts, 1605 __entry->intvl) 1606 ); 1607 1608 TRACE_EVENT(rdev_disconnect, 1609 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1610 u16 reason_code), 1611 TP_ARGS(wiphy, netdev, reason_code), 1612 TP_STRUCT__entry( 1613 WIPHY_ENTRY 1614 NETDEV_ENTRY 1615 __field(u16, reason_code) 1616 ), 1617 TP_fast_assign( 1618 WIPHY_ASSIGN; 1619 NETDEV_ASSIGN; 1620 __entry->reason_code = reason_code; 1621 ), 1622 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", reason code: %u", WIPHY_PR_ARG, 1623 NETDEV_PR_ARG, __entry->reason_code) 1624 ); 1625 1626 TRACE_EVENT(rdev_join_ibss, 1627 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1628 struct cfg80211_ibss_params *params), 1629 TP_ARGS(wiphy, netdev, params), 1630 TP_STRUCT__entry( 1631 WIPHY_ENTRY 1632 NETDEV_ENTRY 1633 MAC_ENTRY(bssid) 1634 __array(char, ssid, IEEE80211_MAX_SSID_LEN + 1) 1635 ), 1636 TP_fast_assign( 1637 WIPHY_ASSIGN; 1638 NETDEV_ASSIGN; 1639 MAC_ASSIGN(bssid, params->bssid); 1640 memset(__entry->ssid, 0, IEEE80211_MAX_SSID_LEN + 1); 1641 memcpy(__entry->ssid, params->ssid, params->ssid_len); 1642 ), 1643 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", bssid: %pM, ssid: %s", 1644 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->bssid, __entry->ssid) 1645 ); 1646 1647 TRACE_EVENT(rdev_join_ocb, 1648 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1649 const struct ocb_setup *setup), 1650 TP_ARGS(wiphy, netdev, setup), 1651 TP_STRUCT__entry( 1652 WIPHY_ENTRY 1653 NETDEV_ENTRY 1654 ), 1655 TP_fast_assign( 1656 WIPHY_ASSIGN; 1657 NETDEV_ASSIGN; 1658 ), 1659 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT, 1660 WIPHY_PR_ARG, NETDEV_PR_ARG) 1661 ); 1662 1663 TRACE_EVENT(rdev_set_wiphy_params, 1664 TP_PROTO(struct wiphy *wiphy, u32 changed), 1665 TP_ARGS(wiphy, changed), 1666 TP_STRUCT__entry( 1667 WIPHY_ENTRY 1668 __field(u32, changed) 1669 ), 1670 TP_fast_assign( 1671 WIPHY_ASSIGN; 1672 __entry->changed = changed; 1673 ), 1674 TP_printk(WIPHY_PR_FMT ", changed: %u", 1675 WIPHY_PR_ARG, __entry->changed) 1676 ); 1677 1678 DEFINE_EVENT(wiphy_wdev_evt, rdev_get_tx_power, 1679 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 1680 TP_ARGS(wiphy, wdev) 1681 ); 1682 1683 TRACE_EVENT(rdev_set_tx_power, 1684 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 1685 enum nl80211_tx_power_setting type, int mbm), 1686 TP_ARGS(wiphy, wdev, type, mbm), 1687 TP_STRUCT__entry( 1688 WIPHY_ENTRY 1689 WDEV_ENTRY 1690 __field(enum nl80211_tx_power_setting, type) 1691 __field(int, mbm) 1692 ), 1693 TP_fast_assign( 1694 WIPHY_ASSIGN; 1695 WDEV_ASSIGN; 1696 __entry->type = type; 1697 __entry->mbm = mbm; 1698 ), 1699 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", type: %u, mbm: %d", 1700 WIPHY_PR_ARG, WDEV_PR_ARG,__entry->type, __entry->mbm) 1701 ); 1702 1703 TRACE_EVENT(rdev_return_int_int, 1704 TP_PROTO(struct wiphy *wiphy, int func_ret, int func_fill), 1705 TP_ARGS(wiphy, func_ret, func_fill), 1706 TP_STRUCT__entry( 1707 WIPHY_ENTRY 1708 __field(int, func_ret) 1709 __field(int, func_fill) 1710 ), 1711 TP_fast_assign( 1712 WIPHY_ASSIGN; 1713 __entry->func_ret = func_ret; 1714 __entry->func_fill = func_fill; 1715 ), 1716 TP_printk(WIPHY_PR_FMT ", function returns: %d, function filled: %d", 1717 WIPHY_PR_ARG, __entry->func_ret, __entry->func_fill) 1718 ); 1719 1720 #ifdef CONFIG_NL80211_TESTMODE 1721 TRACE_EVENT(rdev_testmode_cmd, 1722 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 1723 TP_ARGS(wiphy, wdev), 1724 TP_STRUCT__entry( 1725 WIPHY_ENTRY 1726 WDEV_ENTRY 1727 ), 1728 TP_fast_assign( 1729 WIPHY_ASSIGN; 1730 WDEV_ASSIGN; 1731 ), 1732 TP_printk(WIPHY_PR_FMT WDEV_PR_FMT, WIPHY_PR_ARG, WDEV_PR_ARG) 1733 ); 1734 1735 TRACE_EVENT(rdev_testmode_dump, 1736 TP_PROTO(struct wiphy *wiphy), 1737 TP_ARGS(wiphy), 1738 TP_STRUCT__entry( 1739 WIPHY_ENTRY 1740 ), 1741 TP_fast_assign( 1742 WIPHY_ASSIGN; 1743 ), 1744 TP_printk(WIPHY_PR_FMT, WIPHY_PR_ARG) 1745 ); 1746 #endif /* CONFIG_NL80211_TESTMODE */ 1747 1748 TRACE_EVENT(rdev_set_bitrate_mask, 1749 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1750 unsigned int link_id, 1751 const u8 *peer, const struct cfg80211_bitrate_mask *mask), 1752 TP_ARGS(wiphy, netdev, link_id, peer, mask), 1753 TP_STRUCT__entry( 1754 WIPHY_ENTRY 1755 NETDEV_ENTRY 1756 __field(unsigned int, link_id) 1757 MAC_ENTRY(peer) 1758 ), 1759 TP_fast_assign( 1760 WIPHY_ASSIGN; 1761 NETDEV_ASSIGN; 1762 __entry->link_id = link_id; 1763 MAC_ASSIGN(peer, peer); 1764 ), 1765 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", link_id: %d, peer: %pM", 1766 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->link_id, 1767 __entry->peer) 1768 ); 1769 1770 TRACE_EVENT(rdev_update_mgmt_frame_registrations, 1771 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 1772 struct mgmt_frame_regs *upd), 1773 TP_ARGS(wiphy, wdev, upd), 1774 TP_STRUCT__entry( 1775 WIPHY_ENTRY 1776 WDEV_ENTRY 1777 __field(u16, global_stypes) 1778 __field(u16, interface_stypes) 1779 ), 1780 TP_fast_assign( 1781 WIPHY_ASSIGN; 1782 WDEV_ASSIGN; 1783 __entry->global_stypes = upd->global_stypes; 1784 __entry->interface_stypes = upd->interface_stypes; 1785 ), 1786 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", global: 0x%.2x, intf: 0x%.2x", 1787 WIPHY_PR_ARG, WDEV_PR_ARG, 1788 __entry->global_stypes, __entry->interface_stypes) 1789 ); 1790 1791 TRACE_EVENT(rdev_return_int_tx_rx, 1792 TP_PROTO(struct wiphy *wiphy, int ret, u32 tx, u32 rx), 1793 TP_ARGS(wiphy, ret, tx, rx), 1794 TP_STRUCT__entry( 1795 WIPHY_ENTRY 1796 __field(int, ret) 1797 __field(u32, tx) 1798 __field(u32, rx) 1799 ), 1800 TP_fast_assign( 1801 WIPHY_ASSIGN; 1802 __entry->ret = ret; 1803 __entry->tx = tx; 1804 __entry->rx = rx; 1805 ), 1806 TP_printk(WIPHY_PR_FMT ", returned %d, tx: %u, rx: %u", 1807 WIPHY_PR_ARG, __entry->ret, __entry->tx, __entry->rx) 1808 ); 1809 1810 TRACE_EVENT(rdev_return_void_tx_rx, 1811 TP_PROTO(struct wiphy *wiphy, u32 tx, u32 tx_max, 1812 u32 rx, u32 rx_max), 1813 TP_ARGS(wiphy, tx, tx_max, rx, rx_max), 1814 TP_STRUCT__entry( 1815 WIPHY_ENTRY 1816 __field(u32, tx) 1817 __field(u32, tx_max) 1818 __field(u32, rx) 1819 __field(u32, rx_max) 1820 ), 1821 TP_fast_assign( 1822 WIPHY_ASSIGN; 1823 __entry->tx = tx; 1824 __entry->tx_max = tx_max; 1825 __entry->rx = rx; 1826 __entry->rx_max = rx_max; 1827 ), 1828 TP_printk(WIPHY_PR_FMT ", tx: %u, tx_max: %u, rx: %u, rx_max: %u ", 1829 WIPHY_PR_ARG, __entry->tx, __entry->tx_max, __entry->rx, 1830 __entry->rx_max) 1831 ); 1832 1833 DECLARE_EVENT_CLASS(tx_rx_evt, 1834 TP_PROTO(struct wiphy *wiphy, u32 tx, u32 rx), 1835 TP_ARGS(wiphy, tx, rx), 1836 TP_STRUCT__entry( 1837 WIPHY_ENTRY 1838 __field(u32, tx) 1839 __field(u32, rx) 1840 ), 1841 TP_fast_assign( 1842 WIPHY_ASSIGN; 1843 __entry->tx = tx; 1844 __entry->rx = rx; 1845 ), 1846 TP_printk(WIPHY_PR_FMT ", tx: %u, rx: %u ", 1847 WIPHY_PR_ARG, __entry->tx, __entry->rx) 1848 ); 1849 1850 DEFINE_EVENT(tx_rx_evt, rdev_set_antenna, 1851 TP_PROTO(struct wiphy *wiphy, u32 tx, u32 rx), 1852 TP_ARGS(wiphy, tx, rx) 1853 ); 1854 1855 DECLARE_EVENT_CLASS(wiphy_netdev_id_evt, 1856 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u64 id), 1857 TP_ARGS(wiphy, netdev, id), 1858 TP_STRUCT__entry( 1859 WIPHY_ENTRY 1860 NETDEV_ENTRY 1861 __field(u64, id) 1862 ), 1863 TP_fast_assign( 1864 WIPHY_ASSIGN; 1865 NETDEV_ASSIGN; 1866 __entry->id = id; 1867 ), 1868 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", id: %llu", 1869 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->id) 1870 ); 1871 1872 DEFINE_EVENT(wiphy_netdev_id_evt, rdev_sched_scan_start, 1873 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u64 id), 1874 TP_ARGS(wiphy, netdev, id) 1875 ); 1876 1877 DEFINE_EVENT(wiphy_netdev_id_evt, rdev_sched_scan_stop, 1878 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, u64 id), 1879 TP_ARGS(wiphy, netdev, id) 1880 ); 1881 1882 TRACE_EVENT(rdev_tdls_mgmt, 1883 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1884 u8 *peer, int link_id, u8 action_code, u8 dialog_token, 1885 u16 status_code, u32 peer_capability, 1886 bool initiator, const u8 *buf, size_t len), 1887 TP_ARGS(wiphy, netdev, peer, link_id, action_code, dialog_token, 1888 status_code, peer_capability, initiator, buf, len), 1889 TP_STRUCT__entry( 1890 WIPHY_ENTRY 1891 NETDEV_ENTRY 1892 MAC_ENTRY(peer) 1893 __field(int, link_id) 1894 __field(u8, action_code) 1895 __field(u8, dialog_token) 1896 __field(u16, status_code) 1897 __field(u32, peer_capability) 1898 __field(bool, initiator) 1899 __dynamic_array(u8, buf, len) 1900 ), 1901 TP_fast_assign( 1902 WIPHY_ASSIGN; 1903 NETDEV_ASSIGN; 1904 MAC_ASSIGN(peer, peer); 1905 __entry->link_id = link_id; 1906 __entry->action_code = action_code; 1907 __entry->dialog_token = dialog_token; 1908 __entry->status_code = status_code; 1909 __entry->peer_capability = peer_capability; 1910 __entry->initiator = initiator; 1911 memcpy(__get_dynamic_array(buf), buf, len); 1912 ), 1913 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %pM" 1914 ", link_id: %d, action_code: %u " 1915 "dialog_token: %u, status_code: %u, peer_capability: %u " 1916 "initiator: %s buf: %#.2x ", 1917 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->peer, 1918 __entry->link_id, __entry->action_code, __entry->dialog_token, 1919 __entry->status_code, __entry->peer_capability, 1920 BOOL_TO_STR(__entry->initiator), 1921 ((u8 *)__get_dynamic_array(buf))[0]) 1922 ); 1923 1924 TRACE_EVENT(rdev_dump_survey, 1925 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int _idx), 1926 TP_ARGS(wiphy, netdev, _idx), 1927 TP_STRUCT__entry( 1928 WIPHY_ENTRY 1929 NETDEV_ENTRY 1930 __field(int, idx) 1931 ), 1932 TP_fast_assign( 1933 WIPHY_ASSIGN; 1934 NETDEV_ASSIGN; 1935 __entry->idx = _idx; 1936 ), 1937 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", index: %d", 1938 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->idx) 1939 ); 1940 1941 TRACE_EVENT(rdev_return_int_survey_info, 1942 TP_PROTO(struct wiphy *wiphy, int ret, struct survey_info *info), 1943 TP_ARGS(wiphy, ret, info), 1944 TP_STRUCT__entry( 1945 WIPHY_ENTRY 1946 CHAN_ENTRY 1947 __field(int, ret) 1948 __field(u64, time) 1949 __field(u64, time_busy) 1950 __field(u64, time_ext_busy) 1951 __field(u64, time_rx) 1952 __field(u64, time_tx) 1953 __field(u64, time_scan) 1954 __field(u32, filled) 1955 __field(s8, noise) 1956 ), 1957 TP_fast_assign( 1958 WIPHY_ASSIGN; 1959 CHAN_ASSIGN(info->channel); 1960 __entry->ret = ret; 1961 __entry->time = info->time; 1962 __entry->time_busy = info->time_busy; 1963 __entry->time_ext_busy = info->time_ext_busy; 1964 __entry->time_rx = info->time_rx; 1965 __entry->time_tx = info->time_tx; 1966 __entry->time_scan = info->time_scan; 1967 __entry->filled = info->filled; 1968 __entry->noise = info->noise; 1969 ), 1970 TP_printk(WIPHY_PR_FMT ", returned: %d, " CHAN_PR_FMT 1971 ", channel time: %llu, channel time busy: %llu, " 1972 "channel time extension busy: %llu, channel time rx: %llu, " 1973 "channel time tx: %llu, scan time: %llu, filled: %u, noise: %d", 1974 WIPHY_PR_ARG, __entry->ret, CHAN_PR_ARG, 1975 __entry->time, __entry->time_busy, 1976 __entry->time_ext_busy, __entry->time_rx, 1977 __entry->time_tx, __entry->time_scan, 1978 __entry->filled, __entry->noise) 1979 ); 1980 1981 TRACE_EVENT(rdev_tdls_oper, 1982 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 1983 u8 *peer, enum nl80211_tdls_operation oper), 1984 TP_ARGS(wiphy, netdev, peer, oper), 1985 TP_STRUCT__entry( 1986 WIPHY_ENTRY 1987 NETDEV_ENTRY 1988 MAC_ENTRY(peer) 1989 __field(enum nl80211_tdls_operation, oper) 1990 ), 1991 TP_fast_assign( 1992 WIPHY_ASSIGN; 1993 NETDEV_ASSIGN; 1994 MAC_ASSIGN(peer, peer); 1995 __entry->oper = oper; 1996 ), 1997 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %pM, oper: %d", 1998 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->peer, __entry->oper) 1999 ); 2000 2001 DECLARE_EVENT_CLASS(rdev_pmksa, 2002 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2003 struct cfg80211_pmksa *pmksa), 2004 TP_ARGS(wiphy, netdev, pmksa), 2005 TP_STRUCT__entry( 2006 WIPHY_ENTRY 2007 NETDEV_ENTRY 2008 MAC_ENTRY(bssid) 2009 ), 2010 TP_fast_assign( 2011 WIPHY_ASSIGN; 2012 NETDEV_ASSIGN; 2013 MAC_ASSIGN(bssid, pmksa->bssid); 2014 ), 2015 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", bssid: %pM", 2016 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->bssid) 2017 ); 2018 2019 TRACE_EVENT(rdev_probe_client, 2020 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2021 const u8 *peer), 2022 TP_ARGS(wiphy, netdev, peer), 2023 TP_STRUCT__entry( 2024 WIPHY_ENTRY 2025 NETDEV_ENTRY 2026 MAC_ENTRY(peer) 2027 ), 2028 TP_fast_assign( 2029 WIPHY_ASSIGN; 2030 NETDEV_ASSIGN; 2031 MAC_ASSIGN(peer, peer); 2032 ), 2033 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %pM", 2034 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->peer) 2035 ); 2036 2037 DEFINE_EVENT(rdev_pmksa, rdev_set_pmksa, 2038 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2039 struct cfg80211_pmksa *pmksa), 2040 TP_ARGS(wiphy, netdev, pmksa) 2041 ); 2042 2043 DEFINE_EVENT(rdev_pmksa, rdev_del_pmksa, 2044 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2045 struct cfg80211_pmksa *pmksa), 2046 TP_ARGS(wiphy, netdev, pmksa) 2047 ); 2048 2049 TRACE_EVENT(rdev_remain_on_channel, 2050 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 2051 struct ieee80211_channel *chan, 2052 unsigned int duration), 2053 TP_ARGS(wiphy, wdev, chan, duration), 2054 TP_STRUCT__entry( 2055 WIPHY_ENTRY 2056 WDEV_ENTRY 2057 CHAN_ENTRY 2058 __field(unsigned int, duration) 2059 ), 2060 TP_fast_assign( 2061 WIPHY_ASSIGN; 2062 WDEV_ASSIGN; 2063 CHAN_ASSIGN(chan); 2064 __entry->duration = duration; 2065 ), 2066 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", " CHAN_PR_FMT ", duration: %u", 2067 WIPHY_PR_ARG, WDEV_PR_ARG, CHAN_PR_ARG, __entry->duration) 2068 ); 2069 2070 TRACE_EVENT(rdev_return_int_cookie, 2071 TP_PROTO(struct wiphy *wiphy, int ret, u64 cookie), 2072 TP_ARGS(wiphy, ret, cookie), 2073 TP_STRUCT__entry( 2074 WIPHY_ENTRY 2075 __field(int, ret) 2076 __field(u64, cookie) 2077 ), 2078 TP_fast_assign( 2079 WIPHY_ASSIGN; 2080 __entry->ret = ret; 2081 __entry->cookie = cookie; 2082 ), 2083 TP_printk(WIPHY_PR_FMT ", returned %d, cookie: %llu", 2084 WIPHY_PR_ARG, __entry->ret, __entry->cookie) 2085 ); 2086 2087 TRACE_EVENT(rdev_cancel_remain_on_channel, 2088 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, u64 cookie), 2089 TP_ARGS(wiphy, wdev, cookie), 2090 TP_STRUCT__entry( 2091 WIPHY_ENTRY 2092 WDEV_ENTRY 2093 __field(u64, cookie) 2094 ), 2095 TP_fast_assign( 2096 WIPHY_ASSIGN; 2097 WDEV_ASSIGN; 2098 __entry->cookie = cookie; 2099 ), 2100 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", cookie: %llu", 2101 WIPHY_PR_ARG, WDEV_PR_ARG, __entry->cookie) 2102 ); 2103 2104 TRACE_EVENT(rdev_mgmt_tx, 2105 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 2106 struct cfg80211_mgmt_tx_params *params), 2107 TP_ARGS(wiphy, wdev, params), 2108 TP_STRUCT__entry( 2109 WIPHY_ENTRY 2110 WDEV_ENTRY 2111 CHAN_ENTRY 2112 __field(bool, offchan) 2113 __field(unsigned int, wait) 2114 __field(bool, no_cck) 2115 __field(bool, dont_wait_for_ack) 2116 ), 2117 TP_fast_assign( 2118 WIPHY_ASSIGN; 2119 WDEV_ASSIGN; 2120 CHAN_ASSIGN(params->chan); 2121 __entry->offchan = params->offchan; 2122 __entry->wait = params->wait; 2123 __entry->no_cck = params->no_cck; 2124 __entry->dont_wait_for_ack = params->dont_wait_for_ack; 2125 ), 2126 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", " CHAN_PR_FMT ", offchan: %s," 2127 " wait: %u, no cck: %s, dont wait for ack: %s", 2128 WIPHY_PR_ARG, WDEV_PR_ARG, CHAN_PR_ARG, 2129 BOOL_TO_STR(__entry->offchan), __entry->wait, 2130 BOOL_TO_STR(__entry->no_cck), 2131 BOOL_TO_STR(__entry->dont_wait_for_ack)) 2132 ); 2133 2134 TRACE_EVENT(rdev_tx_control_port, 2135 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2136 const u8 *buf, size_t len, const u8 *dest, __be16 proto, 2137 bool unencrypted, int link_id), 2138 TP_ARGS(wiphy, netdev, buf, len, dest, proto, unencrypted, link_id), 2139 TP_STRUCT__entry( 2140 WIPHY_ENTRY 2141 NETDEV_ENTRY 2142 MAC_ENTRY(dest) 2143 __field(__be16, proto) 2144 __field(bool, unencrypted) 2145 __field(int, link_id) 2146 ), 2147 TP_fast_assign( 2148 WIPHY_ASSIGN; 2149 NETDEV_ASSIGN; 2150 MAC_ASSIGN(dest, dest); 2151 __entry->proto = proto; 2152 __entry->unencrypted = unencrypted; 2153 __entry->link_id = link_id; 2154 ), 2155 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %pM," 2156 " proto: 0x%x, unencrypted: %s, link: %d", 2157 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->dest, 2158 be16_to_cpu(__entry->proto), 2159 BOOL_TO_STR(__entry->unencrypted), 2160 __entry->link_id) 2161 ); 2162 2163 TRACE_EVENT(rdev_set_noack_map, 2164 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2165 u16 noack_map), 2166 TP_ARGS(wiphy, netdev, noack_map), 2167 TP_STRUCT__entry( 2168 WIPHY_ENTRY 2169 NETDEV_ENTRY 2170 __field(u16, noack_map) 2171 ), 2172 TP_fast_assign( 2173 WIPHY_ASSIGN; 2174 NETDEV_ASSIGN; 2175 __entry->noack_map = noack_map; 2176 ), 2177 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", noack_map: %u", 2178 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->noack_map) 2179 ); 2180 2181 DECLARE_EVENT_CLASS(wiphy_wdev_link_evt, 2182 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 2183 unsigned int link_id), 2184 TP_ARGS(wiphy, wdev, link_id), 2185 TP_STRUCT__entry( 2186 WIPHY_ENTRY 2187 WDEV_ENTRY 2188 __field(unsigned int, link_id) 2189 ), 2190 TP_fast_assign( 2191 WIPHY_ASSIGN; 2192 WDEV_ASSIGN; 2193 __entry->link_id = link_id; 2194 ), 2195 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", link_id: %u", 2196 WIPHY_PR_ARG, WDEV_PR_ARG, __entry->link_id) 2197 ); 2198 2199 DEFINE_EVENT(wiphy_wdev_link_evt, rdev_get_channel, 2200 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 2201 unsigned int link_id), 2202 TP_ARGS(wiphy, wdev, link_id) 2203 ); 2204 2205 TRACE_EVENT(rdev_return_chandef, 2206 TP_PROTO(struct wiphy *wiphy, int ret, 2207 struct cfg80211_chan_def *chandef), 2208 TP_ARGS(wiphy, ret, chandef), 2209 TP_STRUCT__entry( 2210 WIPHY_ENTRY 2211 __field(int, ret) 2212 CHAN_DEF_ENTRY 2213 ), 2214 TP_fast_assign( 2215 WIPHY_ASSIGN; 2216 if (ret == 0) 2217 CHAN_DEF_ASSIGN(chandef); 2218 else 2219 CHAN_DEF_ASSIGN((struct cfg80211_chan_def *)NULL); 2220 __entry->ret = ret; 2221 ), 2222 TP_printk(WIPHY_PR_FMT ", " CHAN_DEF_PR_FMT ", ret: %d", 2223 WIPHY_PR_ARG, CHAN_DEF_PR_ARG, __entry->ret) 2224 ); 2225 2226 DEFINE_EVENT(wiphy_wdev_evt, rdev_start_p2p_device, 2227 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 2228 TP_ARGS(wiphy, wdev) 2229 ); 2230 2231 DEFINE_EVENT(wiphy_wdev_evt, rdev_stop_p2p_device, 2232 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 2233 TP_ARGS(wiphy, wdev) 2234 ); 2235 2236 TRACE_EVENT(rdev_start_nan, 2237 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 2238 struct cfg80211_nan_conf *conf), 2239 TP_ARGS(wiphy, wdev, conf), 2240 TP_STRUCT__entry( 2241 WIPHY_ENTRY 2242 WDEV_ENTRY 2243 __field(u8, master_pref) 2244 __field(u8, bands) 2245 ), 2246 TP_fast_assign( 2247 WIPHY_ASSIGN; 2248 WDEV_ASSIGN; 2249 __entry->master_pref = conf->master_pref; 2250 __entry->bands = conf->bands; 2251 ), 2252 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT 2253 ", master preference: %u, bands: 0x%0x", 2254 WIPHY_PR_ARG, WDEV_PR_ARG, __entry->master_pref, 2255 __entry->bands) 2256 ); 2257 2258 TRACE_EVENT(rdev_nan_change_conf, 2259 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 2260 struct cfg80211_nan_conf *conf, u32 changes), 2261 TP_ARGS(wiphy, wdev, conf, changes), 2262 TP_STRUCT__entry( 2263 WIPHY_ENTRY 2264 WDEV_ENTRY 2265 __field(u8, master_pref) 2266 __field(u8, bands) 2267 __field(u32, changes) 2268 ), 2269 TP_fast_assign( 2270 WIPHY_ASSIGN; 2271 WDEV_ASSIGN; 2272 __entry->master_pref = conf->master_pref; 2273 __entry->bands = conf->bands; 2274 __entry->changes = changes; 2275 ), 2276 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT 2277 ", master preference: %u, bands: 0x%0x, changes: %x", 2278 WIPHY_PR_ARG, WDEV_PR_ARG, __entry->master_pref, 2279 __entry->bands, __entry->changes) 2280 ); 2281 2282 DEFINE_EVENT(wiphy_wdev_evt, rdev_stop_nan, 2283 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 2284 TP_ARGS(wiphy, wdev) 2285 ); 2286 2287 TRACE_EVENT(rdev_add_nan_func, 2288 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 2289 const struct cfg80211_nan_func *func), 2290 TP_ARGS(wiphy, wdev, func), 2291 TP_STRUCT__entry( 2292 WIPHY_ENTRY 2293 WDEV_ENTRY 2294 __field(u8, func_type) 2295 __field(u64, cookie) 2296 ), 2297 TP_fast_assign( 2298 WIPHY_ASSIGN; 2299 WDEV_ASSIGN; 2300 __entry->func_type = func->type; 2301 __entry->cookie = func->cookie 2302 ), 2303 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", type=%u, cookie=%llu", 2304 WIPHY_PR_ARG, WDEV_PR_ARG, __entry->func_type, 2305 __entry->cookie) 2306 ); 2307 2308 TRACE_EVENT(rdev_del_nan_func, 2309 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 2310 u64 cookie), 2311 TP_ARGS(wiphy, wdev, cookie), 2312 TP_STRUCT__entry( 2313 WIPHY_ENTRY 2314 WDEV_ENTRY 2315 __field(u64, cookie) 2316 ), 2317 TP_fast_assign( 2318 WIPHY_ASSIGN; 2319 WDEV_ASSIGN; 2320 __entry->cookie = cookie; 2321 ), 2322 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", cookie=%llu", 2323 WIPHY_PR_ARG, WDEV_PR_ARG, __entry->cookie) 2324 ); 2325 2326 TRACE_EVENT(rdev_set_mac_acl, 2327 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2328 struct cfg80211_acl_data *params), 2329 TP_ARGS(wiphy, netdev, params), 2330 TP_STRUCT__entry( 2331 WIPHY_ENTRY 2332 NETDEV_ENTRY 2333 __field(u32, acl_policy) 2334 ), 2335 TP_fast_assign( 2336 WIPHY_ASSIGN; 2337 NETDEV_ASSIGN; 2338 __entry->acl_policy = params->acl_policy; 2339 ), 2340 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", acl policy: %d", 2341 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->acl_policy) 2342 ); 2343 2344 TRACE_EVENT(rdev_update_ft_ies, 2345 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2346 struct cfg80211_update_ft_ies_params *ftie), 2347 TP_ARGS(wiphy, netdev, ftie), 2348 TP_STRUCT__entry( 2349 WIPHY_ENTRY 2350 NETDEV_ENTRY 2351 __field(u16, md) 2352 __dynamic_array(u8, ie, ftie->ie_len) 2353 ), 2354 TP_fast_assign( 2355 WIPHY_ASSIGN; 2356 NETDEV_ASSIGN; 2357 __entry->md = ftie->md; 2358 memcpy(__get_dynamic_array(ie), ftie->ie, ftie->ie_len); 2359 ), 2360 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", md: 0x%x", 2361 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->md) 2362 ); 2363 2364 TRACE_EVENT(rdev_crit_proto_start, 2365 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 2366 enum nl80211_crit_proto_id protocol, u16 duration), 2367 TP_ARGS(wiphy, wdev, protocol, duration), 2368 TP_STRUCT__entry( 2369 WIPHY_ENTRY 2370 WDEV_ENTRY 2371 __field(u16, proto) 2372 __field(u16, duration) 2373 ), 2374 TP_fast_assign( 2375 WIPHY_ASSIGN; 2376 WDEV_ASSIGN; 2377 __entry->proto = protocol; 2378 __entry->duration = duration; 2379 ), 2380 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", proto=%x, duration=%u", 2381 WIPHY_PR_ARG, WDEV_PR_ARG, __entry->proto, __entry->duration) 2382 ); 2383 2384 TRACE_EVENT(rdev_crit_proto_stop, 2385 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 2386 TP_ARGS(wiphy, wdev), 2387 TP_STRUCT__entry( 2388 WIPHY_ENTRY 2389 WDEV_ENTRY 2390 ), 2391 TP_fast_assign( 2392 WIPHY_ASSIGN; 2393 WDEV_ASSIGN; 2394 ), 2395 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT, 2396 WIPHY_PR_ARG, WDEV_PR_ARG) 2397 ); 2398 2399 TRACE_EVENT(rdev_channel_switch, 2400 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2401 struct cfg80211_csa_settings *params), 2402 TP_ARGS(wiphy, netdev, params), 2403 TP_STRUCT__entry( 2404 WIPHY_ENTRY 2405 NETDEV_ENTRY 2406 CHAN_DEF_ENTRY 2407 __field(bool, radar_required) 2408 __field(bool, block_tx) 2409 __field(u8, count) 2410 __dynamic_array(u16, bcn_ofs, params->n_counter_offsets_beacon) 2411 __dynamic_array(u16, pres_ofs, params->n_counter_offsets_presp) 2412 __field(u8, link_id) 2413 ), 2414 TP_fast_assign( 2415 WIPHY_ASSIGN; 2416 NETDEV_ASSIGN; 2417 CHAN_DEF_ASSIGN(¶ms->chandef); 2418 __entry->radar_required = params->radar_required; 2419 __entry->block_tx = params->block_tx; 2420 __entry->count = params->count; 2421 memcpy(__get_dynamic_array(bcn_ofs), 2422 params->counter_offsets_beacon, 2423 params->n_counter_offsets_beacon * sizeof(u16)); 2424 2425 /* probe response offsets are optional */ 2426 if (params->n_counter_offsets_presp) 2427 memcpy(__get_dynamic_array(pres_ofs), 2428 params->counter_offsets_presp, 2429 params->n_counter_offsets_presp * sizeof(u16)); 2430 __entry->link_id = params->link_id; 2431 ), 2432 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", " CHAN_DEF_PR_FMT 2433 ", block_tx: %d, count: %u, radar_required: %d, link_id: %d", 2434 WIPHY_PR_ARG, NETDEV_PR_ARG, CHAN_DEF_PR_ARG, 2435 __entry->block_tx, __entry->count, __entry->radar_required, 2436 __entry->link_id) 2437 ); 2438 2439 TRACE_EVENT(rdev_set_qos_map, 2440 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2441 struct cfg80211_qos_map *qos_map), 2442 TP_ARGS(wiphy, netdev, qos_map), 2443 TP_STRUCT__entry( 2444 WIPHY_ENTRY 2445 NETDEV_ENTRY 2446 QOS_MAP_ENTRY 2447 ), 2448 TP_fast_assign( 2449 WIPHY_ASSIGN; 2450 NETDEV_ASSIGN; 2451 QOS_MAP_ASSIGN(qos_map); 2452 ), 2453 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", num_des: %u", 2454 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->num_des) 2455 ); 2456 2457 TRACE_EVENT(rdev_set_ap_chanwidth, 2458 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2459 unsigned int link_id, 2460 struct cfg80211_chan_def *chandef), 2461 TP_ARGS(wiphy, netdev, link_id, chandef), 2462 TP_STRUCT__entry( 2463 WIPHY_ENTRY 2464 NETDEV_ENTRY 2465 CHAN_DEF_ENTRY 2466 __field(unsigned int, link_id) 2467 ), 2468 TP_fast_assign( 2469 WIPHY_ASSIGN; 2470 NETDEV_ASSIGN; 2471 CHAN_DEF_ASSIGN(chandef); 2472 __entry->link_id = link_id; 2473 ), 2474 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", " CHAN_DEF_PR_FMT ", link:%d", 2475 WIPHY_PR_ARG, NETDEV_PR_ARG, CHAN_DEF_PR_ARG, 2476 __entry->link_id) 2477 ); 2478 2479 TRACE_EVENT(rdev_add_tx_ts, 2480 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2481 u8 tsid, const u8 *peer, u8 user_prio, u16 admitted_time), 2482 TP_ARGS(wiphy, netdev, tsid, peer, user_prio, admitted_time), 2483 TP_STRUCT__entry( 2484 WIPHY_ENTRY 2485 NETDEV_ENTRY 2486 MAC_ENTRY(peer) 2487 __field(u8, tsid) 2488 __field(u8, user_prio) 2489 __field(u16, admitted_time) 2490 ), 2491 TP_fast_assign( 2492 WIPHY_ASSIGN; 2493 NETDEV_ASSIGN; 2494 MAC_ASSIGN(peer, peer); 2495 __entry->tsid = tsid; 2496 __entry->user_prio = user_prio; 2497 __entry->admitted_time = admitted_time; 2498 ), 2499 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %pM, TSID %d, UP %d, time %d", 2500 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->peer, 2501 __entry->tsid, __entry->user_prio, __entry->admitted_time) 2502 ); 2503 2504 TRACE_EVENT(rdev_del_tx_ts, 2505 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2506 u8 tsid, const u8 *peer), 2507 TP_ARGS(wiphy, netdev, tsid, peer), 2508 TP_STRUCT__entry( 2509 WIPHY_ENTRY 2510 NETDEV_ENTRY 2511 MAC_ENTRY(peer) 2512 __field(u8, tsid) 2513 ), 2514 TP_fast_assign( 2515 WIPHY_ASSIGN; 2516 NETDEV_ASSIGN; 2517 MAC_ASSIGN(peer, peer); 2518 __entry->tsid = tsid; 2519 ), 2520 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %pM, TSID %d", 2521 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->peer, __entry->tsid) 2522 ); 2523 2524 TRACE_EVENT(rdev_tdls_channel_switch, 2525 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2526 const u8 *addr, u8 oper_class, 2527 struct cfg80211_chan_def *chandef), 2528 TP_ARGS(wiphy, netdev, addr, oper_class, chandef), 2529 TP_STRUCT__entry( 2530 WIPHY_ENTRY 2531 NETDEV_ENTRY 2532 MAC_ENTRY(addr) 2533 __field(u8, oper_class) 2534 CHAN_DEF_ENTRY 2535 ), 2536 TP_fast_assign( 2537 WIPHY_ASSIGN; 2538 NETDEV_ASSIGN; 2539 MAC_ASSIGN(addr, addr); 2540 CHAN_DEF_ASSIGN(chandef); 2541 ), 2542 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %pM" 2543 " oper class %d, " CHAN_DEF_PR_FMT, 2544 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->addr, 2545 __entry->oper_class, CHAN_DEF_PR_ARG) 2546 ); 2547 2548 TRACE_EVENT(rdev_tdls_cancel_channel_switch, 2549 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2550 const u8 *addr), 2551 TP_ARGS(wiphy, netdev, addr), 2552 TP_STRUCT__entry( 2553 WIPHY_ENTRY 2554 NETDEV_ENTRY 2555 MAC_ENTRY(addr) 2556 ), 2557 TP_fast_assign( 2558 WIPHY_ASSIGN; 2559 NETDEV_ASSIGN; 2560 MAC_ASSIGN(addr, addr); 2561 ), 2562 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %pM", 2563 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->addr) 2564 ); 2565 2566 TRACE_EVENT(rdev_set_pmk, 2567 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2568 struct cfg80211_pmk_conf *pmk_conf), 2569 2570 TP_ARGS(wiphy, netdev, pmk_conf), 2571 2572 TP_STRUCT__entry( 2573 WIPHY_ENTRY 2574 NETDEV_ENTRY 2575 MAC_ENTRY(aa) 2576 __field(u8, pmk_len) 2577 __field(u8, pmk_r0_name_len) 2578 __dynamic_array(u8, pmk, pmk_conf->pmk_len) 2579 __dynamic_array(u8, pmk_r0_name, WLAN_PMK_NAME_LEN) 2580 ), 2581 2582 TP_fast_assign( 2583 WIPHY_ASSIGN; 2584 NETDEV_ASSIGN; 2585 MAC_ASSIGN(aa, pmk_conf->aa); 2586 __entry->pmk_len = pmk_conf->pmk_len; 2587 __entry->pmk_r0_name_len = 2588 pmk_conf->pmk_r0_name ? WLAN_PMK_NAME_LEN : 0; 2589 memcpy(__get_dynamic_array(pmk), pmk_conf->pmk, 2590 pmk_conf->pmk_len); 2591 memcpy(__get_dynamic_array(pmk_r0_name), pmk_conf->pmk_r0_name, 2592 pmk_conf->pmk_r0_name ? WLAN_PMK_NAME_LEN : 0); 2593 ), 2594 2595 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %pM" 2596 "pmk_len=%u, pmk: %s pmk_r0_name: %s", WIPHY_PR_ARG, 2597 NETDEV_PR_ARG, __entry->aa, __entry->pmk_len, 2598 __print_array(__get_dynamic_array(pmk), 2599 __get_dynamic_array_len(pmk), 1), 2600 __entry->pmk_r0_name_len ? 2601 __print_array(__get_dynamic_array(pmk_r0_name), 2602 __get_dynamic_array_len(pmk_r0_name), 1) : "") 2603 ); 2604 2605 TRACE_EVENT(rdev_del_pmk, 2606 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, const u8 *aa), 2607 2608 TP_ARGS(wiphy, netdev, aa), 2609 2610 TP_STRUCT__entry( 2611 WIPHY_ENTRY 2612 NETDEV_ENTRY 2613 MAC_ENTRY(aa) 2614 ), 2615 2616 TP_fast_assign( 2617 WIPHY_ASSIGN; 2618 NETDEV_ASSIGN; 2619 MAC_ASSIGN(aa, aa); 2620 ), 2621 2622 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %pM", 2623 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->aa) 2624 ); 2625 2626 TRACE_EVENT(rdev_external_auth, 2627 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2628 struct cfg80211_external_auth_params *params), 2629 TP_ARGS(wiphy, netdev, params), 2630 TP_STRUCT__entry(WIPHY_ENTRY 2631 NETDEV_ENTRY 2632 MAC_ENTRY(bssid) 2633 __array(u8, ssid, IEEE80211_MAX_SSID_LEN + 1) 2634 __field(u16, status) 2635 MAC_ENTRY(mld_addr) 2636 ), 2637 TP_fast_assign(WIPHY_ASSIGN; 2638 NETDEV_ASSIGN; 2639 MAC_ASSIGN(bssid, params->bssid); 2640 memset(__entry->ssid, 0, IEEE80211_MAX_SSID_LEN + 1); 2641 memcpy(__entry->ssid, params->ssid.ssid, 2642 params->ssid.ssid_len); 2643 __entry->status = params->status; 2644 MAC_ASSIGN(mld_addr, params->mld_addr); 2645 ), 2646 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", bssid: %pM" 2647 ", ssid: %s, status: %u, mld_addr: %pM", 2648 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->bssid, 2649 __entry->ssid, __entry->status, __entry->mld_addr) 2650 ); 2651 2652 TRACE_EVENT(rdev_start_radar_detection, 2653 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2654 struct cfg80211_chan_def *chandef, 2655 u32 cac_time_ms), 2656 TP_ARGS(wiphy, netdev, chandef, cac_time_ms), 2657 TP_STRUCT__entry( 2658 WIPHY_ENTRY 2659 NETDEV_ENTRY 2660 CHAN_DEF_ENTRY 2661 __field(u32, cac_time_ms) 2662 ), 2663 TP_fast_assign( 2664 WIPHY_ASSIGN; 2665 NETDEV_ASSIGN; 2666 CHAN_DEF_ASSIGN(chandef); 2667 __entry->cac_time_ms = cac_time_ms; 2668 ), 2669 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", " CHAN_DEF_PR_FMT 2670 ", cac_time_ms=%u", 2671 WIPHY_PR_ARG, NETDEV_PR_ARG, CHAN_DEF_PR_ARG, 2672 __entry->cac_time_ms) 2673 ); 2674 2675 TRACE_EVENT(rdev_set_mcast_rate, 2676 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2677 int *mcast_rate), 2678 TP_ARGS(wiphy, netdev, mcast_rate), 2679 TP_STRUCT__entry( 2680 WIPHY_ENTRY 2681 NETDEV_ENTRY 2682 __array(int, mcast_rate, NUM_NL80211_BANDS) 2683 ), 2684 TP_fast_assign( 2685 WIPHY_ASSIGN; 2686 NETDEV_ASSIGN; 2687 memcpy(__entry->mcast_rate, mcast_rate, 2688 sizeof(int) * NUM_NL80211_BANDS); 2689 ), 2690 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", " 2691 "mcast_rates [2.4GHz=0x%x, 5.2GHz=0x%x, 6GHz=0x%x, 60GHz=0x%x]", 2692 WIPHY_PR_ARG, NETDEV_PR_ARG, 2693 __entry->mcast_rate[NL80211_BAND_2GHZ], 2694 __entry->mcast_rate[NL80211_BAND_5GHZ], 2695 __entry->mcast_rate[NL80211_BAND_6GHZ], 2696 __entry->mcast_rate[NL80211_BAND_60GHZ]) 2697 ); 2698 2699 TRACE_EVENT(rdev_set_coalesce, 2700 TP_PROTO(struct wiphy *wiphy, struct cfg80211_coalesce *coalesce), 2701 TP_ARGS(wiphy, coalesce), 2702 TP_STRUCT__entry( 2703 WIPHY_ENTRY 2704 __field(int, n_rules) 2705 ), 2706 TP_fast_assign( 2707 WIPHY_ASSIGN; 2708 __entry->n_rules = coalesce ? coalesce->n_rules : 0; 2709 ), 2710 TP_printk(WIPHY_PR_FMT ", n_rules=%d", 2711 WIPHY_PR_ARG, __entry->n_rules) 2712 ); 2713 2714 DEFINE_EVENT(wiphy_wdev_evt, rdev_abort_scan, 2715 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 2716 TP_ARGS(wiphy, wdev) 2717 ); 2718 2719 TRACE_EVENT(rdev_set_multicast_to_unicast, 2720 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2721 const bool enabled), 2722 TP_ARGS(wiphy, netdev, enabled), 2723 TP_STRUCT__entry( 2724 WIPHY_ENTRY 2725 NETDEV_ENTRY 2726 __field(bool, enabled) 2727 ), 2728 TP_fast_assign( 2729 WIPHY_ASSIGN; 2730 NETDEV_ASSIGN; 2731 __entry->enabled = enabled; 2732 ), 2733 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", unicast: %s", 2734 WIPHY_PR_ARG, NETDEV_PR_ARG, 2735 BOOL_TO_STR(__entry->enabled)) 2736 ); 2737 2738 DEFINE_EVENT(wiphy_wdev_evt, rdev_get_txq_stats, 2739 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 2740 TP_ARGS(wiphy, wdev) 2741 ); 2742 2743 TRACE_EVENT(rdev_get_ftm_responder_stats, 2744 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2745 struct cfg80211_ftm_responder_stats *ftm_stats), 2746 2747 TP_ARGS(wiphy, netdev, ftm_stats), 2748 2749 TP_STRUCT__entry( 2750 WIPHY_ENTRY 2751 NETDEV_ENTRY 2752 __field(u64, timestamp) 2753 __field(u32, success_num) 2754 __field(u32, partial_num) 2755 __field(u32, failed_num) 2756 __field(u32, asap_num) 2757 __field(u32, non_asap_num) 2758 __field(u64, duration) 2759 __field(u32, unknown_triggers) 2760 __field(u32, reschedule) 2761 __field(u32, out_of_window) 2762 ), 2763 2764 TP_fast_assign( 2765 WIPHY_ASSIGN; 2766 NETDEV_ASSIGN; 2767 __entry->success_num = ftm_stats->success_num; 2768 __entry->partial_num = ftm_stats->partial_num; 2769 __entry->failed_num = ftm_stats->failed_num; 2770 __entry->asap_num = ftm_stats->asap_num; 2771 __entry->non_asap_num = ftm_stats->non_asap_num; 2772 __entry->duration = ftm_stats->total_duration_ms; 2773 __entry->unknown_triggers = ftm_stats->unknown_triggers_num; 2774 __entry->reschedule = ftm_stats->reschedule_requests_num; 2775 __entry->out_of_window = ftm_stats->out_of_window_triggers_num; 2776 ), 2777 2778 TP_printk(WIPHY_PR_FMT "Ftm responder stats: success %u, partial %u, " 2779 "failed %u, asap %u, non asap %u, total duration %llu, unknown " 2780 "triggers %u, rescheduled %u, out of window %u", WIPHY_PR_ARG, 2781 __entry->success_num, __entry->partial_num, __entry->failed_num, 2782 __entry->asap_num, __entry->non_asap_num, __entry->duration, 2783 __entry->unknown_triggers, __entry->reschedule, 2784 __entry->out_of_window) 2785 ); 2786 2787 DEFINE_EVENT(wiphy_wdev_cookie_evt, rdev_start_pmsr, 2788 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, u64 cookie), 2789 TP_ARGS(wiphy, wdev, cookie) 2790 ); 2791 2792 DEFINE_EVENT(wiphy_wdev_cookie_evt, rdev_abort_pmsr, 2793 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, u64 cookie), 2794 TP_ARGS(wiphy, wdev, cookie) 2795 ); 2796 2797 TRACE_EVENT(rdev_set_fils_aad, 2798 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2799 struct cfg80211_fils_aad *fils_aad), 2800 TP_ARGS(wiphy, netdev, fils_aad), 2801 TP_STRUCT__entry(WIPHY_ENTRY 2802 NETDEV_ENTRY 2803 __array(u8, macaddr, ETH_ALEN) 2804 __field(u8, kek_len) 2805 ), 2806 TP_fast_assign(WIPHY_ASSIGN; 2807 NETDEV_ASSIGN; 2808 FILS_AAD_ASSIGN(fils_aad); 2809 ), 2810 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", " FILS_AAD_PR_FMT, 2811 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->macaddr, 2812 __entry->kek_len) 2813 ); 2814 2815 TRACE_EVENT(rdev_update_owe_info, 2816 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2817 struct cfg80211_update_owe_info *owe_info), 2818 TP_ARGS(wiphy, netdev, owe_info), 2819 TP_STRUCT__entry(WIPHY_ENTRY 2820 NETDEV_ENTRY 2821 MAC_ENTRY(peer) 2822 __field(u16, status) 2823 __dynamic_array(u8, ie, owe_info->ie_len)), 2824 TP_fast_assign(WIPHY_ASSIGN; 2825 NETDEV_ASSIGN; 2826 MAC_ASSIGN(peer, owe_info->peer); 2827 __entry->status = owe_info->status; 2828 memcpy(__get_dynamic_array(ie), 2829 owe_info->ie, owe_info->ie_len);), 2830 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", peer: %pM" 2831 " status %d", WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->peer, 2832 __entry->status) 2833 ); 2834 2835 TRACE_EVENT(rdev_probe_mesh_link, 2836 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2837 const u8 *dest, const u8 *buf, size_t len), 2838 TP_ARGS(wiphy, netdev, dest, buf, len), 2839 TP_STRUCT__entry( 2840 WIPHY_ENTRY 2841 NETDEV_ENTRY 2842 MAC_ENTRY(dest) 2843 ), 2844 TP_fast_assign( 2845 WIPHY_ASSIGN; 2846 NETDEV_ASSIGN; 2847 MAC_ASSIGN(dest, dest); 2848 ), 2849 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", %pM", 2850 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->dest) 2851 ); 2852 2853 TRACE_EVENT(rdev_set_tid_config, 2854 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2855 struct cfg80211_tid_config *tid_conf), 2856 TP_ARGS(wiphy, netdev, tid_conf), 2857 TP_STRUCT__entry( 2858 WIPHY_ENTRY 2859 NETDEV_ENTRY 2860 MAC_ENTRY(peer) 2861 ), 2862 TP_fast_assign( 2863 WIPHY_ASSIGN; 2864 NETDEV_ASSIGN; 2865 MAC_ASSIGN(peer, tid_conf->peer); 2866 ), 2867 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", peer: %pM", 2868 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->peer) 2869 ); 2870 2871 TRACE_EVENT(rdev_reset_tid_config, 2872 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2873 const u8 *peer, u8 tids), 2874 TP_ARGS(wiphy, netdev, peer, tids), 2875 TP_STRUCT__entry( 2876 WIPHY_ENTRY 2877 NETDEV_ENTRY 2878 MAC_ENTRY(peer) 2879 __field(u8, tids) 2880 ), 2881 TP_fast_assign( 2882 WIPHY_ASSIGN; 2883 NETDEV_ASSIGN; 2884 MAC_ASSIGN(peer, peer); 2885 __entry->tids = tids; 2886 ), 2887 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", peer: %pM, tids: 0x%x", 2888 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->peer, __entry->tids) 2889 ); 2890 2891 TRACE_EVENT(rdev_set_sar_specs, 2892 TP_PROTO(struct wiphy *wiphy, struct cfg80211_sar_specs *sar), 2893 TP_ARGS(wiphy, sar), 2894 TP_STRUCT__entry( 2895 WIPHY_ENTRY 2896 __field(u16, type) 2897 __field(u16, num) 2898 ), 2899 TP_fast_assign( 2900 WIPHY_ASSIGN; 2901 __entry->type = sar->type; 2902 __entry->num = sar->num_sub_specs; 2903 2904 ), 2905 TP_printk(WIPHY_PR_FMT ", Set type:%d, num_specs:%d", 2906 WIPHY_PR_ARG, __entry->type, __entry->num) 2907 ); 2908 2909 TRACE_EVENT(rdev_color_change, 2910 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2911 struct cfg80211_color_change_settings *params), 2912 TP_ARGS(wiphy, netdev, params), 2913 TP_STRUCT__entry( 2914 WIPHY_ENTRY 2915 NETDEV_ENTRY 2916 __field(u8, count) 2917 __field(u16, bcn_ofs) 2918 __field(u16, pres_ofs) 2919 __field(u8, link_id) 2920 ), 2921 TP_fast_assign( 2922 WIPHY_ASSIGN; 2923 NETDEV_ASSIGN; 2924 __entry->count = params->count; 2925 __entry->bcn_ofs = params->counter_offset_beacon; 2926 __entry->pres_ofs = params->counter_offset_presp; 2927 __entry->link_id = params->link_id; 2928 ), 2929 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT 2930 ", count: %u, link_id: %d", 2931 WIPHY_PR_ARG, NETDEV_PR_ARG, 2932 __entry->count, __entry->link_id) 2933 ); 2934 2935 TRACE_EVENT(rdev_set_radar_background, 2936 TP_PROTO(struct wiphy *wiphy, struct cfg80211_chan_def *chandef), 2937 2938 TP_ARGS(wiphy, chandef), 2939 2940 TP_STRUCT__entry( 2941 WIPHY_ENTRY 2942 CHAN_DEF_ENTRY 2943 ), 2944 2945 TP_fast_assign( 2946 WIPHY_ASSIGN; 2947 CHAN_DEF_ASSIGN(chandef) 2948 ), 2949 2950 TP_printk(WIPHY_PR_FMT ", " CHAN_DEF_PR_FMT, 2951 WIPHY_PR_ARG, CHAN_DEF_PR_ARG) 2952 ); 2953 2954 DEFINE_EVENT(wiphy_wdev_link_evt, rdev_add_intf_link, 2955 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 2956 unsigned int link_id), 2957 TP_ARGS(wiphy, wdev, link_id) 2958 ); 2959 2960 DEFINE_EVENT(wiphy_wdev_link_evt, rdev_del_intf_link, 2961 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 2962 unsigned int link_id), 2963 TP_ARGS(wiphy, wdev, link_id) 2964 ); 2965 2966 TRACE_EVENT(rdev_del_link_station, 2967 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2968 struct link_station_del_parameters *params), 2969 TP_ARGS(wiphy, netdev, params), 2970 TP_STRUCT__entry( 2971 WIPHY_ENTRY 2972 NETDEV_ENTRY 2973 __array(u8, mld_mac, 6) 2974 __field(u32, link_id) 2975 ), 2976 TP_fast_assign( 2977 WIPHY_ASSIGN; 2978 NETDEV_ASSIGN; 2979 memset(__entry->mld_mac, 0, 6); 2980 if (params->mld_mac) 2981 memcpy(__entry->mld_mac, params->mld_mac, 6); 2982 __entry->link_id = params->link_id; 2983 ), 2984 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", station mac: %pM" 2985 ", link id: %u", 2986 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->mld_mac, 2987 __entry->link_id) 2988 ); 2989 2990 TRACE_EVENT(rdev_set_hw_timestamp, 2991 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 2992 struct cfg80211_set_hw_timestamp *hwts), 2993 2994 TP_ARGS(wiphy, netdev, hwts), 2995 2996 TP_STRUCT__entry( 2997 WIPHY_ENTRY 2998 NETDEV_ENTRY 2999 MAC_ENTRY(macaddr) 3000 __field(bool, enable) 3001 ), 3002 3003 TP_fast_assign( 3004 WIPHY_ASSIGN; 3005 NETDEV_ASSIGN; 3006 MAC_ASSIGN(macaddr, hwts->macaddr); 3007 __entry->enable = hwts->enable; 3008 ), 3009 3010 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", mac %pM, enable: %u", 3011 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->macaddr, 3012 __entry->enable) 3013 ); 3014 3015 TRACE_EVENT(rdev_set_ttlm, 3016 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 3017 struct cfg80211_ttlm_params *params), 3018 TP_ARGS(wiphy, netdev, params), 3019 TP_STRUCT__entry( 3020 WIPHY_ENTRY 3021 NETDEV_ENTRY 3022 __array(u8, dlink, sizeof(u16) * 8) 3023 __array(u8, ulink, sizeof(u16) * 8) 3024 ), 3025 TP_fast_assign( 3026 WIPHY_ASSIGN; 3027 NETDEV_ASSIGN; 3028 memcpy(__entry->dlink, params->dlink, sizeof(params->dlink)); 3029 memcpy(__entry->ulink, params->ulink, sizeof(params->ulink)); 3030 ), 3031 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT, 3032 WIPHY_PR_ARG, NETDEV_PR_ARG) 3033 ); 3034 3035 /************************************************************* 3036 * cfg80211 exported functions traces * 3037 *************************************************************/ 3038 3039 TRACE_EVENT(cfg80211_return_bool, 3040 TP_PROTO(bool ret), 3041 TP_ARGS(ret), 3042 TP_STRUCT__entry( 3043 __field(bool, ret) 3044 ), 3045 TP_fast_assign( 3046 __entry->ret = ret; 3047 ), 3048 TP_printk("returned %s", BOOL_TO_STR(__entry->ret)) 3049 ); 3050 3051 DECLARE_EVENT_CLASS(cfg80211_netdev_mac_evt, 3052 TP_PROTO(struct net_device *netdev, const u8 *macaddr), 3053 TP_ARGS(netdev, macaddr), 3054 TP_STRUCT__entry( 3055 NETDEV_ENTRY 3056 MAC_ENTRY(macaddr) 3057 ), 3058 TP_fast_assign( 3059 NETDEV_ASSIGN; 3060 MAC_ASSIGN(macaddr, macaddr); 3061 ), 3062 TP_printk(NETDEV_PR_FMT ", mac: %pM", 3063 NETDEV_PR_ARG, __entry->macaddr) 3064 ); 3065 3066 DEFINE_EVENT(cfg80211_netdev_mac_evt, cfg80211_notify_new_peer_candidate, 3067 TP_PROTO(struct net_device *netdev, const u8 *macaddr), 3068 TP_ARGS(netdev, macaddr) 3069 ); 3070 3071 DECLARE_EVENT_CLASS(netdev_evt_only, 3072 TP_PROTO(struct net_device *netdev), 3073 TP_ARGS(netdev), 3074 TP_STRUCT__entry( 3075 NETDEV_ENTRY 3076 ), 3077 TP_fast_assign( 3078 NETDEV_ASSIGN; 3079 ), 3080 TP_printk(NETDEV_PR_FMT , NETDEV_PR_ARG) 3081 ); 3082 3083 DEFINE_EVENT(netdev_evt_only, cfg80211_send_rx_auth, 3084 TP_PROTO(struct net_device *netdev), 3085 TP_ARGS(netdev) 3086 ); 3087 3088 TRACE_EVENT(cfg80211_send_rx_assoc, 3089 TP_PROTO(struct net_device *netdev, 3090 const struct cfg80211_rx_assoc_resp_data *data), 3091 TP_ARGS(netdev, data), 3092 TP_STRUCT__entry( 3093 NETDEV_ENTRY 3094 MAC_ENTRY(ap_addr) 3095 ), 3096 TP_fast_assign( 3097 NETDEV_ASSIGN; 3098 MAC_ASSIGN(ap_addr, 3099 data->ap_mld_addr ?: data->links[0].bss->bssid); 3100 ), 3101 TP_printk(NETDEV_PR_FMT ", %pM", 3102 NETDEV_PR_ARG, __entry->ap_addr) 3103 ); 3104 3105 DECLARE_EVENT_CLASS(netdev_frame_event, 3106 TP_PROTO(struct net_device *netdev, const u8 *buf, int len), 3107 TP_ARGS(netdev, buf, len), 3108 TP_STRUCT__entry( 3109 NETDEV_ENTRY 3110 __dynamic_array(u8, frame, len) 3111 ), 3112 TP_fast_assign( 3113 NETDEV_ASSIGN; 3114 memcpy(__get_dynamic_array(frame), buf, len); 3115 ), 3116 TP_printk(NETDEV_PR_FMT ", ftype:0x%.2x", 3117 NETDEV_PR_ARG, 3118 le16_to_cpup((__le16 *)__get_dynamic_array(frame))) 3119 ); 3120 3121 DEFINE_EVENT(netdev_frame_event, cfg80211_rx_unprot_mlme_mgmt, 3122 TP_PROTO(struct net_device *netdev, const u8 *buf, int len), 3123 TP_ARGS(netdev, buf, len) 3124 ); 3125 3126 DEFINE_EVENT(netdev_frame_event, cfg80211_rx_mlme_mgmt, 3127 TP_PROTO(struct net_device *netdev, const u8 *buf, int len), 3128 TP_ARGS(netdev, buf, len) 3129 ); 3130 3131 TRACE_EVENT(cfg80211_tx_mlme_mgmt, 3132 TP_PROTO(struct net_device *netdev, const u8 *buf, int len, 3133 bool reconnect), 3134 TP_ARGS(netdev, buf, len, reconnect), 3135 TP_STRUCT__entry( 3136 NETDEV_ENTRY 3137 __dynamic_array(u8, frame, len) 3138 __field(int, reconnect) 3139 ), 3140 TP_fast_assign( 3141 NETDEV_ASSIGN; 3142 memcpy(__get_dynamic_array(frame), buf, len); 3143 __entry->reconnect = reconnect; 3144 ), 3145 TP_printk(NETDEV_PR_FMT ", ftype:0x%.2x reconnect:%d", 3146 NETDEV_PR_ARG, 3147 le16_to_cpup((__le16 *)__get_dynamic_array(frame)), 3148 __entry->reconnect) 3149 ); 3150 3151 DECLARE_EVENT_CLASS(netdev_mac_evt, 3152 TP_PROTO(struct net_device *netdev, const u8 *mac), 3153 TP_ARGS(netdev, mac), 3154 TP_STRUCT__entry( 3155 NETDEV_ENTRY 3156 MAC_ENTRY(mac) 3157 ), 3158 TP_fast_assign( 3159 NETDEV_ASSIGN; 3160 MAC_ASSIGN(mac, mac) 3161 ), 3162 TP_printk(NETDEV_PR_FMT ", mac: %pM", 3163 NETDEV_PR_ARG, __entry->mac) 3164 ); 3165 3166 DEFINE_EVENT(netdev_mac_evt, cfg80211_send_auth_timeout, 3167 TP_PROTO(struct net_device *netdev, const u8 *mac), 3168 TP_ARGS(netdev, mac) 3169 ); 3170 3171 TRACE_EVENT(cfg80211_send_assoc_failure, 3172 TP_PROTO(struct net_device *netdev, 3173 struct cfg80211_assoc_failure *data), 3174 TP_ARGS(netdev, data), 3175 TP_STRUCT__entry( 3176 NETDEV_ENTRY 3177 MAC_ENTRY(ap_addr) 3178 __field(bool, timeout) 3179 ), 3180 TP_fast_assign( 3181 NETDEV_ASSIGN; 3182 MAC_ASSIGN(ap_addr, data->ap_mld_addr ?: data->bss[0]->bssid); 3183 __entry->timeout = data->timeout; 3184 ), 3185 TP_printk(NETDEV_PR_FMT ", mac: %pM, timeout: %d", 3186 NETDEV_PR_ARG, __entry->ap_addr, __entry->timeout) 3187 ); 3188 3189 TRACE_EVENT(cfg80211_michael_mic_failure, 3190 TP_PROTO(struct net_device *netdev, const u8 *addr, 3191 enum nl80211_key_type key_type, int key_id, const u8 *tsc), 3192 TP_ARGS(netdev, addr, key_type, key_id, tsc), 3193 TP_STRUCT__entry( 3194 NETDEV_ENTRY 3195 MAC_ENTRY(addr) 3196 __field(enum nl80211_key_type, key_type) 3197 __field(int, key_id) 3198 __array(u8, tsc, 6) 3199 ), 3200 TP_fast_assign( 3201 NETDEV_ASSIGN; 3202 MAC_ASSIGN(addr, addr); 3203 __entry->key_type = key_type; 3204 __entry->key_id = key_id; 3205 if (tsc) 3206 memcpy(__entry->tsc, tsc, 6); 3207 ), 3208 TP_printk(NETDEV_PR_FMT ", %pM, key type: %d, key id: %d, tsc: %pm", 3209 NETDEV_PR_ARG, __entry->addr, __entry->key_type, 3210 __entry->key_id, __entry->tsc) 3211 ); 3212 3213 TRACE_EVENT(cfg80211_ready_on_channel, 3214 TP_PROTO(struct wireless_dev *wdev, u64 cookie, 3215 struct ieee80211_channel *chan, 3216 unsigned int duration), 3217 TP_ARGS(wdev, cookie, chan, duration), 3218 TP_STRUCT__entry( 3219 WDEV_ENTRY 3220 __field(u64, cookie) 3221 CHAN_ENTRY 3222 __field(unsigned int, duration) 3223 ), 3224 TP_fast_assign( 3225 WDEV_ASSIGN; 3226 __entry->cookie = cookie; 3227 CHAN_ASSIGN(chan); 3228 __entry->duration = duration; 3229 ), 3230 TP_printk(WDEV_PR_FMT ", cookie: %llu, " CHAN_PR_FMT ", duration: %u", 3231 WDEV_PR_ARG, __entry->cookie, CHAN_PR_ARG, 3232 __entry->duration) 3233 ); 3234 3235 TRACE_EVENT(cfg80211_ready_on_channel_expired, 3236 TP_PROTO(struct wireless_dev *wdev, u64 cookie, 3237 struct ieee80211_channel *chan), 3238 TP_ARGS(wdev, cookie, chan), 3239 TP_STRUCT__entry( 3240 WDEV_ENTRY 3241 __field(u64, cookie) 3242 CHAN_ENTRY 3243 ), 3244 TP_fast_assign( 3245 WDEV_ASSIGN; 3246 __entry->cookie = cookie; 3247 CHAN_ASSIGN(chan); 3248 ), 3249 TP_printk(WDEV_PR_FMT ", cookie: %llu, " CHAN_PR_FMT, 3250 WDEV_PR_ARG, __entry->cookie, CHAN_PR_ARG) 3251 ); 3252 3253 TRACE_EVENT(cfg80211_tx_mgmt_expired, 3254 TP_PROTO(struct wireless_dev *wdev, u64 cookie, 3255 struct ieee80211_channel *chan), 3256 TP_ARGS(wdev, cookie, chan), 3257 TP_STRUCT__entry( 3258 WDEV_ENTRY 3259 __field(u64, cookie) 3260 CHAN_ENTRY 3261 ), 3262 TP_fast_assign( 3263 WDEV_ASSIGN; 3264 __entry->cookie = cookie; 3265 CHAN_ASSIGN(chan); 3266 ), 3267 TP_printk(WDEV_PR_FMT ", cookie: %llu, " CHAN_PR_FMT, 3268 WDEV_PR_ARG, __entry->cookie, CHAN_PR_ARG) 3269 ); 3270 3271 TRACE_EVENT(cfg80211_new_sta, 3272 TP_PROTO(struct net_device *netdev, const u8 *mac_addr, 3273 struct station_info *sinfo), 3274 TP_ARGS(netdev, mac_addr, sinfo), 3275 TP_STRUCT__entry( 3276 NETDEV_ENTRY 3277 MAC_ENTRY(mac_addr) 3278 SINFO_ENTRY 3279 ), 3280 TP_fast_assign( 3281 NETDEV_ASSIGN; 3282 MAC_ASSIGN(mac_addr, mac_addr); 3283 SINFO_ASSIGN; 3284 ), 3285 TP_printk(NETDEV_PR_FMT ", %pM", 3286 NETDEV_PR_ARG, __entry->mac_addr) 3287 ); 3288 3289 DEFINE_EVENT(cfg80211_netdev_mac_evt, cfg80211_del_sta, 3290 TP_PROTO(struct net_device *netdev, const u8 *macaddr), 3291 TP_ARGS(netdev, macaddr) 3292 ); 3293 3294 TRACE_EVENT(cfg80211_rx_mgmt, 3295 TP_PROTO(struct wireless_dev *wdev, struct cfg80211_rx_info *info), 3296 TP_ARGS(wdev, info), 3297 TP_STRUCT__entry( 3298 WDEV_ENTRY 3299 __field(int, freq) 3300 __field(int, sig_dbm) 3301 ), 3302 TP_fast_assign( 3303 WDEV_ASSIGN; 3304 __entry->freq = info->freq; 3305 __entry->sig_dbm = info->sig_dbm; 3306 ), 3307 TP_printk(WDEV_PR_FMT ", freq: "KHZ_F", sig dbm: %d", 3308 WDEV_PR_ARG, PR_KHZ(__entry->freq), __entry->sig_dbm) 3309 ); 3310 3311 TRACE_EVENT(cfg80211_mgmt_tx_status, 3312 TP_PROTO(struct wireless_dev *wdev, u64 cookie, bool ack), 3313 TP_ARGS(wdev, cookie, ack), 3314 TP_STRUCT__entry( 3315 WDEV_ENTRY 3316 __field(u64, cookie) 3317 __field(bool, ack) 3318 ), 3319 TP_fast_assign( 3320 WDEV_ASSIGN; 3321 __entry->cookie = cookie; 3322 __entry->ack = ack; 3323 ), 3324 TP_printk(WDEV_PR_FMT", cookie: %llu, ack: %s", 3325 WDEV_PR_ARG, __entry->cookie, BOOL_TO_STR(__entry->ack)) 3326 ); 3327 3328 TRACE_EVENT(cfg80211_control_port_tx_status, 3329 TP_PROTO(struct wireless_dev *wdev, u64 cookie, bool ack), 3330 TP_ARGS(wdev, cookie, ack), 3331 TP_STRUCT__entry( 3332 WDEV_ENTRY 3333 __field(u64, cookie) 3334 __field(bool, ack) 3335 ), 3336 TP_fast_assign( 3337 WDEV_ASSIGN; 3338 __entry->cookie = cookie; 3339 __entry->ack = ack; 3340 ), 3341 TP_printk(WDEV_PR_FMT", cookie: %llu, ack: %s", 3342 WDEV_PR_ARG, __entry->cookie, BOOL_TO_STR(__entry->ack)) 3343 ); 3344 3345 TRACE_EVENT(cfg80211_rx_control_port, 3346 TP_PROTO(struct net_device *netdev, struct sk_buff *skb, 3347 bool unencrypted, int link_id), 3348 TP_ARGS(netdev, skb, unencrypted, link_id), 3349 TP_STRUCT__entry( 3350 NETDEV_ENTRY 3351 __field(int, len) 3352 MAC_ENTRY(from) 3353 __field(u16, proto) 3354 __field(bool, unencrypted) 3355 __field(int, link_id) 3356 ), 3357 TP_fast_assign( 3358 NETDEV_ASSIGN; 3359 __entry->len = skb->len; 3360 MAC_ASSIGN(from, eth_hdr(skb)->h_source); 3361 __entry->proto = be16_to_cpu(skb->protocol); 3362 __entry->unencrypted = unencrypted; 3363 __entry->link_id = link_id; 3364 ), 3365 TP_printk(NETDEV_PR_FMT ", len=%d, %pM, proto: 0x%x, unencrypted: %s, link: %d", 3366 NETDEV_PR_ARG, __entry->len, __entry->from, 3367 __entry->proto, BOOL_TO_STR(__entry->unencrypted), 3368 __entry->link_id) 3369 ); 3370 3371 TRACE_EVENT(cfg80211_cqm_rssi_notify, 3372 TP_PROTO(struct net_device *netdev, 3373 enum nl80211_cqm_rssi_threshold_event rssi_event, 3374 s32 rssi_level), 3375 TP_ARGS(netdev, rssi_event, rssi_level), 3376 TP_STRUCT__entry( 3377 NETDEV_ENTRY 3378 __field(enum nl80211_cqm_rssi_threshold_event, rssi_event) 3379 __field(s32, rssi_level) 3380 ), 3381 TP_fast_assign( 3382 NETDEV_ASSIGN; 3383 __entry->rssi_event = rssi_event; 3384 __entry->rssi_level = rssi_level; 3385 ), 3386 TP_printk(NETDEV_PR_FMT ", rssi event: %d, level: %d", 3387 NETDEV_PR_ARG, __entry->rssi_event, __entry->rssi_level) 3388 ); 3389 3390 TRACE_EVENT(cfg80211_reg_can_beacon, 3391 TP_PROTO(struct wiphy *wiphy, struct cfg80211_chan_def *chandef, 3392 enum nl80211_iftype iftype, u32 prohibited_flags, 3393 u32 permitting_flags), 3394 TP_ARGS(wiphy, chandef, iftype, prohibited_flags, permitting_flags), 3395 TP_STRUCT__entry( 3396 WIPHY_ENTRY 3397 CHAN_DEF_ENTRY 3398 __field(enum nl80211_iftype, iftype) 3399 __field(u32, prohibited_flags) 3400 __field(u32, permitting_flags) 3401 ), 3402 TP_fast_assign( 3403 WIPHY_ASSIGN; 3404 CHAN_DEF_ASSIGN(chandef); 3405 __entry->iftype = iftype; 3406 __entry->prohibited_flags = prohibited_flags; 3407 __entry->permitting_flags = permitting_flags; 3408 ), 3409 TP_printk(WIPHY_PR_FMT ", " CHAN_DEF_PR_FMT ", iftype=%d prohibited_flags=0x%x permitting_flags=0x%x", 3410 WIPHY_PR_ARG, CHAN_DEF_PR_ARG, __entry->iftype, 3411 __entry->prohibited_flags, __entry->permitting_flags) 3412 ); 3413 3414 TRACE_EVENT(cfg80211_chandef_dfs_required, 3415 TP_PROTO(struct wiphy *wiphy, struct cfg80211_chan_def *chandef), 3416 TP_ARGS(wiphy, chandef), 3417 TP_STRUCT__entry( 3418 WIPHY_ENTRY 3419 CHAN_DEF_ENTRY 3420 ), 3421 TP_fast_assign( 3422 WIPHY_ASSIGN; 3423 CHAN_DEF_ASSIGN(chandef); 3424 ), 3425 TP_printk(WIPHY_PR_FMT ", " CHAN_DEF_PR_FMT, 3426 WIPHY_PR_ARG, CHAN_DEF_PR_ARG) 3427 ); 3428 3429 TRACE_EVENT(cfg80211_ch_switch_notify, 3430 TP_PROTO(struct net_device *netdev, 3431 struct cfg80211_chan_def *chandef, 3432 unsigned int link_id), 3433 TP_ARGS(netdev, chandef, link_id), 3434 TP_STRUCT__entry( 3435 NETDEV_ENTRY 3436 CHAN_DEF_ENTRY 3437 __field(unsigned int, link_id) 3438 ), 3439 TP_fast_assign( 3440 NETDEV_ASSIGN; 3441 CHAN_DEF_ASSIGN(chandef); 3442 __entry->link_id = link_id; 3443 ), 3444 TP_printk(NETDEV_PR_FMT ", " CHAN_DEF_PR_FMT ", link:%d", 3445 NETDEV_PR_ARG, CHAN_DEF_PR_ARG, __entry->link_id) 3446 ); 3447 3448 TRACE_EVENT(cfg80211_ch_switch_started_notify, 3449 TP_PROTO(struct net_device *netdev, 3450 struct cfg80211_chan_def *chandef, 3451 unsigned int link_id), 3452 TP_ARGS(netdev, chandef, link_id), 3453 TP_STRUCT__entry( 3454 NETDEV_ENTRY 3455 CHAN_DEF_ENTRY 3456 __field(unsigned int, link_id) 3457 ), 3458 TP_fast_assign( 3459 NETDEV_ASSIGN; 3460 CHAN_DEF_ASSIGN(chandef); 3461 __entry->link_id = link_id; 3462 ), 3463 TP_printk(NETDEV_PR_FMT ", " CHAN_DEF_PR_FMT ", link:%d", 3464 NETDEV_PR_ARG, CHAN_DEF_PR_ARG, __entry->link_id) 3465 ); 3466 3467 TRACE_EVENT(cfg80211_radar_event, 3468 TP_PROTO(struct wiphy *wiphy, struct cfg80211_chan_def *chandef, 3469 bool offchan), 3470 TP_ARGS(wiphy, chandef, offchan), 3471 TP_STRUCT__entry( 3472 WIPHY_ENTRY 3473 CHAN_DEF_ENTRY 3474 __field(bool, offchan) 3475 ), 3476 TP_fast_assign( 3477 WIPHY_ASSIGN; 3478 CHAN_DEF_ASSIGN(chandef); 3479 __entry->offchan = offchan; 3480 ), 3481 TP_printk(WIPHY_PR_FMT ", " CHAN_DEF_PR_FMT ", offchan %d", 3482 WIPHY_PR_ARG, CHAN_DEF_PR_ARG, __entry->offchan) 3483 ); 3484 3485 TRACE_EVENT(cfg80211_cac_event, 3486 TP_PROTO(struct net_device *netdev, enum nl80211_radar_event evt), 3487 TP_ARGS(netdev, evt), 3488 TP_STRUCT__entry( 3489 NETDEV_ENTRY 3490 __field(enum nl80211_radar_event, evt) 3491 ), 3492 TP_fast_assign( 3493 NETDEV_ASSIGN; 3494 __entry->evt = evt; 3495 ), 3496 TP_printk(NETDEV_PR_FMT ", event: %d", 3497 NETDEV_PR_ARG, __entry->evt) 3498 ); 3499 3500 DECLARE_EVENT_CLASS(cfg80211_rx_evt, 3501 TP_PROTO(struct net_device *netdev, const u8 *addr), 3502 TP_ARGS(netdev, addr), 3503 TP_STRUCT__entry( 3504 NETDEV_ENTRY 3505 MAC_ENTRY(addr) 3506 ), 3507 TP_fast_assign( 3508 NETDEV_ASSIGN; 3509 MAC_ASSIGN(addr, addr); 3510 ), 3511 TP_printk(NETDEV_PR_FMT ", %pM", NETDEV_PR_ARG, __entry->addr) 3512 ); 3513 3514 DEFINE_EVENT(cfg80211_rx_evt, cfg80211_rx_spurious_frame, 3515 TP_PROTO(struct net_device *netdev, const u8 *addr), 3516 TP_ARGS(netdev, addr) 3517 ); 3518 3519 DEFINE_EVENT(cfg80211_rx_evt, cfg80211_rx_unexpected_4addr_frame, 3520 TP_PROTO(struct net_device *netdev, const u8 *addr), 3521 TP_ARGS(netdev, addr) 3522 ); 3523 3524 TRACE_EVENT(cfg80211_ibss_joined, 3525 TP_PROTO(struct net_device *netdev, const u8 *bssid, 3526 struct ieee80211_channel *channel), 3527 TP_ARGS(netdev, bssid, channel), 3528 TP_STRUCT__entry( 3529 NETDEV_ENTRY 3530 MAC_ENTRY(bssid) 3531 CHAN_ENTRY 3532 ), 3533 TP_fast_assign( 3534 NETDEV_ASSIGN; 3535 MAC_ASSIGN(bssid, bssid); 3536 CHAN_ASSIGN(channel); 3537 ), 3538 TP_printk(NETDEV_PR_FMT ", bssid: %pM, " CHAN_PR_FMT, 3539 NETDEV_PR_ARG, __entry->bssid, CHAN_PR_ARG) 3540 ); 3541 3542 TRACE_EVENT(cfg80211_probe_status, 3543 TP_PROTO(struct net_device *netdev, const u8 *addr, u64 cookie, 3544 bool acked), 3545 TP_ARGS(netdev, addr, cookie, acked), 3546 TP_STRUCT__entry( 3547 NETDEV_ENTRY 3548 MAC_ENTRY(addr) 3549 __field(u64, cookie) 3550 __field(bool, acked) 3551 ), 3552 TP_fast_assign( 3553 NETDEV_ASSIGN; 3554 MAC_ASSIGN(addr, addr); 3555 __entry->cookie = cookie; 3556 __entry->acked = acked; 3557 ), 3558 TP_printk(NETDEV_PR_FMT " addr:%pM, cookie: %llu, acked: %s", 3559 NETDEV_PR_ARG, __entry->addr, __entry->cookie, 3560 BOOL_TO_STR(__entry->acked)) 3561 ); 3562 3563 TRACE_EVENT(cfg80211_cqm_pktloss_notify, 3564 TP_PROTO(struct net_device *netdev, const u8 *peer, u32 num_packets), 3565 TP_ARGS(netdev, peer, num_packets), 3566 TP_STRUCT__entry( 3567 NETDEV_ENTRY 3568 MAC_ENTRY(peer) 3569 __field(u32, num_packets) 3570 ), 3571 TP_fast_assign( 3572 NETDEV_ASSIGN; 3573 MAC_ASSIGN(peer, peer); 3574 __entry->num_packets = num_packets; 3575 ), 3576 TP_printk(NETDEV_PR_FMT ", peer: %pM, num of lost packets: %u", 3577 NETDEV_PR_ARG, __entry->peer, __entry->num_packets) 3578 ); 3579 3580 DEFINE_EVENT(cfg80211_netdev_mac_evt, cfg80211_gtk_rekey_notify, 3581 TP_PROTO(struct net_device *netdev, const u8 *macaddr), 3582 TP_ARGS(netdev, macaddr) 3583 ); 3584 3585 TRACE_EVENT(cfg80211_pmksa_candidate_notify, 3586 TP_PROTO(struct net_device *netdev, int index, const u8 *bssid, 3587 bool preauth), 3588 TP_ARGS(netdev, index, bssid, preauth), 3589 TP_STRUCT__entry( 3590 NETDEV_ENTRY 3591 __field(int, index) 3592 MAC_ENTRY(bssid) 3593 __field(bool, preauth) 3594 ), 3595 TP_fast_assign( 3596 NETDEV_ASSIGN; 3597 __entry->index = index; 3598 MAC_ASSIGN(bssid, bssid); 3599 __entry->preauth = preauth; 3600 ), 3601 TP_printk(NETDEV_PR_FMT ", index:%d, bssid: %pM, pre auth: %s", 3602 NETDEV_PR_ARG, __entry->index, __entry->bssid, 3603 BOOL_TO_STR(__entry->preauth)) 3604 ); 3605 3606 TRACE_EVENT(cfg80211_report_obss_beacon, 3607 TP_PROTO(struct wiphy *wiphy, const u8 *frame, size_t len, 3608 int freq, int sig_dbm), 3609 TP_ARGS(wiphy, frame, len, freq, sig_dbm), 3610 TP_STRUCT__entry( 3611 WIPHY_ENTRY 3612 __field(int, freq) 3613 __field(int, sig_dbm) 3614 ), 3615 TP_fast_assign( 3616 WIPHY_ASSIGN; 3617 __entry->freq = freq; 3618 __entry->sig_dbm = sig_dbm; 3619 ), 3620 TP_printk(WIPHY_PR_FMT ", freq: "KHZ_F", sig_dbm: %d", 3621 WIPHY_PR_ARG, PR_KHZ(__entry->freq), __entry->sig_dbm) 3622 ); 3623 3624 TRACE_EVENT(cfg80211_tdls_oper_request, 3625 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, const u8 *peer, 3626 enum nl80211_tdls_operation oper, u16 reason_code), 3627 TP_ARGS(wiphy, netdev, peer, oper, reason_code), 3628 TP_STRUCT__entry( 3629 WIPHY_ENTRY 3630 NETDEV_ENTRY 3631 MAC_ENTRY(peer) 3632 __field(enum nl80211_tdls_operation, oper) 3633 __field(u16, reason_code) 3634 ), 3635 TP_fast_assign( 3636 WIPHY_ASSIGN; 3637 NETDEV_ASSIGN; 3638 MAC_ASSIGN(peer, peer); 3639 __entry->oper = oper; 3640 __entry->reason_code = reason_code; 3641 ), 3642 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", peer: %pM, oper: %d, reason_code %u", 3643 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->peer, __entry->oper, 3644 __entry->reason_code) 3645 ); 3646 3647 TRACE_EVENT(cfg80211_scan_done, 3648 TP_PROTO(struct cfg80211_scan_request *request, 3649 struct cfg80211_scan_info *info), 3650 TP_ARGS(request, info), 3651 TP_STRUCT__entry( 3652 __field(u32, n_channels) 3653 __dynamic_array(u8, ie, request ? request->ie_len : 0) 3654 __array(u32, rates, NUM_NL80211_BANDS) 3655 __field(u32, wdev_id) 3656 MAC_ENTRY(wiphy_mac) 3657 __field(bool, no_cck) 3658 __field(bool, aborted) 3659 __field(u64, scan_start_tsf) 3660 MAC_ENTRY(tsf_bssid) 3661 ), 3662 TP_fast_assign( 3663 if (request) { 3664 memcpy(__get_dynamic_array(ie), request->ie, 3665 request->ie_len); 3666 memcpy(__entry->rates, request->rates, 3667 NUM_NL80211_BANDS); 3668 __entry->wdev_id = request->wdev ? 3669 request->wdev->identifier : 0; 3670 if (request->wiphy) 3671 MAC_ASSIGN(wiphy_mac, 3672 request->wiphy->perm_addr); 3673 __entry->no_cck = request->no_cck; 3674 } 3675 if (info) { 3676 __entry->aborted = info->aborted; 3677 __entry->scan_start_tsf = info->scan_start_tsf; 3678 MAC_ASSIGN(tsf_bssid, info->tsf_bssid); 3679 } 3680 ), 3681 TP_printk("aborted: %s, scan start (TSF): %llu, tsf_bssid: %pM", 3682 BOOL_TO_STR(__entry->aborted), 3683 (unsigned long long)__entry->scan_start_tsf, 3684 __entry->tsf_bssid) 3685 ); 3686 3687 DECLARE_EVENT_CLASS(wiphy_id_evt, 3688 TP_PROTO(struct wiphy *wiphy, u64 id), 3689 TP_ARGS(wiphy, id), 3690 TP_STRUCT__entry( 3691 WIPHY_ENTRY 3692 __field(u64, id) 3693 ), 3694 TP_fast_assign( 3695 WIPHY_ASSIGN; 3696 __entry->id = id; 3697 ), 3698 TP_printk(WIPHY_PR_FMT ", id: %llu", WIPHY_PR_ARG, __entry->id) 3699 ); 3700 3701 DEFINE_EVENT(wiphy_id_evt, cfg80211_sched_scan_stopped, 3702 TP_PROTO(struct wiphy *wiphy, u64 id), 3703 TP_ARGS(wiphy, id) 3704 ); 3705 3706 DEFINE_EVENT(wiphy_id_evt, cfg80211_sched_scan_results, 3707 TP_PROTO(struct wiphy *wiphy, u64 id), 3708 TP_ARGS(wiphy, id) 3709 ); 3710 3711 TRACE_EVENT(cfg80211_get_bss, 3712 TP_PROTO(struct wiphy *wiphy, struct ieee80211_channel *channel, 3713 const u8 *bssid, const u8 *ssid, size_t ssid_len, 3714 enum ieee80211_bss_type bss_type, 3715 enum ieee80211_privacy privacy), 3716 TP_ARGS(wiphy, channel, bssid, ssid, ssid_len, bss_type, privacy), 3717 TP_STRUCT__entry( 3718 WIPHY_ENTRY 3719 CHAN_ENTRY 3720 MAC_ENTRY(bssid) 3721 __dynamic_array(u8, ssid, ssid_len) 3722 __field(enum ieee80211_bss_type, bss_type) 3723 __field(enum ieee80211_privacy, privacy) 3724 ), 3725 TP_fast_assign( 3726 WIPHY_ASSIGN; 3727 CHAN_ASSIGN(channel); 3728 MAC_ASSIGN(bssid, bssid); 3729 memcpy(__get_dynamic_array(ssid), ssid, ssid_len); 3730 __entry->bss_type = bss_type; 3731 __entry->privacy = privacy; 3732 ), 3733 TP_printk(WIPHY_PR_FMT ", " CHAN_PR_FMT ", %pM" 3734 ", buf: %#.2x, bss_type: %d, privacy: %d", 3735 WIPHY_PR_ARG, CHAN_PR_ARG, __entry->bssid, 3736 ((u8 *)__get_dynamic_array(ssid))[0], __entry->bss_type, 3737 __entry->privacy) 3738 ); 3739 3740 TRACE_EVENT(cfg80211_inform_bss_frame, 3741 TP_PROTO(struct wiphy *wiphy, struct cfg80211_inform_bss *data, 3742 struct ieee80211_mgmt *mgmt, size_t len), 3743 TP_ARGS(wiphy, data, mgmt, len), 3744 TP_STRUCT__entry( 3745 WIPHY_ENTRY 3746 CHAN_ENTRY 3747 __dynamic_array(u8, mgmt, len) 3748 __field(s32, signal) 3749 __field(u64, ts_boottime) 3750 __field(u64, parent_tsf) 3751 MAC_ENTRY(parent_bssid) 3752 ), 3753 TP_fast_assign( 3754 WIPHY_ASSIGN; 3755 CHAN_ASSIGN(data->chan); 3756 if (mgmt) 3757 memcpy(__get_dynamic_array(mgmt), mgmt, len); 3758 __entry->signal = data->signal; 3759 __entry->ts_boottime = data->boottime_ns; 3760 __entry->parent_tsf = data->parent_tsf; 3761 MAC_ASSIGN(parent_bssid, data->parent_bssid); 3762 ), 3763 TP_printk(WIPHY_PR_FMT ", " CHAN_PR_FMT 3764 "signal: %d, tsb:%llu, detect_tsf:%llu, tsf_bssid: %pM", 3765 WIPHY_PR_ARG, CHAN_PR_ARG, 3766 __entry->signal, (unsigned long long)__entry->ts_boottime, 3767 (unsigned long long)__entry->parent_tsf, 3768 __entry->parent_bssid) 3769 ); 3770 3771 DECLARE_EVENT_CLASS(cfg80211_bss_evt, 3772 TP_PROTO(struct cfg80211_bss *pub), 3773 TP_ARGS(pub), 3774 TP_STRUCT__entry( 3775 MAC_ENTRY(bssid) 3776 CHAN_ENTRY 3777 ), 3778 TP_fast_assign( 3779 MAC_ASSIGN(bssid, pub->bssid); 3780 CHAN_ASSIGN(pub->channel); 3781 ), 3782 TP_printk("%pM, " CHAN_PR_FMT, __entry->bssid, CHAN_PR_ARG) 3783 ); 3784 3785 DEFINE_EVENT(cfg80211_bss_evt, cfg80211_return_bss, 3786 TP_PROTO(struct cfg80211_bss *pub), 3787 TP_ARGS(pub) 3788 ); 3789 3790 TRACE_EVENT(cfg80211_return_uint, 3791 TP_PROTO(unsigned int ret), 3792 TP_ARGS(ret), 3793 TP_STRUCT__entry( 3794 __field(unsigned int, ret) 3795 ), 3796 TP_fast_assign( 3797 __entry->ret = ret; 3798 ), 3799 TP_printk("ret: %d", __entry->ret) 3800 ); 3801 3802 TRACE_EVENT(cfg80211_return_u32, 3803 TP_PROTO(u32 ret), 3804 TP_ARGS(ret), 3805 TP_STRUCT__entry( 3806 __field(u32, ret) 3807 ), 3808 TP_fast_assign( 3809 __entry->ret = ret; 3810 ), 3811 TP_printk("ret: %u", __entry->ret) 3812 ); 3813 3814 TRACE_EVENT(cfg80211_report_wowlan_wakeup, 3815 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 3816 struct cfg80211_wowlan_wakeup *wakeup), 3817 TP_ARGS(wiphy, wdev, wakeup), 3818 TP_STRUCT__entry( 3819 WIPHY_ENTRY 3820 WDEV_ENTRY 3821 __field(bool, non_wireless) 3822 __field(bool, disconnect) 3823 __field(bool, magic_pkt) 3824 __field(bool, gtk_rekey_failure) 3825 __field(bool, eap_identity_req) 3826 __field(bool, four_way_handshake) 3827 __field(bool, rfkill_release) 3828 __field(s32, pattern_idx) 3829 __field(u32, packet_len) 3830 __dynamic_array(u8, packet, 3831 wakeup ? wakeup->packet_present_len : 0) 3832 ), 3833 TP_fast_assign( 3834 WIPHY_ASSIGN; 3835 WDEV_ASSIGN; 3836 __entry->non_wireless = !wakeup; 3837 __entry->disconnect = wakeup ? wakeup->disconnect : false; 3838 __entry->magic_pkt = wakeup ? wakeup->magic_pkt : false; 3839 __entry->gtk_rekey_failure = wakeup ? wakeup->gtk_rekey_failure : false; 3840 __entry->eap_identity_req = wakeup ? wakeup->eap_identity_req : false; 3841 __entry->four_way_handshake = wakeup ? wakeup->four_way_handshake : false; 3842 __entry->rfkill_release = wakeup ? wakeup->rfkill_release : false; 3843 __entry->pattern_idx = wakeup ? wakeup->pattern_idx : false; 3844 __entry->packet_len = wakeup ? wakeup->packet_len : false; 3845 if (wakeup && wakeup->packet && wakeup->packet_present_len) 3846 memcpy(__get_dynamic_array(packet), wakeup->packet, 3847 wakeup->packet_present_len); 3848 ), 3849 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT, WIPHY_PR_ARG, WDEV_PR_ARG) 3850 ); 3851 3852 TRACE_EVENT(cfg80211_ft_event, 3853 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 3854 struct cfg80211_ft_event_params *ft_event), 3855 TP_ARGS(wiphy, netdev, ft_event), 3856 TP_STRUCT__entry( 3857 WIPHY_ENTRY 3858 NETDEV_ENTRY 3859 __dynamic_array(u8, ies, ft_event->ies_len) 3860 MAC_ENTRY(target_ap) 3861 __dynamic_array(u8, ric_ies, ft_event->ric_ies_len) 3862 ), 3863 TP_fast_assign( 3864 WIPHY_ASSIGN; 3865 NETDEV_ASSIGN; 3866 if (ft_event->ies) 3867 memcpy(__get_dynamic_array(ies), ft_event->ies, 3868 ft_event->ies_len); 3869 MAC_ASSIGN(target_ap, ft_event->target_ap); 3870 if (ft_event->ric_ies) 3871 memcpy(__get_dynamic_array(ric_ies), ft_event->ric_ies, 3872 ft_event->ric_ies_len); 3873 ), 3874 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", target_ap: %pM", 3875 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->target_ap) 3876 ); 3877 3878 TRACE_EVENT(cfg80211_stop_iface, 3879 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 3880 TP_ARGS(wiphy, wdev), 3881 TP_STRUCT__entry( 3882 WIPHY_ENTRY 3883 WDEV_ENTRY 3884 ), 3885 TP_fast_assign( 3886 WIPHY_ASSIGN; 3887 WDEV_ASSIGN; 3888 ), 3889 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT, 3890 WIPHY_PR_ARG, WDEV_PR_ARG) 3891 ); 3892 3893 TRACE_EVENT(cfg80211_pmsr_report, 3894 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, 3895 u64 cookie, const u8 *addr), 3896 TP_ARGS(wiphy, wdev, cookie, addr), 3897 TP_STRUCT__entry( 3898 WIPHY_ENTRY 3899 WDEV_ENTRY 3900 __field(u64, cookie) 3901 MAC_ENTRY(addr) 3902 ), 3903 TP_fast_assign( 3904 WIPHY_ASSIGN; 3905 WDEV_ASSIGN; 3906 __entry->cookie = cookie; 3907 MAC_ASSIGN(addr, addr); 3908 ), 3909 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", cookie:%lld, %pM", 3910 WIPHY_PR_ARG, WDEV_PR_ARG, 3911 (unsigned long long)__entry->cookie, 3912 __entry->addr) 3913 ); 3914 3915 TRACE_EVENT(cfg80211_pmsr_complete, 3916 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, u64 cookie), 3917 TP_ARGS(wiphy, wdev, cookie), 3918 TP_STRUCT__entry( 3919 WIPHY_ENTRY 3920 WDEV_ENTRY 3921 __field(u64, cookie) 3922 ), 3923 TP_fast_assign( 3924 WIPHY_ASSIGN; 3925 WDEV_ASSIGN; 3926 __entry->cookie = cookie; 3927 ), 3928 TP_printk(WIPHY_PR_FMT ", " WDEV_PR_FMT ", cookie:%lld", 3929 WIPHY_PR_ARG, WDEV_PR_ARG, 3930 (unsigned long long)__entry->cookie) 3931 ); 3932 3933 TRACE_EVENT(cfg80211_update_owe_info_event, 3934 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 3935 struct cfg80211_update_owe_info *owe_info), 3936 TP_ARGS(wiphy, netdev, owe_info), 3937 TP_STRUCT__entry( 3938 WIPHY_ENTRY 3939 NETDEV_ENTRY 3940 MAC_ENTRY(peer) 3941 __dynamic_array(u8, ie, owe_info->ie_len) 3942 __field(int, assoc_link_id) 3943 MAC_ENTRY(peer_mld_addr) 3944 ), 3945 TP_fast_assign( 3946 WIPHY_ASSIGN; 3947 NETDEV_ASSIGN; 3948 MAC_ASSIGN(peer, owe_info->peer); 3949 memcpy(__get_dynamic_array(ie), owe_info->ie, 3950 owe_info->ie_len); 3951 __entry->assoc_link_id = owe_info->assoc_link_id; 3952 MAC_ASSIGN(peer_mld_addr, owe_info->peer_mld_addr); 3953 ), 3954 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", peer: %pM," 3955 " assoc_link_id: %d, peer_mld_addr: %pM", 3956 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->peer, 3957 __entry->assoc_link_id, __entry->peer_mld_addr) 3958 ); 3959 3960 TRACE_EVENT(cfg80211_bss_color_notify, 3961 TP_PROTO(struct net_device *netdev, 3962 enum nl80211_commands cmd, 3963 u8 count, u64 color_bitmap), 3964 TP_ARGS(netdev, cmd, count, color_bitmap), 3965 TP_STRUCT__entry( 3966 NETDEV_ENTRY 3967 __field(u32, cmd) 3968 __field(u8, count) 3969 __field(u64, color_bitmap) 3970 ), 3971 TP_fast_assign( 3972 NETDEV_ASSIGN; 3973 __entry->cmd = cmd; 3974 __entry->count = count; 3975 __entry->color_bitmap = color_bitmap; 3976 ), 3977 TP_printk(NETDEV_PR_FMT ", cmd: %x, count: %u, bitmap: %llx", 3978 NETDEV_PR_ARG, __entry->cmd, __entry->count, 3979 __entry->color_bitmap) 3980 ); 3981 3982 TRACE_EVENT(cfg80211_assoc_comeback, 3983 TP_PROTO(struct wireless_dev *wdev, const u8 *ap_addr, u32 timeout), 3984 TP_ARGS(wdev, ap_addr, timeout), 3985 TP_STRUCT__entry( 3986 WDEV_ENTRY 3987 MAC_ENTRY(ap_addr) 3988 __field(u32, timeout) 3989 ), 3990 TP_fast_assign( 3991 WDEV_ASSIGN; 3992 MAC_ASSIGN(ap_addr, ap_addr); 3993 __entry->timeout = timeout; 3994 ), 3995 TP_printk(WDEV_PR_FMT ", %pM, timeout: %u TUs", 3996 WDEV_PR_ARG, __entry->ap_addr, __entry->timeout) 3997 ); 3998 3999 DECLARE_EVENT_CLASS(link_station_add_mod, 4000 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 4001 struct link_station_parameters *params), 4002 TP_ARGS(wiphy, netdev, params), 4003 TP_STRUCT__entry( 4004 WIPHY_ENTRY 4005 NETDEV_ENTRY 4006 __array(u8, mld_mac, 6) 4007 __array(u8, link_mac, 6) 4008 __field(u32, link_id) 4009 __dynamic_array(u8, supported_rates, 4010 params->supported_rates_len) 4011 __array(u8, ht_capa, (int)sizeof(struct ieee80211_ht_cap)) 4012 __array(u8, vht_capa, (int)sizeof(struct ieee80211_vht_cap)) 4013 __field(u8, opmode_notif) 4014 __field(bool, opmode_notif_used) 4015 __dynamic_array(u8, he_capa, params->he_capa_len) 4016 __array(u8, he_6ghz_capa, (int)sizeof(struct ieee80211_he_6ghz_capa)) 4017 __dynamic_array(u8, eht_capa, params->eht_capa_len) 4018 ), 4019 TP_fast_assign( 4020 WIPHY_ASSIGN; 4021 NETDEV_ASSIGN; 4022 memset(__entry->mld_mac, 0, 6); 4023 memset(__entry->link_mac, 0, 6); 4024 if (params->mld_mac) 4025 memcpy(__entry->mld_mac, params->mld_mac, 6); 4026 if (params->link_mac) 4027 memcpy(__entry->link_mac, params->link_mac, 6); 4028 __entry->link_id = params->link_id; 4029 if (params->supported_rates && params->supported_rates_len) 4030 memcpy(__get_dynamic_array(supported_rates), 4031 params->supported_rates, 4032 params->supported_rates_len); 4033 memset(__entry->ht_capa, 0, sizeof(struct ieee80211_ht_cap)); 4034 if (params->ht_capa) 4035 memcpy(__entry->ht_capa, params->ht_capa, 4036 sizeof(struct ieee80211_ht_cap)); 4037 memset(__entry->vht_capa, 0, sizeof(struct ieee80211_vht_cap)); 4038 if (params->vht_capa) 4039 memcpy(__entry->vht_capa, params->vht_capa, 4040 sizeof(struct ieee80211_vht_cap)); 4041 __entry->opmode_notif = params->opmode_notif; 4042 __entry->opmode_notif_used = params->opmode_notif_used; 4043 if (params->he_capa && params->he_capa_len) 4044 memcpy(__get_dynamic_array(he_capa), params->he_capa, 4045 params->he_capa_len); 4046 memset(__entry->he_6ghz_capa, 0, sizeof(struct ieee80211_he_6ghz_capa)); 4047 if (params->he_6ghz_capa) 4048 memcpy(__entry->he_6ghz_capa, params->he_6ghz_capa, 4049 sizeof(struct ieee80211_he_6ghz_capa)); 4050 if (params->eht_capa && params->eht_capa_len) 4051 memcpy(__get_dynamic_array(eht_capa), params->eht_capa, 4052 params->eht_capa_len); 4053 ), 4054 TP_printk(WIPHY_PR_FMT ", " NETDEV_PR_FMT ", station mac: %pM" 4055 ", link mac: %pM, link id: %u", 4056 WIPHY_PR_ARG, NETDEV_PR_ARG, __entry->mld_mac, 4057 __entry->link_mac, __entry->link_id) 4058 ); 4059 4060 DEFINE_EVENT(link_station_add_mod, rdev_add_link_station, 4061 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 4062 struct link_station_parameters *params), 4063 TP_ARGS(wiphy, netdev, params) 4064 ); 4065 4066 DEFINE_EVENT(link_station_add_mod, rdev_mod_link_station, 4067 TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, 4068 struct link_station_parameters *params), 4069 TP_ARGS(wiphy, netdev, params) 4070 ); 4071 4072 TRACE_EVENT(cfg80211_links_removed, 4073 TP_PROTO(struct net_device *netdev, u16 link_mask), 4074 TP_ARGS(netdev, link_mask), 4075 TP_STRUCT__entry( 4076 NETDEV_ENTRY 4077 __field(u16, link_mask) 4078 ), 4079 TP_fast_assign( 4080 NETDEV_ASSIGN; 4081 __entry->link_mask = link_mask; 4082 ), 4083 TP_printk(NETDEV_PR_FMT ", link_mask:%u", NETDEV_PR_ARG, 4084 __entry->link_mask) 4085 ); 4086 4087 #endif /* !__RDEV_OPS_TRACE || TRACE_HEADER_MULTI_READ */ 4088 4089 #undef TRACE_INCLUDE_PATH 4090 #define TRACE_INCLUDE_PATH . 4091 #undef TRACE_INCLUDE_FILE 4092 #define TRACE_INCLUDE_FILE trace 4093 #include <trace/define_trace.h> 4094