tcl_gse_cmd.h 9.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215
  1. /*
  2. * Copyright (c) 2024, Qualcomm Innovation Center, Inc. All rights reserved.
  3. * SPDX-License-Identifier: ISC
  4. */
  5. #ifndef _TCL_GSE_CMD_H_
  6. #define _TCL_GSE_CMD_H_
  7. #if !defined(__ASSEMBLER__)
  8. #endif
  9. #define NUM_OF_DWORDS_TCL_GSE_CMD 8
  10. struct tcl_gse_cmd {
  11. #ifndef WIFI_BIT_ORDER_BIG_ENDIAN
  12. uint32_t control_buffer_addr_31_0 : 32;
  13. uint32_t control_buffer_addr_39_32 : 8,
  14. gse_ctrl : 4,
  15. gse_sel : 1,
  16. status_destination_ring_id : 1,
  17. swap : 1,
  18. index_search_en : 1,
  19. cache_set_num : 4,
  20. reserved_1a : 12;
  21. uint32_t tcl_cmd_type : 1,
  22. reserved_2a : 31;
  23. uint32_t cmd_meta_data_31_0 : 32;
  24. uint32_t cmd_meta_data_63_32 : 32;
  25. uint32_t reserved_5a : 32;
  26. uint32_t reserved_6a : 32;
  27. uint32_t reserved_7a : 20,
  28. ring_id : 8,
  29. looping_count : 4;
  30. #else
  31. uint32_t control_buffer_addr_31_0 : 32;
  32. uint32_t reserved_1a : 12,
  33. cache_set_num : 4,
  34. index_search_en : 1,
  35. swap : 1,
  36. status_destination_ring_id : 1,
  37. gse_sel : 1,
  38. gse_ctrl : 4,
  39. control_buffer_addr_39_32 : 8;
  40. uint32_t reserved_2a : 31,
  41. tcl_cmd_type : 1;
  42. uint32_t cmd_meta_data_31_0 : 32;
  43. uint32_t cmd_meta_data_63_32 : 32;
  44. uint32_t reserved_5a : 32;
  45. uint32_t reserved_6a : 32;
  46. uint32_t looping_count : 4,
  47. ring_id : 8,
  48. reserved_7a : 20;
  49. #endif
  50. };
  51. #define TCL_GSE_CMD_CONTROL_BUFFER_ADDR_31_0_OFFSET 0x00000000
  52. #define TCL_GSE_CMD_CONTROL_BUFFER_ADDR_31_0_LSB 0
  53. #define TCL_GSE_CMD_CONTROL_BUFFER_ADDR_31_0_MSB 31
  54. #define TCL_GSE_CMD_CONTROL_BUFFER_ADDR_31_0_MASK 0xffffffff
  55. #define TCL_GSE_CMD_CONTROL_BUFFER_ADDR_39_32_OFFSET 0x00000004
  56. #define TCL_GSE_CMD_CONTROL_BUFFER_ADDR_39_32_LSB 0
  57. #define TCL_GSE_CMD_CONTROL_BUFFER_ADDR_39_32_MSB 7
  58. #define TCL_GSE_CMD_CONTROL_BUFFER_ADDR_39_32_MASK 0x000000ff
  59. #define TCL_GSE_CMD_GSE_CTRL_OFFSET 0x00000004
  60. #define TCL_GSE_CMD_GSE_CTRL_LSB 8
  61. #define TCL_GSE_CMD_GSE_CTRL_MSB 11
  62. #define TCL_GSE_CMD_GSE_CTRL_MASK 0x00000f00
  63. #define TCL_GSE_CMD_GSE_SEL_OFFSET 0x00000004
  64. #define TCL_GSE_CMD_GSE_SEL_LSB 12
  65. #define TCL_GSE_CMD_GSE_SEL_MSB 12
  66. #define TCL_GSE_CMD_GSE_SEL_MASK 0x00001000
  67. #define TCL_GSE_CMD_STATUS_DESTINATION_RING_ID_OFFSET 0x00000004
  68. #define TCL_GSE_CMD_STATUS_DESTINATION_RING_ID_LSB 13
  69. #define TCL_GSE_CMD_STATUS_DESTINATION_RING_ID_MSB 13
  70. #define TCL_GSE_CMD_STATUS_DESTINATION_RING_ID_MASK 0x00002000
  71. #define TCL_GSE_CMD_SWAP_OFFSET 0x00000004
  72. #define TCL_GSE_CMD_SWAP_LSB 14
  73. #define TCL_GSE_CMD_SWAP_MSB 14
  74. #define TCL_GSE_CMD_SWAP_MASK 0x00004000
  75. #define TCL_GSE_CMD_INDEX_SEARCH_EN_OFFSET 0x00000004
  76. #define TCL_GSE_CMD_INDEX_SEARCH_EN_LSB 15
  77. #define TCL_GSE_CMD_INDEX_SEARCH_EN_MSB 15
  78. #define TCL_GSE_CMD_INDEX_SEARCH_EN_MASK 0x00008000
  79. #define TCL_GSE_CMD_CACHE_SET_NUM_OFFSET 0x00000004
  80. #define TCL_GSE_CMD_CACHE_SET_NUM_LSB 16
  81. #define TCL_GSE_CMD_CACHE_SET_NUM_MSB 19
  82. #define TCL_GSE_CMD_CACHE_SET_NUM_MASK 0x000f0000
  83. #define TCL_GSE_CMD_RESERVED_1A_OFFSET 0x00000004
  84. #define TCL_GSE_CMD_RESERVED_1A_LSB 20
  85. #define TCL_GSE_CMD_RESERVED_1A_MSB 31
  86. #define TCL_GSE_CMD_RESERVED_1A_MASK 0xfff00000
  87. #define TCL_GSE_CMD_TCL_CMD_TYPE_OFFSET 0x00000008
  88. #define TCL_GSE_CMD_TCL_CMD_TYPE_LSB 0
  89. #define TCL_GSE_CMD_TCL_CMD_TYPE_MSB 0
  90. #define TCL_GSE_CMD_TCL_CMD_TYPE_MASK 0x00000001
  91. #define TCL_GSE_CMD_RESERVED_2A_OFFSET 0x00000008
  92. #define TCL_GSE_CMD_RESERVED_2A_LSB 1
  93. #define TCL_GSE_CMD_RESERVED_2A_MSB 31
  94. #define TCL_GSE_CMD_RESERVED_2A_MASK 0xfffffffe
  95. #define TCL_GSE_CMD_CMD_META_DATA_31_0_OFFSET 0x0000000c
  96. #define TCL_GSE_CMD_CMD_META_DATA_31_0_LSB 0
  97. #define TCL_GSE_CMD_CMD_META_DATA_31_0_MSB 31
  98. #define TCL_GSE_CMD_CMD_META_DATA_31_0_MASK 0xffffffff
  99. #define TCL_GSE_CMD_CMD_META_DATA_63_32_OFFSET 0x00000010
  100. #define TCL_GSE_CMD_CMD_META_DATA_63_32_LSB 0
  101. #define TCL_GSE_CMD_CMD_META_DATA_63_32_MSB 31
  102. #define TCL_GSE_CMD_CMD_META_DATA_63_32_MASK 0xffffffff
  103. #define TCL_GSE_CMD_RESERVED_5A_OFFSET 0x00000014
  104. #define TCL_GSE_CMD_RESERVED_5A_LSB 0
  105. #define TCL_GSE_CMD_RESERVED_5A_MSB 31
  106. #define TCL_GSE_CMD_RESERVED_5A_MASK 0xffffffff
  107. #define TCL_GSE_CMD_RESERVED_6A_OFFSET 0x00000018
  108. #define TCL_GSE_CMD_RESERVED_6A_LSB 0
  109. #define TCL_GSE_CMD_RESERVED_6A_MSB 31
  110. #define TCL_GSE_CMD_RESERVED_6A_MASK 0xffffffff
  111. #define TCL_GSE_CMD_RESERVED_7A_OFFSET 0x0000001c
  112. #define TCL_GSE_CMD_RESERVED_7A_LSB 0
  113. #define TCL_GSE_CMD_RESERVED_7A_MSB 19
  114. #define TCL_GSE_CMD_RESERVED_7A_MASK 0x000fffff
  115. #define TCL_GSE_CMD_RING_ID_OFFSET 0x0000001c
  116. #define TCL_GSE_CMD_RING_ID_LSB 20
  117. #define TCL_GSE_CMD_RING_ID_MSB 27
  118. #define TCL_GSE_CMD_RING_ID_MASK 0x0ff00000
  119. #define TCL_GSE_CMD_LOOPING_COUNT_OFFSET 0x0000001c
  120. #define TCL_GSE_CMD_LOOPING_COUNT_LSB 28
  121. #define TCL_GSE_CMD_LOOPING_COUNT_MSB 31
  122. #define TCL_GSE_CMD_LOOPING_COUNT_MASK 0xf0000000
  123. #endif