wlan_pdev_mlme.h 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. /*
  2. * Copyright (c) 2019-2020 The Linux Foundation. All rights reserved.
  3. *
  4. * Permission to use, copy, modify, and/or distribute this software for any
  5. * purpose with or without fee is hereby granted, provided that the above
  6. * copyright notice and this permission notice appear in all copies.
  7. *
  8. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  9. * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
  10. * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
  11. * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  12. * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
  13. * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  14. * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  15. */
  16. /**
  17. * DOC: Define PDEV MLME structure and APIs
  18. */
  19. #ifndef _WLAN_PDEV_MLME_H_
  20. #define _WLAN_PDEV_MLME_H_
  21. #include <qdf_timer.h>
  22. #include <include/wlan_vdev_mlme.h>
  23. #include <wlan_ext_mlme_obj_types.h>
  24. /*
  25. * struct pdev_restart_attr - Pdev restart attributes
  26. * @vdev: vdev on which the pdev restart cmd was enqueued
  27. * @restart_bmap: Bitmap for vdev requesting multivdev restart
  28. */
  29. struct pdev_restart_attr {
  30. struct wlan_objmgr_vdev *vdev;
  31. unsigned long restart_bmap[2];
  32. };
  33. /**
  34. * struct pdev_mlme_obj - PDEV MLME component object
  35. * @pdev: PDEV object
  36. * @ext_pdev_ptr: PDEV MLME legacy pointer
  37. * @mlme_register_ops: Call back to register MLME legacy APIs
  38. * @vdev_restart_lock: Lock for VDEVs restart
  39. * @restart_req_timer: Timer handle for VDEVs restart
  40. * @restart_pend_vdev_bmap: Bitmap for VDEV RESTART command pending
  41. * @restart_send_vdev_bmap: Bitmap for VDEV RESTART command sending
  42. * @start_send_vdev_arr: Bitmap for VDEV START command sending
  43. */
  44. struct pdev_mlme_obj {
  45. struct wlan_objmgr_pdev *pdev;
  46. mlme_pdev_ext_t *ext_pdev_ptr;
  47. QDF_STATUS (*mlme_register_ops)(struct vdev_mlme_obj *vdev_mlme);
  48. qdf_spinlock_t vdev_restart_lock;
  49. qdf_timer_t restart_req_timer;
  50. unsigned long restart_pend_vdev_bmap[2];
  51. unsigned long restart_send_vdev_bmap[2];
  52. unsigned long start_send_vdev_arr[2];
  53. struct pdev_restart_attr pdev_restart;
  54. qdf_atomic_t multivdev_restart_wait_cnt;
  55. };
  56. #endif