xref: /aosp_15_r20/external/wpa_supplicant_8/src/ap/accounting.h (revision 03f9172ca588f91df233974f4258bab95191f931)
1*03f9172cSAndroid Build Coastguard Worker /*
2*03f9172cSAndroid Build Coastguard Worker  * hostapd / RADIUS Accounting
3*03f9172cSAndroid Build Coastguard Worker  * Copyright (c) 2002-2005, Jouni Malinen <[email protected]>
4*03f9172cSAndroid Build Coastguard Worker  *
5*03f9172cSAndroid Build Coastguard Worker  * This software may be distributed under the terms of the BSD license.
6*03f9172cSAndroid Build Coastguard Worker  * See README for more details.
7*03f9172cSAndroid Build Coastguard Worker  */
8*03f9172cSAndroid Build Coastguard Worker 
9*03f9172cSAndroid Build Coastguard Worker #ifndef ACCOUNTING_H
10*03f9172cSAndroid Build Coastguard Worker #define ACCOUNTING_H
11*03f9172cSAndroid Build Coastguard Worker 
12*03f9172cSAndroid Build Coastguard Worker #ifdef CONFIG_NO_ACCOUNTING
accounting_sta_get_id(struct hostapd_data * hapd,struct sta_info * sta)13*03f9172cSAndroid Build Coastguard Worker static inline int accounting_sta_get_id(struct hostapd_data *hapd,
14*03f9172cSAndroid Build Coastguard Worker 					struct sta_info *sta)
15*03f9172cSAndroid Build Coastguard Worker {
16*03f9172cSAndroid Build Coastguard Worker 	return 0;
17*03f9172cSAndroid Build Coastguard Worker }
18*03f9172cSAndroid Build Coastguard Worker 
accounting_sta_start(struct hostapd_data * hapd,struct sta_info * sta)19*03f9172cSAndroid Build Coastguard Worker static inline void accounting_sta_start(struct hostapd_data *hapd,
20*03f9172cSAndroid Build Coastguard Worker 					struct sta_info *sta)
21*03f9172cSAndroid Build Coastguard Worker {
22*03f9172cSAndroid Build Coastguard Worker }
23*03f9172cSAndroid Build Coastguard Worker 
accounting_sta_stop(struct hostapd_data * hapd,struct sta_info * sta)24*03f9172cSAndroid Build Coastguard Worker static inline void accounting_sta_stop(struct hostapd_data *hapd,
25*03f9172cSAndroid Build Coastguard Worker 				       struct sta_info *sta)
26*03f9172cSAndroid Build Coastguard Worker {
27*03f9172cSAndroid Build Coastguard Worker }
28*03f9172cSAndroid Build Coastguard Worker 
accounting_init(struct hostapd_data * hapd)29*03f9172cSAndroid Build Coastguard Worker static inline int accounting_init(struct hostapd_data *hapd)
30*03f9172cSAndroid Build Coastguard Worker {
31*03f9172cSAndroid Build Coastguard Worker 	return 0;
32*03f9172cSAndroid Build Coastguard Worker }
33*03f9172cSAndroid Build Coastguard Worker 
accounting_deinit(struct hostapd_data * hapd)34*03f9172cSAndroid Build Coastguard Worker static inline void accounting_deinit(struct hostapd_data *hapd)
35*03f9172cSAndroid Build Coastguard Worker {
36*03f9172cSAndroid Build Coastguard Worker }
37*03f9172cSAndroid Build Coastguard Worker #else /* CONFIG_NO_ACCOUNTING */
38*03f9172cSAndroid Build Coastguard Worker int accounting_sta_get_id(struct hostapd_data *hapd, struct sta_info *sta);
39*03f9172cSAndroid Build Coastguard Worker void accounting_sta_start(struct hostapd_data *hapd, struct sta_info *sta);
40*03f9172cSAndroid Build Coastguard Worker void accounting_sta_stop(struct hostapd_data *hapd, struct sta_info *sta);
41*03f9172cSAndroid Build Coastguard Worker int accounting_init(struct hostapd_data *hapd);
42*03f9172cSAndroid Build Coastguard Worker void accounting_deinit(struct hostapd_data *hapd);
43*03f9172cSAndroid Build Coastguard Worker #endif /* CONFIG_NO_ACCOUNTING */
44*03f9172cSAndroid Build Coastguard Worker 
45*03f9172cSAndroid Build Coastguard Worker #endif /* ACCOUNTING_H */
46