binder.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /*
  2. * binder interface for wpa_supplicant daemon
  3. * Copyright (c) 2004-2016, Jouni Malinen <j@w1.fi>
  4. * Copyright (c) 2004-2016, Roshan Pius <rpius@google.com>
  5. *
  6. * This software may be distributed under the terms of the BSD license.
  7. * See README for more details.
  8. */
  9. #ifndef WPA_SUPPLICANT_BINDER_BINDER_H
  10. #define WPA_SUPPLICANT_BINDER_BINDER_H
  11. #ifdef _cplusplus
  12. extern "C" {
  13. #endif /* _cplusplus */
  14. /**
  15. * This is the binder RPC interface entry point to the wpa_supplicant core.
  16. * This initializes the binder driver & BinderManager instance and then forwards
  17. * all the notifcations from the supplicant core to the BinderManager.
  18. */
  19. struct wpas_binder_priv;
  20. struct wpa_global;
  21. struct wpas_binder_priv *wpas_binder_init(struct wpa_global *global);
  22. void wpas_binder_deinit(struct wpas_binder_priv *priv);
  23. #ifdef CONFIG_CTRL_IFACE_BINDER
  24. int wpas_binder_register_interface(struct wpa_supplicant *wpa_s);
  25. int wpas_binder_unregister_interface(struct wpa_supplicant *wpa_s);
  26. #else /* CONFIG_CTRL_IFACE_BINDER */
  27. static inline int wpas_binder_register_interface(struct wpa_supplicant *wpa_s)
  28. {
  29. return 0;
  30. }
  31. static inline int wpas_binder_unregister_interface(struct wpa_supplicant *wpa_s)
  32. {
  33. return 0;
  34. }
  35. #endif /* CONFIG_CTRL_IFACE_BINDER */
  36. #ifdef _cplusplus
  37. }
  38. #endif /* _cplusplus */
  39. #endif /* WPA_SUPPLICANT_BINDER_BINDER_H */