[RFC 26/40] wpas: add notification functions for STA authorized

Jouni Malinen j
Thu Feb 24 12:43:26 PST 2011

On Wed, Jan 05, 2011 at 08:53:22PM +0100, Johannes Berg wrote:
> diff --git a/wpa_supplicant/notify.c b/wpa_supplicant/notify.c

> +void wpas_notify_sta_authorized(struct wpa_supplicant *wpa_s,
> +				const u8 *mac_addr, int authorized)
> +{
> +#ifdef CONFIG_P2P
> +	if (authorized)
> +		wpas_notify_p2p_peer_joined(wpa_s, mac_addr);
> +	else
> +		wpas_notify_p2p_peer_disconnected(wpa_s, mac_addr);
> +#endif

Adding sta_authorized notification itself is fine, but that #ifdef
CONFIG_P2P is not going to make this in any way mean that the
p2p_peer_{joined,disconnected} notifications were really specific to
P2P. Is there any particular reason to try to make this apply for P2P GO
case only or would it be fine to rename these to
station_{connected,disconnected} for any AP use?
Jouni Malinen                                            PGP id EFC895FA

More information about the Hostap mailing list