rx_mpdu_link_ptr.h 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213
  1. /*
  2. * Copyright (c) 2019 The Linux Foundation. All rights reserved.
  3. *
  4. * Permission to use, copy, modify, and/or distribute this software for
  5. * any purpose with or without fee is hereby granted, provided that the
  6. * above copyright notice and this permission notice appear in all
  7. * copies.
  8. *
  9. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
  10. * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
  11. * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
  12. * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
  13. * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
  14. * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
  15. * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
  16. * PERFORMANCE OF THIS SOFTWARE.
  17. */
  18. //
  19. // DO NOT EDIT! This file is automatically generated
  20. // These definitions are tied to a particular hardware layout
  21. #ifndef _RX_MPDU_LINK_PTR_H_
  22. #define _RX_MPDU_LINK_PTR_H_
  23. #if !defined(__ASSEMBLER__)
  24. #endif
  25. #include "buffer_addr_info.h"
  26. // ################ START SUMMARY #################
  27. //
  28. // Dword Fields
  29. // 0-1 struct buffer_addr_info mpdu_link_desc_addr_info;
  30. //
  31. // ################ END SUMMARY #################
  32. #define NUM_OF_DWORDS_RX_MPDU_LINK_PTR 2
  33. struct rx_mpdu_link_ptr {
  34. struct buffer_addr_info mpdu_link_desc_addr_info;
  35. };
  36. /*
  37. struct buffer_addr_info mpdu_link_desc_addr_info
  38. Details of the physical address of an MPDU link
  39. descriptor
  40. */
  41. /* EXTERNAL REFERENCE : struct buffer_addr_info mpdu_link_desc_addr_info */
  42. /* Description RX_MPDU_LINK_PTR_0_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_31_0
  43. Address (lower 32 bits) of the MSDU buffer OR
  44. MSDU_EXTENSION descriptor OR Link Descriptor
  45. In case of 'NULL' pointer, this field is set to 0
  46. <legal all>
  47. */
  48. #define RX_MPDU_LINK_PTR_0_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_31_0_OFFSET 0x00000000
  49. #define RX_MPDU_LINK_PTR_0_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_31_0_LSB 0
  50. #define RX_MPDU_LINK_PTR_0_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_31_0_MASK 0xffffffff
  51. /* Description RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_39_32
  52. Address (upper 8 bits) of the MSDU buffer OR
  53. MSDU_EXTENSION descriptor OR Link Descriptor
  54. In case of 'NULL' pointer, this field is set to 0
  55. <legal all>
  56. */
  57. #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_39_32_OFFSET 0x00000004
  58. #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_39_32_LSB 0
  59. #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_39_32_MASK 0x000000ff
  60. /* Description RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER
  61. Consumer: WBM
  62. Producer: SW/FW
  63. In case of 'NULL' pointer, this field is set to 0
  64. Indicates to which buffer manager the buffer OR
  65. MSDU_EXTENSION descriptor OR link descriptor that is being
  66. pointed to shall be returned after the frame has been
  67. processed. It is used by WBM for routing purposes.
  68. <enum 0 WBM_IDLE_BUF_LIST> This buffer shall be returned
  69. to the WMB buffer idle list
  70. <enum 1 WBM_IDLE_DESC_LIST> This buffer shall be
  71. returned to the WMB idle link descriptor idle list
  72. <enum 2 FW_BM> This buffer shall be returned to the FW
  73. <enum 3 SW0_BM> This buffer shall be returned to the SW,
  74. ring 0
  75. <enum 4 SW1_BM> This buffer shall be returned to the SW,
  76. ring 1
  77. <enum 5 SW2_BM> This buffer shall be returned to the SW,
  78. ring 2
  79. <enum 6 SW3_BM> This buffer shall be returned to the SW,
  80. ring 3
  81. <enum 7 SW4_BM> This buffer shall be returned to the SW,
  82. ring 4
  83. <legal all>
  84. */
  85. #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER_OFFSET 0x00000004
  86. #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER_LSB 8
  87. #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER_MASK 0x00000700
  88. /* Description RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_SW_BUFFER_COOKIE
  89. Cookie field exclusively used by SW.
  90. In case of 'NULL' pointer, this field is set to 0
  91. HW ignores the contents, accept that it passes the
  92. programmed value on to other descriptors together with the
  93. physical address
  94. Field can be used by SW to for example associate the
  95. buffers physical address with the virtual address
  96. The bit definitions as used by SW are within SW HLD
  97. specification
  98. NOTE:
  99. The three most significant bits can have a special
  100. meaning in case this struct is embedded in a TX_MPDU_DETAILS
  101. STRUCT, and field transmit_bw_restriction is set
  102. In case of NON punctured transmission:
  103. Sw_buffer_cookie[20:19] = 2'b00: 20 MHz TX only
  104. Sw_buffer_cookie[20:19] = 2'b01: 40 MHz TX only
  105. Sw_buffer_cookie[20:19] = 2'b10: 80 MHz TX only
  106. Sw_buffer_cookie[20:19] = 2'b11: 160 MHz TX only
  107. In case of punctured transmission:
  108. Sw_buffer_cookie[20:18] = 3'b000: pattern 0 only
  109. Sw_buffer_cookie[20:18] = 3'b001: pattern 1 only
  110. Sw_buffer_cookie[20:18] = 3'b010: pattern 2 only
  111. Sw_buffer_cookie[20:18] = 3'b011: pattern 3 only
  112. Sw_buffer_cookie[20:18] = 3'b100: pattern 4 only
  113. Sw_buffer_cookie[20:18] = 3'b101: pattern 5 only
  114. Sw_buffer_cookie[20:18] = 3'b110: pattern 6 only
  115. Sw_buffer_cookie[20:18] = 3'b111: pattern 7 only
  116. Note: a punctured transmission is indicated by the
  117. presence of TLV TX_PUNCTURE_SETUP embedded in the scheduler
  118. TLV
  119. <legal all>
  120. */
  121. #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_SW_BUFFER_COOKIE_OFFSET 0x00000004
  122. #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_SW_BUFFER_COOKIE_LSB 11
  123. #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_SW_BUFFER_COOKIE_MASK 0xfffff800
  124. #endif // _RX_MPDU_LINK_PTR_H_