aboutsummaryrefslogtreecommitdiffstats
path: root/src/drivers/driver_atheros.c
diff options
context:
space:
mode:
authorJouni Malinen <jouni@codeaurora.org>2020-01-08 20:15:18 (GMT)
committerJouni Malinen <j@w1.fi>2020-01-08 22:48:57 (GMT)
commitf82254645170fa02bb59c4fbc996dba6c173adca (patch)
tree194262adbf0e7ca606a81e6a22a092b36ba45815 /src/drivers/driver_atheros.c
parent283be365c346d1e353e0ed182fcdf978b0ba9ac5 (diff)
downloadhostap-f82254645170fa02bb59c4fbc996dba6c173adca.zip
hostap-f82254645170fa02bb59c4fbc996dba6c173adca.tar.gz
hostap-f82254645170fa02bb59c4fbc996dba6c173adca.tar.bz2
driver: Move set_key() parameters into a struct
This makes it more convenient to add, remove, and modify the parameters without always having to update every single driver_*.c implementation of this callback function. Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
Diffstat (limited to 'src/drivers/driver_atheros.c')
-rw-r--r--src/drivers/driver_atheros.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/drivers/driver_atheros.c b/src/drivers/driver_atheros.c
index de25e4e..2014f9d 100644
--- a/src/drivers/driver_atheros.c
+++ b/src/drivers/driver_atheros.c
@@ -492,14 +492,18 @@ atheros_del_key(void *priv, const u8 *addr, int key_idx)
}
static int
-atheros_set_key(const char *ifname, void *priv, enum wpa_alg alg,
- const u8 *addr, int key_idx, int set_tx, const u8 *seq,
- size_t seq_len, const u8 *key, size_t key_len)
+atheros_set_key(void *priv, struct wpa_driver_set_key_params *params)
{
struct atheros_driver_data *drv = priv;
struct ieee80211req_key wk;
u_int8_t cipher;
int ret;
+ enum wpa_alg alg = params->alg;
+ const u8 *addr = params->addr;
+ int key_idx = params->key_idx;
+ int set_tx = params->set_tx;
+ const u8 *key = params->key;
+ size_t key_len = params->key_len;
if (alg == WPA_ALG_NONE)
return atheros_del_key(drv, addr, key_idx);