Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 1 | #if !defined(__MAC80211_DRIVER_TRACE) || defined(TRACE_HEADER_MULTI_READ) |
| 2 | #define __MAC80211_DRIVER_TRACE |
| 3 | |
| 4 | #include <linux/tracepoint.h> |
| 5 | #include <net/mac80211.h> |
| 6 | #include "ieee80211_i.h" |
| 7 | |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 8 | #undef TRACE_SYSTEM |
| 9 | #define TRACE_SYSTEM mac80211 |
| 10 | |
| 11 | #define MAXNAME 32 |
| 12 | #define LOCAL_ENTRY __array(char, wiphy_name, 32) |
| 13 | #define LOCAL_ASSIGN strlcpy(__entry->wiphy_name, wiphy_name(local->hw.wiphy), MAXNAME) |
| 14 | #define LOCAL_PR_FMT "%s" |
| 15 | #define LOCAL_PR_ARG __entry->wiphy_name |
| 16 | |
| 17 | #define STA_ENTRY __array(char, sta_addr, ETH_ALEN) |
| 18 | #define STA_ASSIGN (sta ? memcpy(__entry->sta_addr, sta->addr, ETH_ALEN) : memset(__entry->sta_addr, 0, ETH_ALEN)) |
| 19 | #define STA_PR_FMT " sta:%pM" |
| 20 | #define STA_PR_ARG __entry->sta_addr |
| 21 | |
Johannes Berg | 2ca27bc | 2010-09-16 14:58:23 +0200 | [diff] [blame] | 22 | #define VIF_ENTRY __field(enum nl80211_iftype, vif_type) __field(void *, sdata) \ |
| 23 | __field(bool, p2p) \ |
Johannes Berg | 12375ef | 2009-11-25 20:30:31 +0100 | [diff] [blame] | 24 | __string(vif_name, sdata->dev ? sdata->dev->name : "<nodev>") |
Johannes Berg | 2ca27bc | 2010-09-16 14:58:23 +0200 | [diff] [blame] | 25 | #define VIF_ASSIGN __entry->vif_type = sdata->vif.type; __entry->sdata = sdata; \ |
| 26 | __entry->p2p = sdata->vif.p2p; \ |
Johannes Berg | f142c6b | 2012-06-18 20:07:15 +0200 | [diff] [blame] | 27 | __assign_str(vif_name, sdata->dev ? sdata->dev->name : sdata->name) |
Johannes Berg | 2ca27bc | 2010-09-16 14:58:23 +0200 | [diff] [blame] | 28 | #define VIF_PR_FMT " vif:%s(%d%s)" |
| 29 | #define VIF_PR_ARG __get_str(vif_name), __entry->vif_type, __entry->p2p ? "/p2p" : "" |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 30 | |
Michal Kazior | c3645ea | 2012-06-26 14:37:17 +0200 | [diff] [blame^] | 31 | #define CHANCTX_ENTRY __field(int, freq) \ |
| 32 | __field(int, chantype) |
| 33 | #define CHANCTX_ASSIGN __entry->freq = ctx->conf.channel->center_freq; \ |
| 34 | __entry->chantype = ctx->conf.channel_type |
| 35 | #define CHANCTX_PR_FMT " freq:%d MHz chantype:%d" |
| 36 | #define CHANCTX_PR_ARG __entry->freq, __entry->chantype |
| 37 | |
| 38 | |
| 39 | |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 40 | /* |
| 41 | * Tracing for driver callbacks. |
| 42 | */ |
| 43 | |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 44 | DECLARE_EVENT_CLASS(local_only_evt, |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 45 | TP_PROTO(struct ieee80211_local *local), |
| 46 | TP_ARGS(local), |
| 47 | TP_STRUCT__entry( |
| 48 | LOCAL_ENTRY |
| 49 | ), |
| 50 | TP_fast_assign( |
| 51 | LOCAL_ASSIGN; |
| 52 | ), |
| 53 | TP_printk(LOCAL_PR_FMT, LOCAL_PR_ARG) |
| 54 | ); |
| 55 | |
Luciano Coelho | 92ddc11 | 2011-05-09 14:40:06 +0300 | [diff] [blame] | 56 | DECLARE_EVENT_CLASS(local_sdata_addr_evt, |
| 57 | TP_PROTO(struct ieee80211_local *local, |
| 58 | struct ieee80211_sub_if_data *sdata), |
| 59 | TP_ARGS(local, sdata), |
| 60 | |
| 61 | TP_STRUCT__entry( |
| 62 | LOCAL_ENTRY |
| 63 | VIF_ENTRY |
| 64 | __array(char, addr, 6) |
| 65 | ), |
| 66 | |
| 67 | TP_fast_assign( |
| 68 | LOCAL_ASSIGN; |
| 69 | VIF_ASSIGN; |
| 70 | memcpy(__entry->addr, sdata->vif.addr, 6); |
| 71 | ), |
| 72 | |
| 73 | TP_printk( |
| 74 | LOCAL_PR_FMT VIF_PR_FMT " addr:%pM", |
| 75 | LOCAL_PR_ARG, VIF_PR_ARG, __entry->addr |
| 76 | ) |
| 77 | ); |
| 78 | |
| 79 | DECLARE_EVENT_CLASS(local_u32_evt, |
| 80 | TP_PROTO(struct ieee80211_local *local, u32 value), |
| 81 | TP_ARGS(local, value), |
| 82 | |
| 83 | TP_STRUCT__entry( |
| 84 | LOCAL_ENTRY |
| 85 | __field(u32, value) |
| 86 | ), |
| 87 | |
| 88 | TP_fast_assign( |
| 89 | LOCAL_ASSIGN; |
| 90 | __entry->value = value; |
| 91 | ), |
| 92 | |
| 93 | TP_printk( |
| 94 | LOCAL_PR_FMT " value:%d", |
| 95 | LOCAL_PR_ARG, __entry->value |
| 96 | ) |
| 97 | ); |
| 98 | |
Luciano Coelho | 79f460c | 2011-05-11 17:09:36 +0300 | [diff] [blame] | 99 | DECLARE_EVENT_CLASS(local_sdata_evt, |
| 100 | TP_PROTO(struct ieee80211_local *local, |
| 101 | struct ieee80211_sub_if_data *sdata), |
| 102 | TP_ARGS(local, sdata), |
| 103 | |
| 104 | TP_STRUCT__entry( |
| 105 | LOCAL_ENTRY |
| 106 | VIF_ENTRY |
| 107 | ), |
| 108 | |
| 109 | TP_fast_assign( |
| 110 | LOCAL_ASSIGN; |
| 111 | VIF_ASSIGN; |
| 112 | ), |
| 113 | |
| 114 | TP_printk( |
| 115 | LOCAL_PR_FMT VIF_PR_FMT, |
| 116 | LOCAL_PR_ARG, VIF_PR_ARG |
| 117 | ) |
| 118 | ); |
| 119 | |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 120 | DEFINE_EVENT(local_only_evt, drv_return_void, |
| 121 | TP_PROTO(struct ieee80211_local *local), |
| 122 | TP_ARGS(local) |
| 123 | ); |
| 124 | |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 125 | TRACE_EVENT(drv_return_int, |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 126 | TP_PROTO(struct ieee80211_local *local, int ret), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 127 | TP_ARGS(local, ret), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 128 | TP_STRUCT__entry( |
| 129 | LOCAL_ENTRY |
| 130 | __field(int, ret) |
| 131 | ), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 132 | TP_fast_assign( |
| 133 | LOCAL_ASSIGN; |
| 134 | __entry->ret = ret; |
| 135 | ), |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 136 | TP_printk(LOCAL_PR_FMT " - %d", LOCAL_PR_ARG, __entry->ret) |
| 137 | ); |
| 138 | |
Vivek Natarajan | e8306f9 | 2011-04-06 11:41:10 +0530 | [diff] [blame] | 139 | TRACE_EVENT(drv_return_bool, |
| 140 | TP_PROTO(struct ieee80211_local *local, bool ret), |
| 141 | TP_ARGS(local, ret), |
| 142 | TP_STRUCT__entry( |
| 143 | LOCAL_ENTRY |
| 144 | __field(bool, ret) |
| 145 | ), |
| 146 | TP_fast_assign( |
| 147 | LOCAL_ASSIGN; |
| 148 | __entry->ret = ret; |
| 149 | ), |
| 150 | TP_printk(LOCAL_PR_FMT " - %s", LOCAL_PR_ARG, (__entry->ret) ? |
| 151 | "true" : "false") |
| 152 | ); |
| 153 | |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 154 | TRACE_EVENT(drv_return_u64, |
| 155 | TP_PROTO(struct ieee80211_local *local, u64 ret), |
| 156 | TP_ARGS(local, ret), |
| 157 | TP_STRUCT__entry( |
| 158 | LOCAL_ENTRY |
| 159 | __field(u64, ret) |
| 160 | ), |
| 161 | TP_fast_assign( |
| 162 | LOCAL_ASSIGN; |
| 163 | __entry->ret = ret; |
| 164 | ), |
| 165 | TP_printk(LOCAL_PR_FMT " - %llu", LOCAL_PR_ARG, __entry->ret) |
| 166 | ); |
| 167 | |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 168 | DEFINE_EVENT(local_only_evt, drv_start, |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 169 | TP_PROTO(struct ieee80211_local *local), |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 170 | TP_ARGS(local) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 171 | ); |
| 172 | |
Ben Greear | e352114 | 2012-04-23 12:50:31 -0700 | [diff] [blame] | 173 | DEFINE_EVENT(local_u32_evt, drv_get_et_strings, |
| 174 | TP_PROTO(struct ieee80211_local *local, u32 sset), |
| 175 | TP_ARGS(local, sset) |
| 176 | ); |
| 177 | |
| 178 | DEFINE_EVENT(local_u32_evt, drv_get_et_sset_count, |
| 179 | TP_PROTO(struct ieee80211_local *local, u32 sset), |
| 180 | TP_ARGS(local, sset) |
| 181 | ); |
| 182 | |
| 183 | DEFINE_EVENT(local_only_evt, drv_get_et_stats, |
| 184 | TP_PROTO(struct ieee80211_local *local), |
| 185 | TP_ARGS(local) |
| 186 | ); |
| 187 | |
Johannes Berg | eecc480 | 2011-05-04 15:37:29 +0200 | [diff] [blame] | 188 | DEFINE_EVENT(local_only_evt, drv_suspend, |
| 189 | TP_PROTO(struct ieee80211_local *local), |
| 190 | TP_ARGS(local) |
| 191 | ); |
| 192 | |
| 193 | DEFINE_EVENT(local_only_evt, drv_resume, |
| 194 | TP_PROTO(struct ieee80211_local *local), |
| 195 | TP_ARGS(local) |
| 196 | ); |
| 197 | |
Johannes Berg | 6d52563 | 2012-04-04 15:05:25 +0200 | [diff] [blame] | 198 | TRACE_EVENT(drv_set_wakeup, |
| 199 | TP_PROTO(struct ieee80211_local *local, bool enabled), |
| 200 | TP_ARGS(local, enabled), |
| 201 | TP_STRUCT__entry( |
| 202 | LOCAL_ENTRY |
| 203 | __field(bool, enabled) |
| 204 | ), |
| 205 | TP_fast_assign( |
| 206 | LOCAL_ASSIGN; |
| 207 | __entry->enabled = enabled; |
| 208 | ), |
| 209 | TP_printk(LOCAL_PR_FMT " enabled:%d", LOCAL_PR_ARG, __entry->enabled) |
| 210 | ); |
| 211 | |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 212 | DEFINE_EVENT(local_only_evt, drv_stop, |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 213 | TP_PROTO(struct ieee80211_local *local), |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 214 | TP_ARGS(local) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 215 | ); |
| 216 | |
Luciano Coelho | 92ddc11 | 2011-05-09 14:40:06 +0300 | [diff] [blame] | 217 | DEFINE_EVENT(local_sdata_addr_evt, drv_add_interface, |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 218 | TP_PROTO(struct ieee80211_local *local, |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 219 | struct ieee80211_sub_if_data *sdata), |
Luciano Coelho | 92ddc11 | 2011-05-09 14:40:06 +0300 | [diff] [blame] | 220 | TP_ARGS(local, sdata) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 221 | ); |
| 222 | |
Johannes Berg | 34d4bc4 | 2010-08-27 12:35:58 +0200 | [diff] [blame] | 223 | TRACE_EVENT(drv_change_interface, |
| 224 | TP_PROTO(struct ieee80211_local *local, |
| 225 | struct ieee80211_sub_if_data *sdata, |
Johannes Berg | 2ca27bc | 2010-09-16 14:58:23 +0200 | [diff] [blame] | 226 | enum nl80211_iftype type, bool p2p), |
Johannes Berg | 34d4bc4 | 2010-08-27 12:35:58 +0200 | [diff] [blame] | 227 | |
Johannes Berg | 2ca27bc | 2010-09-16 14:58:23 +0200 | [diff] [blame] | 228 | TP_ARGS(local, sdata, type, p2p), |
Johannes Berg | 34d4bc4 | 2010-08-27 12:35:58 +0200 | [diff] [blame] | 229 | |
| 230 | TP_STRUCT__entry( |
| 231 | LOCAL_ENTRY |
| 232 | VIF_ENTRY |
| 233 | __field(u32, new_type) |
Johannes Berg | 2ca27bc | 2010-09-16 14:58:23 +0200 | [diff] [blame] | 234 | __field(bool, new_p2p) |
Johannes Berg | 34d4bc4 | 2010-08-27 12:35:58 +0200 | [diff] [blame] | 235 | ), |
| 236 | |
| 237 | TP_fast_assign( |
| 238 | LOCAL_ASSIGN; |
| 239 | VIF_ASSIGN; |
| 240 | __entry->new_type = type; |
Johannes Berg | 2ca27bc | 2010-09-16 14:58:23 +0200 | [diff] [blame] | 241 | __entry->new_p2p = p2p; |
Johannes Berg | 34d4bc4 | 2010-08-27 12:35:58 +0200 | [diff] [blame] | 242 | ), |
| 243 | |
| 244 | TP_printk( |
Johannes Berg | 2ca27bc | 2010-09-16 14:58:23 +0200 | [diff] [blame] | 245 | LOCAL_PR_FMT VIF_PR_FMT " new type:%d%s", |
| 246 | LOCAL_PR_ARG, VIF_PR_ARG, __entry->new_type, |
| 247 | __entry->new_p2p ? "/p2p" : "" |
Johannes Berg | 34d4bc4 | 2010-08-27 12:35:58 +0200 | [diff] [blame] | 248 | ) |
| 249 | ); |
| 250 | |
Luciano Coelho | 92ddc11 | 2011-05-09 14:40:06 +0300 | [diff] [blame] | 251 | DEFINE_EVENT(local_sdata_addr_evt, drv_remove_interface, |
| 252 | TP_PROTO(struct ieee80211_local *local, |
| 253 | struct ieee80211_sub_if_data *sdata), |
| 254 | TP_ARGS(local, sdata) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 255 | ); |
| 256 | |
| 257 | TRACE_EVENT(drv_config, |
| 258 | TP_PROTO(struct ieee80211_local *local, |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 259 | u32 changed), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 260 | |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 261 | TP_ARGS(local, changed), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 262 | |
| 263 | TP_STRUCT__entry( |
| 264 | LOCAL_ENTRY |
| 265 | __field(u32, changed) |
Johannes Berg | f911ab8 | 2009-11-25 19:07:20 +0100 | [diff] [blame] | 266 | __field(u32, flags) |
| 267 | __field(int, power_level) |
| 268 | __field(int, dynamic_ps_timeout) |
| 269 | __field(int, max_sleep_period) |
| 270 | __field(u16, listen_interval) |
| 271 | __field(u8, long_frame_max_tx_count) |
| 272 | __field(u8, short_frame_max_tx_count) |
| 273 | __field(int, center_freq) |
| 274 | __field(int, channel_type) |
Johannes Berg | 0f78231 | 2009-12-01 13:37:02 +0100 | [diff] [blame] | 275 | __field(int, smps) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 276 | ), |
| 277 | |
| 278 | TP_fast_assign( |
| 279 | LOCAL_ASSIGN; |
| 280 | __entry->changed = changed; |
Johannes Berg | f911ab8 | 2009-11-25 19:07:20 +0100 | [diff] [blame] | 281 | __entry->flags = local->hw.conf.flags; |
| 282 | __entry->power_level = local->hw.conf.power_level; |
| 283 | __entry->dynamic_ps_timeout = local->hw.conf.dynamic_ps_timeout; |
| 284 | __entry->max_sleep_period = local->hw.conf.max_sleep_period; |
| 285 | __entry->listen_interval = local->hw.conf.listen_interval; |
Johannes Berg | 3d01be7 | 2012-07-26 14:27:39 +0200 | [diff] [blame] | 286 | __entry->long_frame_max_tx_count = |
| 287 | local->hw.conf.long_frame_max_tx_count; |
| 288 | __entry->short_frame_max_tx_count = |
| 289 | local->hw.conf.short_frame_max_tx_count; |
| 290 | __entry->center_freq = local->hw.conf.channel ? |
| 291 | local->hw.conf.channel->center_freq : 0; |
Johannes Berg | f911ab8 | 2009-11-25 19:07:20 +0100 | [diff] [blame] | 292 | __entry->channel_type = local->hw.conf.channel_type; |
Johannes Berg | 0f78231 | 2009-12-01 13:37:02 +0100 | [diff] [blame] | 293 | __entry->smps = local->hw.conf.smps_mode; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 294 | ), |
| 295 | |
| 296 | TP_printk( |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 297 | LOCAL_PR_FMT " ch:%#x freq:%d", |
| 298 | LOCAL_PR_ARG, __entry->changed, __entry->center_freq |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 299 | ) |
| 300 | ); |
| 301 | |
| 302 | TRACE_EVENT(drv_bss_info_changed, |
| 303 | TP_PROTO(struct ieee80211_local *local, |
Johannes Berg | 12375ef | 2009-11-25 20:30:31 +0100 | [diff] [blame] | 304 | struct ieee80211_sub_if_data *sdata, |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 305 | struct ieee80211_bss_conf *info, |
| 306 | u32 changed), |
| 307 | |
Johannes Berg | 12375ef | 2009-11-25 20:30:31 +0100 | [diff] [blame] | 308 | TP_ARGS(local, sdata, info, changed), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 309 | |
| 310 | TP_STRUCT__entry( |
| 311 | LOCAL_ENTRY |
| 312 | VIF_ENTRY |
| 313 | __field(bool, assoc) |
| 314 | __field(u16, aid) |
| 315 | __field(bool, cts) |
| 316 | __field(bool, shortpre) |
| 317 | __field(bool, shortslot) |
| 318 | __field(u8, dtimper) |
| 319 | __field(u16, bcnint) |
| 320 | __field(u16, assoc_cap) |
Johannes Berg | 8c358bc | 2012-05-22 22:13:05 +0200 | [diff] [blame] | 321 | __field(u64, sync_tsf) |
| 322 | __field(u32, sync_device_ts) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 323 | __field(u32, basic_rates) |
| 324 | __field(u32, changed) |
Johannes Berg | f911ab8 | 2009-11-25 19:07:20 +0100 | [diff] [blame] | 325 | __field(bool, enable_beacon) |
| 326 | __field(u16, ht_operation_mode) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 327 | ), |
| 328 | |
| 329 | TP_fast_assign( |
| 330 | LOCAL_ASSIGN; |
| 331 | VIF_ASSIGN; |
| 332 | __entry->changed = changed; |
| 333 | __entry->aid = info->aid; |
| 334 | __entry->assoc = info->assoc; |
| 335 | __entry->shortpre = info->use_short_preamble; |
| 336 | __entry->cts = info->use_cts_prot; |
| 337 | __entry->shortslot = info->use_short_slot; |
| 338 | __entry->dtimper = info->dtim_period; |
| 339 | __entry->bcnint = info->beacon_int; |
| 340 | __entry->assoc_cap = info->assoc_capability; |
Johannes Berg | 8c358bc | 2012-05-22 22:13:05 +0200 | [diff] [blame] | 341 | __entry->sync_tsf = info->sync_tsf; |
| 342 | __entry->sync_device_ts = info->sync_device_ts; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 343 | __entry->basic_rates = info->basic_rates; |
Johannes Berg | f911ab8 | 2009-11-25 19:07:20 +0100 | [diff] [blame] | 344 | __entry->enable_beacon = info->enable_beacon; |
| 345 | __entry->ht_operation_mode = info->ht_operation_mode; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 346 | ), |
| 347 | |
| 348 | TP_printk( |
| 349 | LOCAL_PR_FMT VIF_PR_FMT " changed:%#x", |
| 350 | LOCAL_PR_ARG, VIF_PR_ARG, __entry->changed |
| 351 | ) |
| 352 | ); |
| 353 | |
Johannes Berg | 3ac64be | 2009-08-17 16:16:53 +0200 | [diff] [blame] | 354 | TRACE_EVENT(drv_prepare_multicast, |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 355 | TP_PROTO(struct ieee80211_local *local, int mc_count), |
Johannes Berg | 3ac64be | 2009-08-17 16:16:53 +0200 | [diff] [blame] | 356 | |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 357 | TP_ARGS(local, mc_count), |
Johannes Berg | 3ac64be | 2009-08-17 16:16:53 +0200 | [diff] [blame] | 358 | |
| 359 | TP_STRUCT__entry( |
| 360 | LOCAL_ENTRY |
| 361 | __field(int, mc_count) |
Johannes Berg | 3ac64be | 2009-08-17 16:16:53 +0200 | [diff] [blame] | 362 | ), |
| 363 | |
| 364 | TP_fast_assign( |
| 365 | LOCAL_ASSIGN; |
| 366 | __entry->mc_count = mc_count; |
Johannes Berg | 3ac64be | 2009-08-17 16:16:53 +0200 | [diff] [blame] | 367 | ), |
| 368 | |
| 369 | TP_printk( |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 370 | LOCAL_PR_FMT " prepare mc (%d)", |
| 371 | LOCAL_PR_ARG, __entry->mc_count |
Johannes Berg | 3ac64be | 2009-08-17 16:16:53 +0200 | [diff] [blame] | 372 | ) |
| 373 | ); |
| 374 | |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 375 | TRACE_EVENT(drv_configure_filter, |
| 376 | TP_PROTO(struct ieee80211_local *local, |
| 377 | unsigned int changed_flags, |
| 378 | unsigned int *total_flags, |
Johannes Berg | 3ac64be | 2009-08-17 16:16:53 +0200 | [diff] [blame] | 379 | u64 multicast), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 380 | |
Johannes Berg | 3ac64be | 2009-08-17 16:16:53 +0200 | [diff] [blame] | 381 | TP_ARGS(local, changed_flags, total_flags, multicast), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 382 | |
| 383 | TP_STRUCT__entry( |
| 384 | LOCAL_ENTRY |
| 385 | __field(unsigned int, changed) |
| 386 | __field(unsigned int, total) |
Johannes Berg | 3ac64be | 2009-08-17 16:16:53 +0200 | [diff] [blame] | 387 | __field(u64, multicast) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 388 | ), |
| 389 | |
| 390 | TP_fast_assign( |
| 391 | LOCAL_ASSIGN; |
| 392 | __entry->changed = changed_flags; |
| 393 | __entry->total = *total_flags; |
Johannes Berg | 3ac64be | 2009-08-17 16:16:53 +0200 | [diff] [blame] | 394 | __entry->multicast = multicast; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 395 | ), |
| 396 | |
| 397 | TP_printk( |
Johannes Berg | 3ac64be | 2009-08-17 16:16:53 +0200 | [diff] [blame] | 398 | LOCAL_PR_FMT " changed:%#x total:%#x", |
| 399 | LOCAL_PR_ARG, __entry->changed, __entry->total |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 400 | ) |
| 401 | ); |
| 402 | |
| 403 | TRACE_EVENT(drv_set_tim, |
| 404 | TP_PROTO(struct ieee80211_local *local, |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 405 | struct ieee80211_sta *sta, bool set), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 406 | |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 407 | TP_ARGS(local, sta, set), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 408 | |
| 409 | TP_STRUCT__entry( |
| 410 | LOCAL_ENTRY |
| 411 | STA_ENTRY |
| 412 | __field(bool, set) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 413 | ), |
| 414 | |
| 415 | TP_fast_assign( |
| 416 | LOCAL_ASSIGN; |
| 417 | STA_ASSIGN; |
| 418 | __entry->set = set; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 419 | ), |
| 420 | |
| 421 | TP_printk( |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 422 | LOCAL_PR_FMT STA_PR_FMT " set:%d", |
| 423 | LOCAL_PR_ARG, STA_PR_FMT, __entry->set |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 424 | ) |
| 425 | ); |
| 426 | |
| 427 | TRACE_EVENT(drv_set_key, |
| 428 | TP_PROTO(struct ieee80211_local *local, |
Johannes Berg | 12375ef | 2009-11-25 20:30:31 +0100 | [diff] [blame] | 429 | enum set_key_cmd cmd, struct ieee80211_sub_if_data *sdata, |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 430 | struct ieee80211_sta *sta, |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 431 | struct ieee80211_key_conf *key), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 432 | |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 433 | TP_ARGS(local, cmd, sdata, sta, key), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 434 | |
| 435 | TP_STRUCT__entry( |
| 436 | LOCAL_ENTRY |
| 437 | VIF_ENTRY |
| 438 | STA_ENTRY |
Johannes Berg | 97359d1 | 2010-08-10 09:46:38 +0200 | [diff] [blame] | 439 | __field(u32, cipher) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 440 | __field(u8, hw_key_idx) |
| 441 | __field(u8, flags) |
| 442 | __field(s8, keyidx) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 443 | ), |
| 444 | |
| 445 | TP_fast_assign( |
| 446 | LOCAL_ASSIGN; |
| 447 | VIF_ASSIGN; |
| 448 | STA_ASSIGN; |
Johannes Berg | 97359d1 | 2010-08-10 09:46:38 +0200 | [diff] [blame] | 449 | __entry->cipher = key->cipher; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 450 | __entry->flags = key->flags; |
| 451 | __entry->keyidx = key->keyidx; |
| 452 | __entry->hw_key_idx = key->hw_key_idx; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 453 | ), |
| 454 | |
| 455 | TP_printk( |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 456 | LOCAL_PR_FMT VIF_PR_FMT STA_PR_FMT, |
| 457 | LOCAL_PR_ARG, VIF_PR_ARG, STA_PR_ARG |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 458 | ) |
| 459 | ); |
| 460 | |
| 461 | TRACE_EVENT(drv_update_tkip_key, |
| 462 | TP_PROTO(struct ieee80211_local *local, |
Johannes Berg | b3fbdcf | 2010-01-21 11:40:47 +0100 | [diff] [blame] | 463 | struct ieee80211_sub_if_data *sdata, |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 464 | struct ieee80211_key_conf *conf, |
Johannes Berg | b3fbdcf | 2010-01-21 11:40:47 +0100 | [diff] [blame] | 465 | struct ieee80211_sta *sta, u32 iv32), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 466 | |
Johannes Berg | b3fbdcf | 2010-01-21 11:40:47 +0100 | [diff] [blame] | 467 | TP_ARGS(local, sdata, conf, sta, iv32), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 468 | |
| 469 | TP_STRUCT__entry( |
| 470 | LOCAL_ENTRY |
Johannes Berg | b3fbdcf | 2010-01-21 11:40:47 +0100 | [diff] [blame] | 471 | VIF_ENTRY |
| 472 | STA_ENTRY |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 473 | __field(u32, iv32) |
| 474 | ), |
| 475 | |
| 476 | TP_fast_assign( |
| 477 | LOCAL_ASSIGN; |
Johannes Berg | b3fbdcf | 2010-01-21 11:40:47 +0100 | [diff] [blame] | 478 | VIF_ASSIGN; |
| 479 | STA_ASSIGN; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 480 | __entry->iv32 = iv32; |
| 481 | ), |
| 482 | |
| 483 | TP_printk( |
Johannes Berg | b3fbdcf | 2010-01-21 11:40:47 +0100 | [diff] [blame] | 484 | LOCAL_PR_FMT VIF_PR_FMT STA_PR_FMT " iv32:%#x", |
| 485 | LOCAL_PR_ARG,VIF_PR_ARG,STA_PR_ARG, __entry->iv32 |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 486 | ) |
| 487 | ); |
| 488 | |
Luciano Coelho | 79f460c | 2011-05-11 17:09:36 +0300 | [diff] [blame] | 489 | DEFINE_EVENT(local_sdata_evt, drv_hw_scan, |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 490 | TP_PROTO(struct ieee80211_local *local, |
Luciano Coelho | 79f460c | 2011-05-11 17:09:36 +0300 | [diff] [blame] | 491 | struct ieee80211_sub_if_data *sdata), |
| 492 | TP_ARGS(local, sdata) |
| 493 | ); |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 494 | |
Eliad Peller | b856439 | 2011-06-13 12:47:30 +0300 | [diff] [blame] | 495 | DEFINE_EVENT(local_sdata_evt, drv_cancel_hw_scan, |
| 496 | TP_PROTO(struct ieee80211_local *local, |
| 497 | struct ieee80211_sub_if_data *sdata), |
| 498 | TP_ARGS(local, sdata) |
| 499 | ); |
| 500 | |
Luciano Coelho | 79f460c | 2011-05-11 17:09:36 +0300 | [diff] [blame] | 501 | DEFINE_EVENT(local_sdata_evt, drv_sched_scan_start, |
| 502 | TP_PROTO(struct ieee80211_local *local, |
| 503 | struct ieee80211_sub_if_data *sdata), |
| 504 | TP_ARGS(local, sdata) |
| 505 | ); |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 506 | |
Luciano Coelho | 79f460c | 2011-05-11 17:09:36 +0300 | [diff] [blame] | 507 | DEFINE_EVENT(local_sdata_evt, drv_sched_scan_stop, |
| 508 | TP_PROTO(struct ieee80211_local *local, |
| 509 | struct ieee80211_sub_if_data *sdata), |
| 510 | TP_ARGS(local, sdata) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 511 | ); |
| 512 | |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 513 | DEFINE_EVENT(local_only_evt, drv_sw_scan_start, |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 514 | TP_PROTO(struct ieee80211_local *local), |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 515 | TP_ARGS(local) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 516 | ); |
| 517 | |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 518 | DEFINE_EVENT(local_only_evt, drv_sw_scan_complete, |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 519 | TP_PROTO(struct ieee80211_local *local), |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 520 | TP_ARGS(local) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 521 | ); |
| 522 | |
| 523 | TRACE_EVENT(drv_get_stats, |
| 524 | TP_PROTO(struct ieee80211_local *local, |
| 525 | struct ieee80211_low_level_stats *stats, |
| 526 | int ret), |
| 527 | |
| 528 | TP_ARGS(local, stats, ret), |
| 529 | |
| 530 | TP_STRUCT__entry( |
| 531 | LOCAL_ENTRY |
| 532 | __field(int, ret) |
| 533 | __field(unsigned int, ackfail) |
| 534 | __field(unsigned int, rtsfail) |
| 535 | __field(unsigned int, fcserr) |
| 536 | __field(unsigned int, rtssucc) |
| 537 | ), |
| 538 | |
| 539 | TP_fast_assign( |
| 540 | LOCAL_ASSIGN; |
| 541 | __entry->ret = ret; |
| 542 | __entry->ackfail = stats->dot11ACKFailureCount; |
| 543 | __entry->rtsfail = stats->dot11RTSFailureCount; |
| 544 | __entry->fcserr = stats->dot11FCSErrorCount; |
| 545 | __entry->rtssucc = stats->dot11RTSSuccessCount; |
| 546 | ), |
| 547 | |
| 548 | TP_printk( |
| 549 | LOCAL_PR_FMT " ret:%d", |
| 550 | LOCAL_PR_ARG, __entry->ret |
| 551 | ) |
| 552 | ); |
| 553 | |
| 554 | TRACE_EVENT(drv_get_tkip_seq, |
| 555 | TP_PROTO(struct ieee80211_local *local, |
| 556 | u8 hw_key_idx, u32 *iv32, u16 *iv16), |
| 557 | |
| 558 | TP_ARGS(local, hw_key_idx, iv32, iv16), |
| 559 | |
| 560 | TP_STRUCT__entry( |
| 561 | LOCAL_ENTRY |
| 562 | __field(u8, hw_key_idx) |
| 563 | __field(u32, iv32) |
| 564 | __field(u16, iv16) |
| 565 | ), |
| 566 | |
| 567 | TP_fast_assign( |
| 568 | LOCAL_ASSIGN; |
| 569 | __entry->hw_key_idx = hw_key_idx; |
| 570 | __entry->iv32 = *iv32; |
| 571 | __entry->iv16 = *iv16; |
| 572 | ), |
| 573 | |
| 574 | TP_printk( |
| 575 | LOCAL_PR_FMT, LOCAL_PR_ARG |
| 576 | ) |
| 577 | ); |
| 578 | |
Luciano Coelho | 92ddc11 | 2011-05-09 14:40:06 +0300 | [diff] [blame] | 579 | DEFINE_EVENT(local_u32_evt, drv_set_frag_threshold, |
Arik Nemtsov | f23a478 | 2010-11-08 11:51:06 +0200 | [diff] [blame] | 580 | TP_PROTO(struct ieee80211_local *local, u32 value), |
Luciano Coelho | 92ddc11 | 2011-05-09 14:40:06 +0300 | [diff] [blame] | 581 | TP_ARGS(local, value) |
Arik Nemtsov | f23a478 | 2010-11-08 11:51:06 +0200 | [diff] [blame] | 582 | ); |
| 583 | |
Luciano Coelho | 92ddc11 | 2011-05-09 14:40:06 +0300 | [diff] [blame] | 584 | DEFINE_EVENT(local_u32_evt, drv_set_rts_threshold, |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 585 | TP_PROTO(struct ieee80211_local *local, u32 value), |
Luciano Coelho | 92ddc11 | 2011-05-09 14:40:06 +0300 | [diff] [blame] | 586 | TP_ARGS(local, value) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 587 | ); |
| 588 | |
Lukáš Turek | 310bc67 | 2009-12-21 22:50:48 +0100 | [diff] [blame] | 589 | TRACE_EVENT(drv_set_coverage_class, |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 590 | TP_PROTO(struct ieee80211_local *local, u8 value), |
Lukáš Turek | 310bc67 | 2009-12-21 22:50:48 +0100 | [diff] [blame] | 591 | |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 592 | TP_ARGS(local, value), |
Lukáš Turek | 310bc67 | 2009-12-21 22:50:48 +0100 | [diff] [blame] | 593 | |
| 594 | TP_STRUCT__entry( |
| 595 | LOCAL_ENTRY |
| 596 | __field(u8, value) |
Lukáš Turek | 310bc67 | 2009-12-21 22:50:48 +0100 | [diff] [blame] | 597 | ), |
| 598 | |
| 599 | TP_fast_assign( |
| 600 | LOCAL_ASSIGN; |
Lukáš Turek | 310bc67 | 2009-12-21 22:50:48 +0100 | [diff] [blame] | 601 | __entry->value = value; |
| 602 | ), |
| 603 | |
| 604 | TP_printk( |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 605 | LOCAL_PR_FMT " value:%d", |
| 606 | LOCAL_PR_ARG, __entry->value |
Lukáš Turek | 310bc67 | 2009-12-21 22:50:48 +0100 | [diff] [blame] | 607 | ) |
| 608 | ); |
| 609 | |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 610 | TRACE_EVENT(drv_sta_notify, |
| 611 | TP_PROTO(struct ieee80211_local *local, |
Johannes Berg | 12375ef | 2009-11-25 20:30:31 +0100 | [diff] [blame] | 612 | struct ieee80211_sub_if_data *sdata, |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 613 | enum sta_notify_cmd cmd, |
| 614 | struct ieee80211_sta *sta), |
| 615 | |
Johannes Berg | 12375ef | 2009-11-25 20:30:31 +0100 | [diff] [blame] | 616 | TP_ARGS(local, sdata, cmd, sta), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 617 | |
| 618 | TP_STRUCT__entry( |
| 619 | LOCAL_ENTRY |
| 620 | VIF_ENTRY |
| 621 | STA_ENTRY |
| 622 | __field(u32, cmd) |
| 623 | ), |
| 624 | |
| 625 | TP_fast_assign( |
| 626 | LOCAL_ASSIGN; |
| 627 | VIF_ASSIGN; |
| 628 | STA_ASSIGN; |
| 629 | __entry->cmd = cmd; |
| 630 | ), |
| 631 | |
| 632 | TP_printk( |
| 633 | LOCAL_PR_FMT VIF_PR_FMT STA_PR_FMT " cmd:%d", |
| 634 | LOCAL_PR_ARG, VIF_PR_ARG, STA_PR_ARG, __entry->cmd |
| 635 | ) |
| 636 | ); |
| 637 | |
Johannes Berg | f09603a | 2012-01-20 13:55:21 +0100 | [diff] [blame] | 638 | TRACE_EVENT(drv_sta_state, |
| 639 | TP_PROTO(struct ieee80211_local *local, |
| 640 | struct ieee80211_sub_if_data *sdata, |
| 641 | struct ieee80211_sta *sta, |
| 642 | enum ieee80211_sta_state old_state, |
| 643 | enum ieee80211_sta_state new_state), |
| 644 | |
| 645 | TP_ARGS(local, sdata, sta, old_state, new_state), |
| 646 | |
| 647 | TP_STRUCT__entry( |
| 648 | LOCAL_ENTRY |
| 649 | VIF_ENTRY |
| 650 | STA_ENTRY |
| 651 | __field(u32, old_state) |
| 652 | __field(u32, new_state) |
| 653 | ), |
| 654 | |
| 655 | TP_fast_assign( |
| 656 | LOCAL_ASSIGN; |
| 657 | VIF_ASSIGN; |
| 658 | STA_ASSIGN; |
| 659 | __entry->old_state = old_state; |
| 660 | __entry->new_state = new_state; |
| 661 | ), |
| 662 | |
| 663 | TP_printk( |
| 664 | LOCAL_PR_FMT VIF_PR_FMT STA_PR_FMT " state: %d->%d", |
| 665 | LOCAL_PR_ARG, VIF_PR_ARG, STA_PR_ARG, |
| 666 | __entry->old_state, __entry->new_state |
| 667 | ) |
| 668 | ); |
| 669 | |
Johannes Berg | 8f727ef | 2012-03-30 08:43:32 +0200 | [diff] [blame] | 670 | TRACE_EVENT(drv_sta_rc_update, |
| 671 | TP_PROTO(struct ieee80211_local *local, |
| 672 | struct ieee80211_sub_if_data *sdata, |
| 673 | struct ieee80211_sta *sta, |
| 674 | u32 changed), |
| 675 | |
| 676 | TP_ARGS(local, sdata, sta, changed), |
| 677 | |
| 678 | TP_STRUCT__entry( |
| 679 | LOCAL_ENTRY |
| 680 | VIF_ENTRY |
| 681 | STA_ENTRY |
| 682 | __field(u32, changed) |
| 683 | ), |
| 684 | |
| 685 | TP_fast_assign( |
| 686 | LOCAL_ASSIGN; |
| 687 | VIF_ASSIGN; |
| 688 | STA_ASSIGN; |
| 689 | __entry->changed = changed; |
| 690 | ), |
| 691 | |
| 692 | TP_printk( |
| 693 | LOCAL_PR_FMT VIF_PR_FMT STA_PR_FMT " changed: 0x%x", |
| 694 | LOCAL_PR_ARG, VIF_PR_ARG, STA_PR_ARG, __entry->changed |
| 695 | ) |
| 696 | ); |
| 697 | |
Johannes Berg | 34e8950 | 2010-02-03 13:59:58 +0100 | [diff] [blame] | 698 | TRACE_EVENT(drv_sta_add, |
| 699 | TP_PROTO(struct ieee80211_local *local, |
| 700 | struct ieee80211_sub_if_data *sdata, |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 701 | struct ieee80211_sta *sta), |
Johannes Berg | 34e8950 | 2010-02-03 13:59:58 +0100 | [diff] [blame] | 702 | |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 703 | TP_ARGS(local, sdata, sta), |
Johannes Berg | 34e8950 | 2010-02-03 13:59:58 +0100 | [diff] [blame] | 704 | |
| 705 | TP_STRUCT__entry( |
| 706 | LOCAL_ENTRY |
| 707 | VIF_ENTRY |
| 708 | STA_ENTRY |
Johannes Berg | 34e8950 | 2010-02-03 13:59:58 +0100 | [diff] [blame] | 709 | ), |
| 710 | |
| 711 | TP_fast_assign( |
| 712 | LOCAL_ASSIGN; |
| 713 | VIF_ASSIGN; |
| 714 | STA_ASSIGN; |
Johannes Berg | 34e8950 | 2010-02-03 13:59:58 +0100 | [diff] [blame] | 715 | ), |
| 716 | |
| 717 | TP_printk( |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 718 | LOCAL_PR_FMT VIF_PR_FMT STA_PR_FMT, |
| 719 | LOCAL_PR_ARG, VIF_PR_ARG, STA_PR_ARG |
Johannes Berg | 34e8950 | 2010-02-03 13:59:58 +0100 | [diff] [blame] | 720 | ) |
| 721 | ); |
| 722 | |
| 723 | TRACE_EVENT(drv_sta_remove, |
| 724 | TP_PROTO(struct ieee80211_local *local, |
| 725 | struct ieee80211_sub_if_data *sdata, |
| 726 | struct ieee80211_sta *sta), |
| 727 | |
| 728 | TP_ARGS(local, sdata, sta), |
| 729 | |
| 730 | TP_STRUCT__entry( |
| 731 | LOCAL_ENTRY |
| 732 | VIF_ENTRY |
| 733 | STA_ENTRY |
| 734 | ), |
| 735 | |
| 736 | TP_fast_assign( |
| 737 | LOCAL_ASSIGN; |
| 738 | VIF_ASSIGN; |
| 739 | STA_ASSIGN; |
| 740 | ), |
| 741 | |
| 742 | TP_printk( |
| 743 | LOCAL_PR_FMT VIF_PR_FMT STA_PR_FMT, |
| 744 | LOCAL_PR_ARG, VIF_PR_ARG, STA_PR_ARG |
| 745 | ) |
| 746 | ); |
| 747 | |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 748 | TRACE_EVENT(drv_conf_tx, |
Eliad Peller | f6f3def | 2011-09-25 20:06:54 +0300 | [diff] [blame] | 749 | TP_PROTO(struct ieee80211_local *local, |
| 750 | struct ieee80211_sub_if_data *sdata, |
Johannes Berg | a3304b0 | 2012-03-28 11:04:24 +0200 | [diff] [blame] | 751 | u16 ac, const struct ieee80211_tx_queue_params *params), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 752 | |
Johannes Berg | a3304b0 | 2012-03-28 11:04:24 +0200 | [diff] [blame] | 753 | TP_ARGS(local, sdata, ac, params), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 754 | |
| 755 | TP_STRUCT__entry( |
| 756 | LOCAL_ENTRY |
Eliad Peller | f6f3def | 2011-09-25 20:06:54 +0300 | [diff] [blame] | 757 | VIF_ENTRY |
Johannes Berg | a3304b0 | 2012-03-28 11:04:24 +0200 | [diff] [blame] | 758 | __field(u16, ac) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 759 | __field(u16, txop) |
| 760 | __field(u16, cw_min) |
| 761 | __field(u16, cw_max) |
| 762 | __field(u8, aifs) |
Eliad Peller | f6f3def | 2011-09-25 20:06:54 +0300 | [diff] [blame] | 763 | __field(bool, uapsd) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 764 | ), |
| 765 | |
| 766 | TP_fast_assign( |
| 767 | LOCAL_ASSIGN; |
Eliad Peller | f6f3def | 2011-09-25 20:06:54 +0300 | [diff] [blame] | 768 | VIF_ASSIGN; |
Johannes Berg | a3304b0 | 2012-03-28 11:04:24 +0200 | [diff] [blame] | 769 | __entry->ac = ac; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 770 | __entry->txop = params->txop; |
| 771 | __entry->cw_max = params->cw_max; |
| 772 | __entry->cw_min = params->cw_min; |
| 773 | __entry->aifs = params->aifs; |
Eliad Peller | f6f3def | 2011-09-25 20:06:54 +0300 | [diff] [blame] | 774 | __entry->uapsd = params->uapsd; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 775 | ), |
| 776 | |
| 777 | TP_printk( |
Johannes Berg | a3304b0 | 2012-03-28 11:04:24 +0200 | [diff] [blame] | 778 | LOCAL_PR_FMT VIF_PR_FMT " AC:%d", |
| 779 | LOCAL_PR_ARG, VIF_PR_ARG, __entry->ac |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 780 | ) |
| 781 | ); |
| 782 | |
Eliad Peller | 37a41b4 | 2011-09-21 14:06:11 +0300 | [diff] [blame] | 783 | DEFINE_EVENT(local_sdata_evt, drv_get_tsf, |
| 784 | TP_PROTO(struct ieee80211_local *local, |
| 785 | struct ieee80211_sub_if_data *sdata), |
| 786 | TP_ARGS(local, sdata) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 787 | ); |
| 788 | |
| 789 | TRACE_EVENT(drv_set_tsf, |
Eliad Peller | 37a41b4 | 2011-09-21 14:06:11 +0300 | [diff] [blame] | 790 | TP_PROTO(struct ieee80211_local *local, |
| 791 | struct ieee80211_sub_if_data *sdata, |
| 792 | u64 tsf), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 793 | |
Eliad Peller | 37a41b4 | 2011-09-21 14:06:11 +0300 | [diff] [blame] | 794 | TP_ARGS(local, sdata, tsf), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 795 | |
| 796 | TP_STRUCT__entry( |
| 797 | LOCAL_ENTRY |
Eliad Peller | 37a41b4 | 2011-09-21 14:06:11 +0300 | [diff] [blame] | 798 | VIF_ENTRY |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 799 | __field(u64, tsf) |
| 800 | ), |
| 801 | |
| 802 | TP_fast_assign( |
| 803 | LOCAL_ASSIGN; |
Eliad Peller | 37a41b4 | 2011-09-21 14:06:11 +0300 | [diff] [blame] | 804 | VIF_ASSIGN; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 805 | __entry->tsf = tsf; |
| 806 | ), |
| 807 | |
| 808 | TP_printk( |
Eliad Peller | 37a41b4 | 2011-09-21 14:06:11 +0300 | [diff] [blame] | 809 | LOCAL_PR_FMT VIF_PR_FMT " tsf:%llu", |
| 810 | LOCAL_PR_ARG, VIF_PR_ARG, (unsigned long long)__entry->tsf |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 811 | ) |
| 812 | ); |
| 813 | |
Eliad Peller | 37a41b4 | 2011-09-21 14:06:11 +0300 | [diff] [blame] | 814 | DEFINE_EVENT(local_sdata_evt, drv_reset_tsf, |
| 815 | TP_PROTO(struct ieee80211_local *local, |
| 816 | struct ieee80211_sub_if_data *sdata), |
| 817 | TP_ARGS(local, sdata) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 818 | ); |
| 819 | |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 820 | DEFINE_EVENT(local_only_evt, drv_tx_last_beacon, |
Johannes Berg | 4efc76b | 2010-06-10 10:56:20 +0200 | [diff] [blame] | 821 | TP_PROTO(struct ieee80211_local *local), |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 822 | TP_ARGS(local) |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 823 | ); |
| 824 | |
| 825 | TRACE_EVENT(drv_ampdu_action, |
| 826 | TP_PROTO(struct ieee80211_local *local, |
Johannes Berg | 12375ef | 2009-11-25 20:30:31 +0100 | [diff] [blame] | 827 | struct ieee80211_sub_if_data *sdata, |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 828 | enum ieee80211_ampdu_mlme_action action, |
| 829 | struct ieee80211_sta *sta, u16 tid, |
Johannes Berg | 0b01f03 | 2011-01-18 13:51:05 +0100 | [diff] [blame] | 830 | u16 *ssn, u8 buf_size), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 831 | |
Johannes Berg | 0b01f03 | 2011-01-18 13:51:05 +0100 | [diff] [blame] | 832 | TP_ARGS(local, sdata, action, sta, tid, ssn, buf_size), |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 833 | |
| 834 | TP_STRUCT__entry( |
| 835 | LOCAL_ENTRY |
| 836 | STA_ENTRY |
| 837 | __field(u32, action) |
| 838 | __field(u16, tid) |
| 839 | __field(u16, ssn) |
Johannes Berg | 0b01f03 | 2011-01-18 13:51:05 +0100 | [diff] [blame] | 840 | __field(u8, buf_size) |
Johannes Berg | c951ad3 | 2009-11-16 12:00:38 +0100 | [diff] [blame] | 841 | VIF_ENTRY |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 842 | ), |
| 843 | |
| 844 | TP_fast_assign( |
| 845 | LOCAL_ASSIGN; |
Johannes Berg | c951ad3 | 2009-11-16 12:00:38 +0100 | [diff] [blame] | 846 | VIF_ASSIGN; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 847 | STA_ASSIGN; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 848 | __entry->action = action; |
| 849 | __entry->tid = tid; |
Zhu Yi | 3092ad0 | 2010-01-26 15:58:57 +0800 | [diff] [blame] | 850 | __entry->ssn = ssn ? *ssn : 0; |
Johannes Berg | 0b01f03 | 2011-01-18 13:51:05 +0100 | [diff] [blame] | 851 | __entry->buf_size = buf_size; |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 852 | ), |
| 853 | |
| 854 | TP_printk( |
Johannes Berg | 0b01f03 | 2011-01-18 13:51:05 +0100 | [diff] [blame] | 855 | LOCAL_PR_FMT VIF_PR_FMT STA_PR_FMT " action:%d tid:%d buf:%d", |
| 856 | LOCAL_PR_ARG, VIF_PR_ARG, STA_PR_ARG, __entry->action, |
| 857 | __entry->tid, __entry->buf_size |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 858 | ) |
| 859 | ); |
Johannes Berg | a80f7c0 | 2009-12-23 13:15:32 +0100 | [diff] [blame] | 860 | |
John W. Linville | c466d4e | 2010-06-29 14:51:23 -0400 | [diff] [blame] | 861 | TRACE_EVENT(drv_get_survey, |
| 862 | TP_PROTO(struct ieee80211_local *local, int idx, |
| 863 | struct survey_info *survey), |
| 864 | |
| 865 | TP_ARGS(local, idx, survey), |
| 866 | |
| 867 | TP_STRUCT__entry( |
| 868 | LOCAL_ENTRY |
| 869 | __field(int, idx) |
| 870 | ), |
| 871 | |
| 872 | TP_fast_assign( |
| 873 | LOCAL_ASSIGN; |
| 874 | __entry->idx = idx; |
| 875 | ), |
| 876 | |
| 877 | TP_printk( |
| 878 | LOCAL_PR_FMT " idx:%d", |
| 879 | LOCAL_PR_ARG, __entry->idx |
| 880 | ) |
| 881 | ); |
| 882 | |
Johannes Berg | a80f7c0 | 2009-12-23 13:15:32 +0100 | [diff] [blame] | 883 | TRACE_EVENT(drv_flush, |
| 884 | TP_PROTO(struct ieee80211_local *local, bool drop), |
| 885 | |
| 886 | TP_ARGS(local, drop), |
| 887 | |
| 888 | TP_STRUCT__entry( |
| 889 | LOCAL_ENTRY |
| 890 | __field(bool, drop) |
| 891 | ), |
| 892 | |
| 893 | TP_fast_assign( |
| 894 | LOCAL_ASSIGN; |
| 895 | __entry->drop = drop; |
| 896 | ), |
| 897 | |
| 898 | TP_printk( |
| 899 | LOCAL_PR_FMT " drop:%d", |
| 900 | LOCAL_PR_ARG, __entry->drop |
| 901 | ) |
| 902 | ); |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 903 | |
Johannes Berg | 5ce6e43 | 2010-05-11 16:20:57 +0200 | [diff] [blame] | 904 | TRACE_EVENT(drv_channel_switch, |
| 905 | TP_PROTO(struct ieee80211_local *local, |
| 906 | struct ieee80211_channel_switch *ch_switch), |
| 907 | |
| 908 | TP_ARGS(local, ch_switch), |
| 909 | |
| 910 | TP_STRUCT__entry( |
| 911 | LOCAL_ENTRY |
| 912 | __field(u64, timestamp) |
| 913 | __field(bool, block_tx) |
| 914 | __field(u16, freq) |
| 915 | __field(u8, count) |
| 916 | ), |
| 917 | |
| 918 | TP_fast_assign( |
| 919 | LOCAL_ASSIGN; |
| 920 | __entry->timestamp = ch_switch->timestamp; |
| 921 | __entry->block_tx = ch_switch->block_tx; |
| 922 | __entry->freq = ch_switch->channel->center_freq; |
| 923 | __entry->count = ch_switch->count; |
| 924 | ), |
| 925 | |
| 926 | TP_printk( |
| 927 | LOCAL_PR_FMT " new freq:%u count:%d", |
| 928 | LOCAL_PR_ARG, __entry->freq, __entry->count |
| 929 | ) |
| 930 | ); |
| 931 | |
Bruno Randolf | 15d9675 | 2010-11-10 12:50:56 +0900 | [diff] [blame] | 932 | TRACE_EVENT(drv_set_antenna, |
| 933 | TP_PROTO(struct ieee80211_local *local, u32 tx_ant, u32 rx_ant, int ret), |
| 934 | |
| 935 | TP_ARGS(local, tx_ant, rx_ant, ret), |
| 936 | |
| 937 | TP_STRUCT__entry( |
| 938 | LOCAL_ENTRY |
| 939 | __field(u32, tx_ant) |
| 940 | __field(u32, rx_ant) |
| 941 | __field(int, ret) |
| 942 | ), |
| 943 | |
| 944 | TP_fast_assign( |
| 945 | LOCAL_ASSIGN; |
| 946 | __entry->tx_ant = tx_ant; |
| 947 | __entry->rx_ant = rx_ant; |
| 948 | __entry->ret = ret; |
| 949 | ), |
| 950 | |
| 951 | TP_printk( |
| 952 | LOCAL_PR_FMT " tx_ant:%d rx_ant:%d ret:%d", |
| 953 | LOCAL_PR_ARG, __entry->tx_ant, __entry->rx_ant, __entry->ret |
| 954 | ) |
| 955 | ); |
| 956 | |
| 957 | TRACE_EVENT(drv_get_antenna, |
| 958 | TP_PROTO(struct ieee80211_local *local, u32 tx_ant, u32 rx_ant, int ret), |
| 959 | |
| 960 | TP_ARGS(local, tx_ant, rx_ant, ret), |
| 961 | |
| 962 | TP_STRUCT__entry( |
| 963 | LOCAL_ENTRY |
| 964 | __field(u32, tx_ant) |
| 965 | __field(u32, rx_ant) |
| 966 | __field(int, ret) |
| 967 | ), |
| 968 | |
| 969 | TP_fast_assign( |
| 970 | LOCAL_ASSIGN; |
| 971 | __entry->tx_ant = tx_ant; |
| 972 | __entry->rx_ant = rx_ant; |
| 973 | __entry->ret = ret; |
| 974 | ), |
| 975 | |
| 976 | TP_printk( |
| 977 | LOCAL_PR_FMT " tx_ant:%d rx_ant:%d ret:%d", |
| 978 | LOCAL_PR_ARG, __entry->tx_ant, __entry->rx_ant, __entry->ret |
| 979 | ) |
| 980 | ); |
| 981 | |
Johannes Berg | 21f8358 | 2010-12-18 17:20:47 +0100 | [diff] [blame] | 982 | TRACE_EVENT(drv_remain_on_channel, |
| 983 | TP_PROTO(struct ieee80211_local *local, struct ieee80211_channel *chan, |
| 984 | enum nl80211_channel_type chantype, unsigned int duration), |
| 985 | |
| 986 | TP_ARGS(local, chan, chantype, duration), |
| 987 | |
| 988 | TP_STRUCT__entry( |
| 989 | LOCAL_ENTRY |
| 990 | __field(int, center_freq) |
| 991 | __field(int, channel_type) |
| 992 | __field(unsigned int, duration) |
| 993 | ), |
| 994 | |
| 995 | TP_fast_assign( |
| 996 | LOCAL_ASSIGN; |
| 997 | __entry->center_freq = chan->center_freq; |
| 998 | __entry->channel_type = chantype; |
| 999 | __entry->duration = duration; |
| 1000 | ), |
| 1001 | |
| 1002 | TP_printk( |
| 1003 | LOCAL_PR_FMT " freq:%dMHz duration:%dms", |
| 1004 | LOCAL_PR_ARG, __entry->center_freq, __entry->duration |
| 1005 | ) |
| 1006 | ); |
| 1007 | |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 1008 | DEFINE_EVENT(local_only_evt, drv_cancel_remain_on_channel, |
Johannes Berg | 21f8358 | 2010-12-18 17:20:47 +0100 | [diff] [blame] | 1009 | TP_PROTO(struct ieee80211_local *local), |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 1010 | TP_ARGS(local) |
Johannes Berg | 21f8358 | 2010-12-18 17:20:47 +0100 | [diff] [blame] | 1011 | ); |
| 1012 | |
Johannes Berg | 5f16a43 | 2011-02-25 15:36:57 +0100 | [diff] [blame] | 1013 | TRACE_EVENT(drv_offchannel_tx, |
| 1014 | TP_PROTO(struct ieee80211_local *local, struct sk_buff *skb, |
| 1015 | struct ieee80211_channel *chan, |
| 1016 | enum nl80211_channel_type channel_type, |
| 1017 | unsigned int wait), |
| 1018 | |
| 1019 | TP_ARGS(local, skb, chan, channel_type, wait), |
| 1020 | |
| 1021 | TP_STRUCT__entry( |
| 1022 | LOCAL_ENTRY |
| 1023 | __field(int, center_freq) |
| 1024 | __field(int, channel_type) |
| 1025 | __field(unsigned int, wait) |
| 1026 | ), |
| 1027 | |
| 1028 | TP_fast_assign( |
| 1029 | LOCAL_ASSIGN; |
| 1030 | __entry->center_freq = chan->center_freq; |
| 1031 | __entry->channel_type = channel_type; |
| 1032 | __entry->wait = wait; |
| 1033 | ), |
| 1034 | |
| 1035 | TP_printk( |
| 1036 | LOCAL_PR_FMT " freq:%dMHz, wait:%dms", |
| 1037 | LOCAL_PR_ARG, __entry->center_freq, __entry->wait |
| 1038 | ) |
| 1039 | ); |
| 1040 | |
John W. Linville | 38c0915 | 2011-03-07 16:19:18 -0500 | [diff] [blame] | 1041 | TRACE_EVENT(drv_set_ringparam, |
| 1042 | TP_PROTO(struct ieee80211_local *local, u32 tx, u32 rx), |
| 1043 | |
| 1044 | TP_ARGS(local, tx, rx), |
| 1045 | |
| 1046 | TP_STRUCT__entry( |
| 1047 | LOCAL_ENTRY |
| 1048 | __field(u32, tx) |
| 1049 | __field(u32, rx) |
| 1050 | ), |
| 1051 | |
| 1052 | TP_fast_assign( |
| 1053 | LOCAL_ASSIGN; |
| 1054 | __entry->tx = tx; |
| 1055 | __entry->rx = rx; |
| 1056 | ), |
| 1057 | |
| 1058 | TP_printk( |
| 1059 | LOCAL_PR_FMT " tx:%d rx %d", |
| 1060 | LOCAL_PR_ARG, __entry->tx, __entry->rx |
| 1061 | ) |
| 1062 | ); |
| 1063 | |
| 1064 | TRACE_EVENT(drv_get_ringparam, |
| 1065 | TP_PROTO(struct ieee80211_local *local, u32 *tx, u32 *tx_max, |
| 1066 | u32 *rx, u32 *rx_max), |
| 1067 | |
| 1068 | TP_ARGS(local, tx, tx_max, rx, rx_max), |
| 1069 | |
| 1070 | TP_STRUCT__entry( |
| 1071 | LOCAL_ENTRY |
| 1072 | __field(u32, tx) |
| 1073 | __field(u32, tx_max) |
| 1074 | __field(u32, rx) |
| 1075 | __field(u32, rx_max) |
| 1076 | ), |
| 1077 | |
| 1078 | TP_fast_assign( |
| 1079 | LOCAL_ASSIGN; |
| 1080 | __entry->tx = *tx; |
| 1081 | __entry->tx_max = *tx_max; |
| 1082 | __entry->rx = *rx; |
| 1083 | __entry->rx_max = *rx_max; |
| 1084 | ), |
| 1085 | |
| 1086 | TP_printk( |
| 1087 | LOCAL_PR_FMT " tx:%d tx_max %d rx %d rx_max %d", |
| 1088 | LOCAL_PR_ARG, |
| 1089 | __entry->tx, __entry->tx_max, __entry->rx, __entry->rx_max |
| 1090 | ) |
| 1091 | ); |
| 1092 | |
Vivek Natarajan | e8306f9 | 2011-04-06 11:41:10 +0530 | [diff] [blame] | 1093 | DEFINE_EVENT(local_only_evt, drv_tx_frames_pending, |
| 1094 | TP_PROTO(struct ieee80211_local *local), |
| 1095 | TP_ARGS(local) |
| 1096 | ); |
| 1097 | |
Johannes Berg | 5f16a43 | 2011-02-25 15:36:57 +0100 | [diff] [blame] | 1098 | DEFINE_EVENT(local_only_evt, drv_offchannel_tx_cancel_wait, |
| 1099 | TP_PROTO(struct ieee80211_local *local), |
| 1100 | TP_ARGS(local) |
| 1101 | ); |
| 1102 | |
Sujith Manoharan | bdbfd6b | 2011-04-27 16:56:51 +0530 | [diff] [blame] | 1103 | TRACE_EVENT(drv_set_bitrate_mask, |
| 1104 | TP_PROTO(struct ieee80211_local *local, |
| 1105 | struct ieee80211_sub_if_data *sdata, |
| 1106 | const struct cfg80211_bitrate_mask *mask), |
| 1107 | |
| 1108 | TP_ARGS(local, sdata, mask), |
| 1109 | |
| 1110 | TP_STRUCT__entry( |
| 1111 | LOCAL_ENTRY |
| 1112 | VIF_ENTRY |
| 1113 | __field(u32, legacy_2g) |
| 1114 | __field(u32, legacy_5g) |
| 1115 | ), |
| 1116 | |
| 1117 | TP_fast_assign( |
| 1118 | LOCAL_ASSIGN; |
| 1119 | VIF_ASSIGN; |
| 1120 | __entry->legacy_2g = mask->control[IEEE80211_BAND_2GHZ].legacy; |
| 1121 | __entry->legacy_5g = mask->control[IEEE80211_BAND_5GHZ].legacy; |
| 1122 | ), |
| 1123 | |
| 1124 | TP_printk( |
| 1125 | LOCAL_PR_FMT VIF_PR_FMT " 2G Mask:0x%x 5G Mask:0x%x", |
| 1126 | LOCAL_PR_ARG, VIF_PR_ARG, __entry->legacy_2g, __entry->legacy_5g |
| 1127 | ) |
| 1128 | ); |
| 1129 | |
Johannes Berg | c68f4b8 | 2011-07-05 16:35:41 +0200 | [diff] [blame] | 1130 | TRACE_EVENT(drv_set_rekey_data, |
| 1131 | TP_PROTO(struct ieee80211_local *local, |
| 1132 | struct ieee80211_sub_if_data *sdata, |
| 1133 | struct cfg80211_gtk_rekey_data *data), |
| 1134 | |
| 1135 | TP_ARGS(local, sdata, data), |
| 1136 | |
| 1137 | TP_STRUCT__entry( |
| 1138 | LOCAL_ENTRY |
| 1139 | VIF_ENTRY |
| 1140 | __array(u8, kek, NL80211_KEK_LEN) |
| 1141 | __array(u8, kck, NL80211_KCK_LEN) |
| 1142 | __array(u8, replay_ctr, NL80211_REPLAY_CTR_LEN) |
| 1143 | ), |
| 1144 | |
| 1145 | TP_fast_assign( |
| 1146 | LOCAL_ASSIGN; |
| 1147 | VIF_ASSIGN; |
| 1148 | memcpy(__entry->kek, data->kek, NL80211_KEK_LEN); |
| 1149 | memcpy(__entry->kck, data->kck, NL80211_KCK_LEN); |
| 1150 | memcpy(__entry->replay_ctr, data->replay_ctr, |
| 1151 | NL80211_REPLAY_CTR_LEN); |
| 1152 | ), |
| 1153 | |
| 1154 | TP_printk(LOCAL_PR_FMT VIF_PR_FMT, |
| 1155 | LOCAL_PR_ARG, VIF_PR_ARG) |
| 1156 | ); |
| 1157 | |
Meenakshi Venkataraman | 615f7b9 | 2011-07-08 08:46:22 -0700 | [diff] [blame] | 1158 | TRACE_EVENT(drv_rssi_callback, |
| 1159 | TP_PROTO(struct ieee80211_local *local, |
| 1160 | enum ieee80211_rssi_event rssi_event), |
| 1161 | |
| 1162 | TP_ARGS(local, rssi_event), |
| 1163 | |
| 1164 | TP_STRUCT__entry( |
| 1165 | LOCAL_ENTRY |
| 1166 | __field(u32, rssi_event) |
| 1167 | ), |
| 1168 | |
| 1169 | TP_fast_assign( |
| 1170 | LOCAL_ASSIGN; |
| 1171 | __entry->rssi_event = rssi_event; |
| 1172 | ), |
| 1173 | |
| 1174 | TP_printk( |
| 1175 | LOCAL_PR_FMT " rssi_event:%d", |
| 1176 | LOCAL_PR_ARG, __entry->rssi_event |
| 1177 | ) |
| 1178 | ); |
| 1179 | |
Johannes Berg | 40b9640 | 2011-09-29 16:04:38 +0200 | [diff] [blame] | 1180 | DECLARE_EVENT_CLASS(release_evt, |
Johannes Berg | 4049e09 | 2011-09-29 16:04:32 +0200 | [diff] [blame] | 1181 | TP_PROTO(struct ieee80211_local *local, |
| 1182 | struct ieee80211_sta *sta, |
| 1183 | u16 tids, int num_frames, |
| 1184 | enum ieee80211_frame_release_type reason, |
| 1185 | bool more_data), |
| 1186 | |
| 1187 | TP_ARGS(local, sta, tids, num_frames, reason, more_data), |
| 1188 | |
| 1189 | TP_STRUCT__entry( |
| 1190 | LOCAL_ENTRY |
| 1191 | STA_ENTRY |
| 1192 | __field(u16, tids) |
| 1193 | __field(int, num_frames) |
| 1194 | __field(int, reason) |
| 1195 | __field(bool, more_data) |
| 1196 | ), |
| 1197 | |
| 1198 | TP_fast_assign( |
| 1199 | LOCAL_ASSIGN; |
| 1200 | STA_ASSIGN; |
| 1201 | __entry->tids = tids; |
| 1202 | __entry->num_frames = num_frames; |
| 1203 | __entry->reason = reason; |
| 1204 | __entry->more_data = more_data; |
| 1205 | ), |
| 1206 | |
| 1207 | TP_printk( |
| 1208 | LOCAL_PR_FMT STA_PR_FMT |
| 1209 | " TIDs:0x%.4x frames:%d reason:%d more:%d", |
| 1210 | LOCAL_PR_ARG, STA_PR_ARG, __entry->tids, __entry->num_frames, |
| 1211 | __entry->reason, __entry->more_data |
| 1212 | ) |
| 1213 | ); |
| 1214 | |
Johannes Berg | 40b9640 | 2011-09-29 16:04:38 +0200 | [diff] [blame] | 1215 | DEFINE_EVENT(release_evt, drv_release_buffered_frames, |
| 1216 | TP_PROTO(struct ieee80211_local *local, |
| 1217 | struct ieee80211_sta *sta, |
| 1218 | u16 tids, int num_frames, |
| 1219 | enum ieee80211_frame_release_type reason, |
| 1220 | bool more_data), |
| 1221 | |
| 1222 | TP_ARGS(local, sta, tids, num_frames, reason, more_data) |
| 1223 | ); |
| 1224 | |
| 1225 | DEFINE_EVENT(release_evt, drv_allow_buffered_frames, |
| 1226 | TP_PROTO(struct ieee80211_local *local, |
| 1227 | struct ieee80211_sta *sta, |
| 1228 | u16 tids, int num_frames, |
| 1229 | enum ieee80211_frame_release_type reason, |
| 1230 | bool more_data), |
| 1231 | |
| 1232 | TP_ARGS(local, sta, tids, num_frames, reason, more_data) |
| 1233 | ); |
| 1234 | |
Victor Goldenshtein | 66572cf | 2012-06-21 10:56:46 +0300 | [diff] [blame] | 1235 | TRACE_EVENT(drv_get_rssi, |
| 1236 | TP_PROTO(struct ieee80211_local *local, struct ieee80211_sta *sta, |
| 1237 | s8 rssi, int ret), |
| 1238 | |
| 1239 | TP_ARGS(local, sta, rssi, ret), |
| 1240 | |
| 1241 | TP_STRUCT__entry( |
| 1242 | LOCAL_ENTRY |
| 1243 | STA_ENTRY |
| 1244 | __field(s8, rssi) |
| 1245 | __field(int, ret) |
| 1246 | ), |
| 1247 | |
| 1248 | TP_fast_assign( |
| 1249 | LOCAL_ASSIGN; |
| 1250 | STA_ASSIGN; |
| 1251 | __entry->rssi = rssi; |
| 1252 | __entry->ret = ret; |
| 1253 | ), |
| 1254 | |
| 1255 | TP_printk( |
| 1256 | LOCAL_PR_FMT STA_PR_FMT " rssi:%d ret:%d", |
| 1257 | LOCAL_PR_ARG, STA_PR_ARG, __entry->rssi, __entry->ret |
| 1258 | ) |
| 1259 | ); |
| 1260 | |
Johannes Berg | a1845fc | 2012-06-27 13:18:36 +0200 | [diff] [blame] | 1261 | DEFINE_EVENT(local_sdata_evt, drv_mgd_prepare_tx, |
| 1262 | TP_PROTO(struct ieee80211_local *local, |
| 1263 | struct ieee80211_sub_if_data *sdata), |
| 1264 | |
| 1265 | TP_ARGS(local, sdata) |
| 1266 | ); |
| 1267 | |
Michal Kazior | c3645ea | 2012-06-26 14:37:17 +0200 | [diff] [blame^] | 1268 | DECLARE_EVENT_CLASS(local_chanctx, |
| 1269 | TP_PROTO(struct ieee80211_local *local, |
| 1270 | struct ieee80211_chanctx *ctx), |
| 1271 | |
| 1272 | TP_ARGS(local, ctx), |
| 1273 | |
| 1274 | TP_STRUCT__entry( |
| 1275 | LOCAL_ENTRY |
| 1276 | CHANCTX_ENTRY |
| 1277 | ), |
| 1278 | |
| 1279 | TP_fast_assign( |
| 1280 | LOCAL_ASSIGN; |
| 1281 | CHANCTX_ASSIGN; |
| 1282 | ), |
| 1283 | |
| 1284 | TP_printk( |
| 1285 | LOCAL_PR_FMT CHANCTX_PR_FMT, |
| 1286 | LOCAL_PR_ARG, CHANCTX_PR_ARG |
| 1287 | ) |
| 1288 | ); |
| 1289 | |
| 1290 | DEFINE_EVENT(local_chanctx, drv_add_chanctx, |
| 1291 | TP_PROTO(struct ieee80211_local *local, |
| 1292 | struct ieee80211_chanctx *ctx), |
| 1293 | TP_ARGS(local, ctx) |
| 1294 | ); |
| 1295 | |
| 1296 | DEFINE_EVENT(local_chanctx, drv_remove_chanctx, |
| 1297 | TP_PROTO(struct ieee80211_local *local, |
| 1298 | struct ieee80211_chanctx *ctx), |
| 1299 | TP_ARGS(local, ctx) |
| 1300 | ); |
| 1301 | |
| 1302 | TRACE_EVENT(drv_change_chanctx, |
| 1303 | TP_PROTO(struct ieee80211_local *local, |
| 1304 | struct ieee80211_chanctx *ctx, |
| 1305 | u32 changed), |
| 1306 | |
| 1307 | TP_ARGS(local, ctx, changed), |
| 1308 | |
| 1309 | TP_STRUCT__entry( |
| 1310 | LOCAL_ENTRY |
| 1311 | CHANCTX_ENTRY |
| 1312 | __field(u32, changed) |
| 1313 | ), |
| 1314 | |
| 1315 | TP_fast_assign( |
| 1316 | LOCAL_ASSIGN; |
| 1317 | CHANCTX_ASSIGN; |
| 1318 | __entry->changed = changed; |
| 1319 | ), |
| 1320 | |
| 1321 | TP_printk( |
| 1322 | LOCAL_PR_FMT CHANCTX_PR_FMT " changed:%#x", |
| 1323 | LOCAL_PR_ARG, CHANCTX_PR_ARG, __entry->changed |
| 1324 | ) |
| 1325 | ); |
| 1326 | |
| 1327 | DECLARE_EVENT_CLASS(local_sdata_chanctx, |
| 1328 | TP_PROTO(struct ieee80211_local *local, |
| 1329 | struct ieee80211_sub_if_data *sdata, |
| 1330 | struct ieee80211_chanctx *ctx), |
| 1331 | |
| 1332 | TP_ARGS(local, sdata, ctx), |
| 1333 | |
| 1334 | TP_STRUCT__entry( |
| 1335 | LOCAL_ENTRY |
| 1336 | VIF_ENTRY |
| 1337 | CHANCTX_ENTRY |
| 1338 | ), |
| 1339 | |
| 1340 | TP_fast_assign( |
| 1341 | LOCAL_ASSIGN; |
| 1342 | VIF_ASSIGN; |
| 1343 | CHANCTX_ASSIGN; |
| 1344 | ), |
| 1345 | |
| 1346 | TP_printk( |
| 1347 | LOCAL_PR_FMT VIF_PR_FMT CHANCTX_PR_FMT, |
| 1348 | LOCAL_PR_ARG, VIF_PR_ARG, CHANCTX_PR_ARG |
| 1349 | ) |
| 1350 | ); |
| 1351 | |
| 1352 | DEFINE_EVENT(local_sdata_chanctx, drv_assign_vif_chanctx, |
| 1353 | TP_PROTO(struct ieee80211_local *local, |
| 1354 | struct ieee80211_sub_if_data *sdata, |
| 1355 | struct ieee80211_chanctx *ctx), |
| 1356 | TP_ARGS(local, sdata, ctx) |
| 1357 | ); |
| 1358 | |
| 1359 | DEFINE_EVENT(local_sdata_chanctx, drv_unassign_vif_chanctx, |
| 1360 | TP_PROTO(struct ieee80211_local *local, |
| 1361 | struct ieee80211_sub_if_data *sdata, |
| 1362 | struct ieee80211_chanctx *ctx), |
| 1363 | TP_ARGS(local, sdata, ctx) |
| 1364 | ); |
| 1365 | |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 1366 | /* |
| 1367 | * Tracing for API calls that drivers call. |
| 1368 | */ |
| 1369 | |
| 1370 | TRACE_EVENT(api_start_tx_ba_session, |
| 1371 | TP_PROTO(struct ieee80211_sta *sta, u16 tid), |
| 1372 | |
| 1373 | TP_ARGS(sta, tid), |
| 1374 | |
| 1375 | TP_STRUCT__entry( |
| 1376 | STA_ENTRY |
| 1377 | __field(u16, tid) |
| 1378 | ), |
| 1379 | |
| 1380 | TP_fast_assign( |
| 1381 | STA_ASSIGN; |
| 1382 | __entry->tid = tid; |
| 1383 | ), |
| 1384 | |
| 1385 | TP_printk( |
| 1386 | STA_PR_FMT " tid:%d", |
| 1387 | STA_PR_ARG, __entry->tid |
| 1388 | ) |
| 1389 | ); |
| 1390 | |
| 1391 | TRACE_EVENT(api_start_tx_ba_cb, |
| 1392 | TP_PROTO(struct ieee80211_sub_if_data *sdata, const u8 *ra, u16 tid), |
| 1393 | |
| 1394 | TP_ARGS(sdata, ra, tid), |
| 1395 | |
| 1396 | TP_STRUCT__entry( |
| 1397 | VIF_ENTRY |
| 1398 | __array(u8, ra, ETH_ALEN) |
| 1399 | __field(u16, tid) |
| 1400 | ), |
| 1401 | |
| 1402 | TP_fast_assign( |
| 1403 | VIF_ASSIGN; |
| 1404 | memcpy(__entry->ra, ra, ETH_ALEN); |
| 1405 | __entry->tid = tid; |
| 1406 | ), |
| 1407 | |
| 1408 | TP_printk( |
| 1409 | VIF_PR_FMT " ra:%pM tid:%d", |
| 1410 | VIF_PR_ARG, __entry->ra, __entry->tid |
| 1411 | ) |
| 1412 | ); |
| 1413 | |
| 1414 | TRACE_EVENT(api_stop_tx_ba_session, |
Johannes Berg | 6a8579d | 2010-05-27 14:41:07 +0200 | [diff] [blame] | 1415 | TP_PROTO(struct ieee80211_sta *sta, u16 tid), |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 1416 | |
Johannes Berg | 6a8579d | 2010-05-27 14:41:07 +0200 | [diff] [blame] | 1417 | TP_ARGS(sta, tid), |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 1418 | |
| 1419 | TP_STRUCT__entry( |
| 1420 | STA_ENTRY |
| 1421 | __field(u16, tid) |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 1422 | ), |
| 1423 | |
| 1424 | TP_fast_assign( |
| 1425 | STA_ASSIGN; |
| 1426 | __entry->tid = tid; |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 1427 | ), |
| 1428 | |
| 1429 | TP_printk( |
Johannes Berg | 6a8579d | 2010-05-27 14:41:07 +0200 | [diff] [blame] | 1430 | STA_PR_FMT " tid:%d", |
| 1431 | STA_PR_ARG, __entry->tid |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 1432 | ) |
| 1433 | ); |
| 1434 | |
| 1435 | TRACE_EVENT(api_stop_tx_ba_cb, |
| 1436 | TP_PROTO(struct ieee80211_sub_if_data *sdata, const u8 *ra, u16 tid), |
| 1437 | |
| 1438 | TP_ARGS(sdata, ra, tid), |
| 1439 | |
| 1440 | TP_STRUCT__entry( |
| 1441 | VIF_ENTRY |
| 1442 | __array(u8, ra, ETH_ALEN) |
| 1443 | __field(u16, tid) |
| 1444 | ), |
| 1445 | |
| 1446 | TP_fast_assign( |
| 1447 | VIF_ASSIGN; |
| 1448 | memcpy(__entry->ra, ra, ETH_ALEN); |
| 1449 | __entry->tid = tid; |
| 1450 | ), |
| 1451 | |
| 1452 | TP_printk( |
| 1453 | VIF_PR_FMT " ra:%pM tid:%d", |
| 1454 | VIF_PR_ARG, __entry->ra, __entry->tid |
| 1455 | ) |
| 1456 | ); |
| 1457 | |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 1458 | DEFINE_EVENT(local_only_evt, api_restart_hw, |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 1459 | TP_PROTO(struct ieee80211_local *local), |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 1460 | TP_ARGS(local) |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 1461 | ); |
| 1462 | |
| 1463 | TRACE_EVENT(api_beacon_loss, |
| 1464 | TP_PROTO(struct ieee80211_sub_if_data *sdata), |
| 1465 | |
| 1466 | TP_ARGS(sdata), |
| 1467 | |
| 1468 | TP_STRUCT__entry( |
| 1469 | VIF_ENTRY |
| 1470 | ), |
| 1471 | |
| 1472 | TP_fast_assign( |
| 1473 | VIF_ASSIGN; |
| 1474 | ), |
| 1475 | |
| 1476 | TP_printk( |
| 1477 | VIF_PR_FMT, |
| 1478 | VIF_PR_ARG |
| 1479 | ) |
| 1480 | ); |
| 1481 | |
| 1482 | TRACE_EVENT(api_connection_loss, |
| 1483 | TP_PROTO(struct ieee80211_sub_if_data *sdata), |
| 1484 | |
| 1485 | TP_ARGS(sdata), |
| 1486 | |
| 1487 | TP_STRUCT__entry( |
| 1488 | VIF_ENTRY |
| 1489 | ), |
| 1490 | |
| 1491 | TP_fast_assign( |
| 1492 | VIF_ASSIGN; |
| 1493 | ), |
| 1494 | |
| 1495 | TP_printk( |
| 1496 | VIF_PR_FMT, |
| 1497 | VIF_PR_ARG |
| 1498 | ) |
| 1499 | ); |
| 1500 | |
| 1501 | TRACE_EVENT(api_cqm_rssi_notify, |
| 1502 | TP_PROTO(struct ieee80211_sub_if_data *sdata, |
| 1503 | enum nl80211_cqm_rssi_threshold_event rssi_event), |
| 1504 | |
| 1505 | TP_ARGS(sdata, rssi_event), |
| 1506 | |
| 1507 | TP_STRUCT__entry( |
| 1508 | VIF_ENTRY |
| 1509 | __field(u32, rssi_event) |
| 1510 | ), |
| 1511 | |
| 1512 | TP_fast_assign( |
| 1513 | VIF_ASSIGN; |
| 1514 | __entry->rssi_event = rssi_event; |
| 1515 | ), |
| 1516 | |
| 1517 | TP_printk( |
| 1518 | VIF_PR_FMT " event:%d", |
| 1519 | VIF_PR_ARG, __entry->rssi_event |
| 1520 | ) |
| 1521 | ); |
| 1522 | |
| 1523 | TRACE_EVENT(api_scan_completed, |
| 1524 | TP_PROTO(struct ieee80211_local *local, bool aborted), |
| 1525 | |
| 1526 | TP_ARGS(local, aborted), |
| 1527 | |
| 1528 | TP_STRUCT__entry( |
| 1529 | LOCAL_ENTRY |
| 1530 | __field(bool, aborted) |
| 1531 | ), |
| 1532 | |
| 1533 | TP_fast_assign( |
| 1534 | LOCAL_ASSIGN; |
| 1535 | __entry->aborted = aborted; |
| 1536 | ), |
| 1537 | |
| 1538 | TP_printk( |
| 1539 | LOCAL_PR_FMT " aborted:%d", |
| 1540 | LOCAL_PR_ARG, __entry->aborted |
| 1541 | ) |
| 1542 | ); |
| 1543 | |
Luciano Coelho | 79f460c | 2011-05-11 17:09:36 +0300 | [diff] [blame] | 1544 | TRACE_EVENT(api_sched_scan_results, |
| 1545 | TP_PROTO(struct ieee80211_local *local), |
| 1546 | |
| 1547 | TP_ARGS(local), |
| 1548 | |
| 1549 | TP_STRUCT__entry( |
| 1550 | LOCAL_ENTRY |
| 1551 | ), |
| 1552 | |
| 1553 | TP_fast_assign( |
| 1554 | LOCAL_ASSIGN; |
| 1555 | ), |
| 1556 | |
| 1557 | TP_printk( |
| 1558 | LOCAL_PR_FMT, LOCAL_PR_ARG |
| 1559 | ) |
| 1560 | ); |
| 1561 | |
| 1562 | TRACE_EVENT(api_sched_scan_stopped, |
| 1563 | TP_PROTO(struct ieee80211_local *local), |
| 1564 | |
| 1565 | TP_ARGS(local), |
| 1566 | |
| 1567 | TP_STRUCT__entry( |
| 1568 | LOCAL_ENTRY |
| 1569 | ), |
| 1570 | |
| 1571 | TP_fast_assign( |
| 1572 | LOCAL_ASSIGN; |
| 1573 | ), |
| 1574 | |
| 1575 | TP_printk( |
| 1576 | LOCAL_PR_FMT, LOCAL_PR_ARG |
| 1577 | ) |
| 1578 | ); |
| 1579 | |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 1580 | TRACE_EVENT(api_sta_block_awake, |
| 1581 | TP_PROTO(struct ieee80211_local *local, |
| 1582 | struct ieee80211_sta *sta, bool block), |
| 1583 | |
| 1584 | TP_ARGS(local, sta, block), |
| 1585 | |
| 1586 | TP_STRUCT__entry( |
| 1587 | LOCAL_ENTRY |
| 1588 | STA_ENTRY |
| 1589 | __field(bool, block) |
| 1590 | ), |
| 1591 | |
| 1592 | TP_fast_assign( |
| 1593 | LOCAL_ASSIGN; |
| 1594 | STA_ASSIGN; |
| 1595 | __entry->block = block; |
| 1596 | ), |
| 1597 | |
| 1598 | TP_printk( |
| 1599 | LOCAL_PR_FMT STA_PR_FMT " block:%d", |
| 1600 | LOCAL_PR_ARG, STA_PR_FMT, __entry->block |
| 1601 | ) |
| 1602 | ); |
| 1603 | |
Johannes Berg | 5ce6e43 | 2010-05-11 16:20:57 +0200 | [diff] [blame] | 1604 | TRACE_EVENT(api_chswitch_done, |
| 1605 | TP_PROTO(struct ieee80211_sub_if_data *sdata, bool success), |
| 1606 | |
| 1607 | TP_ARGS(sdata, success), |
| 1608 | |
| 1609 | TP_STRUCT__entry( |
| 1610 | VIF_ENTRY |
| 1611 | __field(bool, success) |
| 1612 | ), |
| 1613 | |
| 1614 | TP_fast_assign( |
| 1615 | VIF_ASSIGN; |
| 1616 | __entry->success = success; |
| 1617 | ), |
| 1618 | |
| 1619 | TP_printk( |
| 1620 | VIF_PR_FMT " success=%d", |
| 1621 | VIF_PR_ARG, __entry->success |
| 1622 | ) |
| 1623 | ); |
| 1624 | |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 1625 | DEFINE_EVENT(local_only_evt, api_ready_on_channel, |
Johannes Berg | 21f8358 | 2010-12-18 17:20:47 +0100 | [diff] [blame] | 1626 | TP_PROTO(struct ieee80211_local *local), |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 1627 | TP_ARGS(local) |
Johannes Berg | 21f8358 | 2010-12-18 17:20:47 +0100 | [diff] [blame] | 1628 | ); |
| 1629 | |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 1630 | DEFINE_EVENT(local_only_evt, api_remain_on_channel_expired, |
Johannes Berg | 21f8358 | 2010-12-18 17:20:47 +0100 | [diff] [blame] | 1631 | TP_PROTO(struct ieee80211_local *local), |
Johannes Berg | ba99d93 | 2011-01-26 09:22:15 +0100 | [diff] [blame] | 1632 | TP_ARGS(local) |
Johannes Berg | 21f8358 | 2010-12-18 17:20:47 +0100 | [diff] [blame] | 1633 | ); |
| 1634 | |
Johannes Berg | c68f4b8 | 2011-07-05 16:35:41 +0200 | [diff] [blame] | 1635 | TRACE_EVENT(api_gtk_rekey_notify, |
| 1636 | TP_PROTO(struct ieee80211_sub_if_data *sdata, |
| 1637 | const u8 *bssid, const u8 *replay_ctr), |
| 1638 | |
| 1639 | TP_ARGS(sdata, bssid, replay_ctr), |
| 1640 | |
| 1641 | TP_STRUCT__entry( |
| 1642 | VIF_ENTRY |
| 1643 | __array(u8, bssid, ETH_ALEN) |
| 1644 | __array(u8, replay_ctr, NL80211_REPLAY_CTR_LEN) |
| 1645 | ), |
| 1646 | |
| 1647 | TP_fast_assign( |
| 1648 | VIF_ASSIGN; |
| 1649 | memcpy(__entry->bssid, bssid, ETH_ALEN); |
| 1650 | memcpy(__entry->replay_ctr, replay_ctr, NL80211_REPLAY_CTR_LEN); |
| 1651 | ), |
| 1652 | |
| 1653 | TP_printk(VIF_PR_FMT, VIF_PR_ARG) |
| 1654 | ); |
| 1655 | |
Meenakshi Venkataraman | 615f7b9 | 2011-07-08 08:46:22 -0700 | [diff] [blame] | 1656 | TRACE_EVENT(api_enable_rssi_reports, |
| 1657 | TP_PROTO(struct ieee80211_sub_if_data *sdata, |
| 1658 | int rssi_min_thold, int rssi_max_thold), |
| 1659 | |
| 1660 | TP_ARGS(sdata, rssi_min_thold, rssi_max_thold), |
| 1661 | |
| 1662 | TP_STRUCT__entry( |
| 1663 | VIF_ENTRY |
| 1664 | __field(int, rssi_min_thold) |
| 1665 | __field(int, rssi_max_thold) |
| 1666 | ), |
| 1667 | |
| 1668 | TP_fast_assign( |
| 1669 | VIF_ASSIGN; |
| 1670 | __entry->rssi_min_thold = rssi_min_thold; |
| 1671 | __entry->rssi_max_thold = rssi_max_thold; |
| 1672 | ), |
| 1673 | |
| 1674 | TP_printk( |
| 1675 | VIF_PR_FMT " rssi_min_thold =%d, rssi_max_thold = %d", |
| 1676 | VIF_PR_ARG, __entry->rssi_min_thold, __entry->rssi_max_thold |
| 1677 | ) |
| 1678 | ); |
| 1679 | |
Johannes Berg | 37fbd90 | 2011-09-29 16:04:39 +0200 | [diff] [blame] | 1680 | TRACE_EVENT(api_eosp, |
| 1681 | TP_PROTO(struct ieee80211_local *local, |
| 1682 | struct ieee80211_sta *sta), |
| 1683 | |
| 1684 | TP_ARGS(local, sta), |
| 1685 | |
| 1686 | TP_STRUCT__entry( |
| 1687 | LOCAL_ENTRY |
| 1688 | STA_ENTRY |
| 1689 | ), |
| 1690 | |
| 1691 | TP_fast_assign( |
| 1692 | LOCAL_ASSIGN; |
| 1693 | STA_ASSIGN; |
| 1694 | ), |
| 1695 | |
| 1696 | TP_printk( |
| 1697 | LOCAL_PR_FMT STA_PR_FMT, |
| 1698 | LOCAL_PR_ARG, STA_PR_FMT |
| 1699 | ) |
| 1700 | ); |
| 1701 | |
Johannes Berg | b5878a2 | 2010-04-07 16:48:40 +0200 | [diff] [blame] | 1702 | /* |
| 1703 | * Tracing for internal functions |
| 1704 | * (which may also be called in response to driver calls) |
| 1705 | */ |
| 1706 | |
| 1707 | TRACE_EVENT(wake_queue, |
| 1708 | TP_PROTO(struct ieee80211_local *local, u16 queue, |
| 1709 | enum queue_stop_reason reason), |
| 1710 | |
| 1711 | TP_ARGS(local, queue, reason), |
| 1712 | |
| 1713 | TP_STRUCT__entry( |
| 1714 | LOCAL_ENTRY |
| 1715 | __field(u16, queue) |
| 1716 | __field(u32, reason) |
| 1717 | ), |
| 1718 | |
| 1719 | TP_fast_assign( |
| 1720 | LOCAL_ASSIGN; |
| 1721 | __entry->queue = queue; |
| 1722 | __entry->reason = reason; |
| 1723 | ), |
| 1724 | |
| 1725 | TP_printk( |
| 1726 | LOCAL_PR_FMT " queue:%d, reason:%d", |
| 1727 | LOCAL_PR_ARG, __entry->queue, __entry->reason |
| 1728 | ) |
| 1729 | ); |
| 1730 | |
| 1731 | TRACE_EVENT(stop_queue, |
| 1732 | TP_PROTO(struct ieee80211_local *local, u16 queue, |
| 1733 | enum queue_stop_reason reason), |
| 1734 | |
| 1735 | TP_ARGS(local, queue, reason), |
| 1736 | |
| 1737 | TP_STRUCT__entry( |
| 1738 | LOCAL_ENTRY |
| 1739 | __field(u16, queue) |
| 1740 | __field(u32, reason) |
| 1741 | ), |
| 1742 | |
| 1743 | TP_fast_assign( |
| 1744 | LOCAL_ASSIGN; |
| 1745 | __entry->queue = queue; |
| 1746 | __entry->reason = reason; |
| 1747 | ), |
| 1748 | |
| 1749 | TP_printk( |
| 1750 | LOCAL_PR_FMT " queue:%d, reason:%d", |
| 1751 | LOCAL_PR_ARG, __entry->queue, __entry->reason |
| 1752 | ) |
| 1753 | ); |
Johannes Berg | 3fae027 | 2012-06-22 13:36:25 +0200 | [diff] [blame] | 1754 | |
| 1755 | #ifdef CONFIG_MAC80211_MESSAGE_TRACING |
| 1756 | #undef TRACE_SYSTEM |
| 1757 | #define TRACE_SYSTEM mac80211_msg |
| 1758 | |
| 1759 | #define MAX_MSG_LEN 100 |
| 1760 | |
| 1761 | DECLARE_EVENT_CLASS(mac80211_msg_event, |
| 1762 | TP_PROTO(struct va_format *vaf), |
| 1763 | |
| 1764 | TP_ARGS(vaf), |
| 1765 | |
| 1766 | TP_STRUCT__entry( |
| 1767 | __dynamic_array(char, msg, MAX_MSG_LEN) |
| 1768 | ), |
| 1769 | |
| 1770 | TP_fast_assign( |
| 1771 | WARN_ON_ONCE(vsnprintf(__get_dynamic_array(msg), |
| 1772 | MAX_MSG_LEN, vaf->fmt, |
| 1773 | *vaf->va) >= MAX_MSG_LEN); |
| 1774 | ), |
| 1775 | |
| 1776 | TP_printk("%s", __get_str(msg)) |
| 1777 | ); |
| 1778 | |
| 1779 | DEFINE_EVENT(mac80211_msg_event, mac80211_info, |
| 1780 | TP_PROTO(struct va_format *vaf), |
| 1781 | TP_ARGS(vaf) |
| 1782 | ); |
| 1783 | DEFINE_EVENT(mac80211_msg_event, mac80211_dbg, |
| 1784 | TP_PROTO(struct va_format *vaf), |
| 1785 | TP_ARGS(vaf) |
| 1786 | ); |
| 1787 | DEFINE_EVENT(mac80211_msg_event, mac80211_err, |
| 1788 | TP_PROTO(struct va_format *vaf), |
| 1789 | TP_ARGS(vaf) |
| 1790 | ); |
| 1791 | #endif |
| 1792 | |
Christian Lamparter | f742880 | 2009-07-19 23:21:07 +0200 | [diff] [blame] | 1793 | #endif /* !__MAC80211_DRIVER_TRACE || TRACE_HEADER_MULTI_READ */ |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 1794 | |
| 1795 | #undef TRACE_INCLUDE_PATH |
| 1796 | #define TRACE_INCLUDE_PATH . |
| 1797 | #undef TRACE_INCLUDE_FILE |
Johannes Berg | 011ad0e | 2012-06-22 12:55:52 +0200 | [diff] [blame] | 1798 | #define TRACE_INCLUDE_FILE trace |
Johannes Berg | 0a2b8bb | 2009-07-07 13:46:22 +0200 | [diff] [blame] | 1799 | #include <trace/define_trace.h> |