Lines Matching refs:key

23 	struct ieee80211_key *key = file->private_data;			\
25 format_string, key->prop); \
69 struct ieee80211_key *key = file->private_data; in key_algorithm_read() local
70 u32 c = key->conf.cipher; in key_algorithm_read()
84 struct ieee80211_key *key = file->private_data; in key_tx_spec_read() local
86 switch (key->conf.cipher) { in key_tx_spec_read()
93 key->u.tkip.tx.iv32, in key_tx_spec_read()
94 key->u.tkip.tx.iv16); in key_tx_spec_read()
98 pn = atomic64_read(&key->u.ccmp.tx_pn); in key_tx_spec_read()
105 pn = atomic64_read(&key->u.aes_cmac.tx_pn); in key_tx_spec_read()
112 pn = atomic64_read(&key->u.aes_gmac.tx_pn); in key_tx_spec_read()
119 pn = atomic64_read(&key->u.gcmp.tx_pn); in key_tx_spec_read()
134 struct ieee80211_key *key = file->private_data; in key_rx_spec_read() local
139 switch (key->conf.cipher) { in key_rx_spec_read()
148 key->u.tkip.rx[i].iv32, in key_rx_spec_read()
149 key->u.tkip.rx[i].iv16); in key_rx_spec_read()
155 rpn = key->u.ccmp.rx_pn[i]; in key_rx_spec_read()
165 rpn = key->u.aes_cmac.rx_pn; in key_rx_spec_read()
174 rpn = key->u.aes_gmac.rx_pn; in key_rx_spec_read()
184 rpn = key->u.gcmp.rx_pn[i]; in key_rx_spec_read()
202 struct ieee80211_key *key = file->private_data; in key_replays_read() local
206 switch (key->conf.cipher) { in key_replays_read()
209 len = scnprintf(buf, sizeof(buf), "%u\n", key->u.ccmp.replays); in key_replays_read()
214 key->u.aes_cmac.replays); in key_replays_read()
219 key->u.aes_gmac.replays); in key_replays_read()
223 len = scnprintf(buf, sizeof(buf), "%u\n", key->u.gcmp.replays); in key_replays_read()
235 struct ieee80211_key *key = file->private_data; in key_icverrors_read() local
239 switch (key->conf.cipher) { in key_icverrors_read()
243 key->u.aes_cmac.icverrors); in key_icverrors_read()
248 key->u.aes_gmac.icverrors); in key_icverrors_read()
260 struct ieee80211_key *key = file->private_data; in key_mic_failures_read() local
264 if (key->conf.cipher != WLAN_CIPHER_SUITE_TKIP) in key_mic_failures_read()
267 len = scnprintf(buf, sizeof(buf), "%u\n", key->u.tkip.mic_failures); in key_mic_failures_read()
276 struct ieee80211_key *key = file->private_data; in key_key_read() local
277 int i, bufsize = 2 * key->conf.keylen + 2; in key_key_read()
285 for (i = 0; i < key->conf.keylen; i++) in key_key_read()
286 p += scnprintf(p, bufsize + buf - p, "%02x", key->conf.key[i]); in key_key_read()
292 KEY_OPS(key);
295 debugfs_create_file(#name, 0400, key->debugfs.dir, \
296 key, &key_##name##_ops);
298 void ieee80211_debugfs_key_add(struct ieee80211_key *key) in ieee80211_debugfs_key_add() argument
304 if (!key->local->debugfs.keys) in ieee80211_debugfs_key_add()
308 key->debugfs.cnt = keycount; in ieee80211_debugfs_key_add()
310 key->debugfs.dir = debugfs_create_dir(buf, in ieee80211_debugfs_key_add()
311 key->local->debugfs.keys); in ieee80211_debugfs_key_add()
313 if (!key->debugfs.dir) in ieee80211_debugfs_key_add()
316 sta = key->sta; in ieee80211_debugfs_key_add()
320 key->debugfs.stalink = in ieee80211_debugfs_key_add()
321 debugfs_create_symlink("station", key->debugfs.dir, buf); in ieee80211_debugfs_key_add()
335 DEBUGFS_ADD(key); in ieee80211_debugfs_key_add()
339 void ieee80211_debugfs_key_remove(struct ieee80211_key *key) in ieee80211_debugfs_key_remove() argument
341 if (!key) in ieee80211_debugfs_key_remove()
344 debugfs_remove_recursive(key->debugfs.dir); in ieee80211_debugfs_key_remove()
345 key->debugfs.dir = NULL; in ieee80211_debugfs_key_remove()
351 struct ieee80211_key *key; in ieee80211_debugfs_key_update_default() local
362 key = key_mtx_dereference(sdata->local, in ieee80211_debugfs_key_update_default()
364 sprintf(buf, "../keys/%d", key->debugfs.cnt); in ieee80211_debugfs_key_update_default()
374 key = key_mtx_dereference(sdata->local, in ieee80211_debugfs_key_update_default()
376 sprintf(buf, "../keys/%d", key->debugfs.cnt); in ieee80211_debugfs_key_update_default()
386 struct ieee80211_key *key; in ieee80211_debugfs_key_add_mgmt_default() local
391 key = key_mtx_dereference(sdata->local, in ieee80211_debugfs_key_add_mgmt_default()
393 if (key) { in ieee80211_debugfs_key_add_mgmt_default()
394 sprintf(buf, "../keys/%d", key->debugfs.cnt); in ieee80211_debugfs_key_add_mgmt_default()
411 void ieee80211_debugfs_key_sta_del(struct ieee80211_key *key, in ieee80211_debugfs_key_sta_del() argument
414 debugfs_remove(key->debugfs.stalink); in ieee80211_debugfs_key_sta_del()
415 key->debugfs.stalink = NULL; in ieee80211_debugfs_key_sta_del()