From 7474ff09754e4041614116e4d23628736150d016 Mon Sep 17 00:00:00 2001 From: James Prestwood Date: Tue, 28 Sep 2021 08:46:52 -0700 Subject: [PATCH] auth-proto: add auth_proto_rx_oci This allows auth protos to get notified when the chandef has been set. Since netdev sets chandef already there is no arguments. --- src/auth-proto.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/auth-proto.h b/src/auth-proto.h index 33a74291..9f8da604 100644 --- a/src/auth-proto.h +++ b/src/auth-proto.h @@ -44,6 +44,7 @@ struct auth_proto { const uint8_t *frame, size_t len); int (*rx_associate)(struct auth_proto *driver, const uint8_t *frame, size_t len); + int (*rx_oci)(struct auth_proto *driver); bool (*auth_timeout)(struct auth_proto *ap); bool (*assoc_timeout)(struct auth_proto *ap); uint8_t prev_bssid[6]; @@ -98,3 +99,11 @@ static inline bool auth_proto_assoc_timeout(struct auth_proto *ap) return false; } + +static inline int auth_proto_rx_oci(struct auth_proto *ap) +{ + if (ap && ap->rx_oci) + return ap->rx_oci(ap); + + return -ENOTSUP; +}