Lines Matching defs:crypto
478 static void memcpy_tkip(struct rt2x00lib_crypto *crypto, u8 *key, u8 key_len)
481 memcpy(&crypto->key,
483 sizeof(crypto->key));
486 memcpy(&crypto->tx_mic,
488 sizeof(crypto->tx_mic));
491 memcpy(&crypto->rx_mic,
493 sizeof(crypto->rx_mic));
503 struct rt2x00lib_crypto *crypto,
505 struct rt2x00lib_crypto crypto;
516 memset(&crypto, 0, sizeof(crypto));
523 crypto.bssidx = 0;
525 crypto.bssidx = intf->mac[5] & (rt2x00dev->ops->max_ap_intf - 1);
527 crypto.cipher = rt2x00crypto_key_to_cipher(key);
528 if (crypto.cipher == CIPHER_NONE)
531 crypto.cmd = cmd;
535 crypto.aid = sta->aid;
536 crypto.address = sta->addr;
538 crypto.address = bcast_addr;
540 if (crypto.cipher == CIPHER_TKIP)
541 memcpy_tkip(&crypto, &key->key[0], key->keylen);
543 memcpy(&crypto.key, &key->key[0], key->keylen);
571 return set_key(rt2x00dev, &crypto, key);