rx_reo_queue_reference.h 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. /*
  2. * Copyright (c) 2023 Qualcomm Innovation Center, Inc. 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. #ifndef _RX_REO_QUEUE_REFERENCE_H_
  17. #define _RX_REO_QUEUE_REFERENCE_H_
  18. #if !defined(__ASSEMBLER__)
  19. #endif
  20. #define NUM_OF_DWORDS_RX_REO_QUEUE_REFERENCE 2
  21. struct rx_reo_queue_reference {
  22. #ifndef WIFI_BIT_ORDER_BIG_ENDIAN
  23. uint32_t rx_reo_queue_desc_addr_31_0 : 32; // [31:0]
  24. uint32_t rx_reo_queue_desc_addr_39_32 : 8, // [7:0]
  25. reserved_1 : 8, // [15:8]
  26. receive_queue_number : 16; // [31:16]
  27. #else
  28. uint32_t rx_reo_queue_desc_addr_31_0 : 32; // [31:0]
  29. uint32_t receive_queue_number : 16, // [31:16]
  30. reserved_1 : 8, // [15:8]
  31. rx_reo_queue_desc_addr_39_32 : 8; // [7:0]
  32. #endif
  33. };
  34. /* Description RX_REO_QUEUE_DESC_ADDR_31_0
  35. Consumer: RXDMA
  36. Producer: RXOLE
  37. Address (lower 32 bits) of the REO queue descriptor.
  38. <legal all>
  39. */
  40. #define RX_REO_QUEUE_REFERENCE_RX_REO_QUEUE_DESC_ADDR_31_0_OFFSET 0x00000000
  41. #define RX_REO_QUEUE_REFERENCE_RX_REO_QUEUE_DESC_ADDR_31_0_LSB 0
  42. #define RX_REO_QUEUE_REFERENCE_RX_REO_QUEUE_DESC_ADDR_31_0_MSB 31
  43. #define RX_REO_QUEUE_REFERENCE_RX_REO_QUEUE_DESC_ADDR_31_0_MASK 0xffffffff
  44. /* Description RX_REO_QUEUE_DESC_ADDR_39_32
  45. Consumer: RXDMA
  46. Producer: RXOLE
  47. Address (upper 8 bits) of the REO queue descriptor.
  48. <legal all>
  49. */
  50. #define RX_REO_QUEUE_REFERENCE_RX_REO_QUEUE_DESC_ADDR_39_32_OFFSET 0x00000004
  51. #define RX_REO_QUEUE_REFERENCE_RX_REO_QUEUE_DESC_ADDR_39_32_LSB 0
  52. #define RX_REO_QUEUE_REFERENCE_RX_REO_QUEUE_DESC_ADDR_39_32_MSB 7
  53. #define RX_REO_QUEUE_REFERENCE_RX_REO_QUEUE_DESC_ADDR_39_32_MASK 0x000000ff
  54. /* Description RESERVED_1
  55. <legal 0>
  56. */
  57. #define RX_REO_QUEUE_REFERENCE_RESERVED_1_OFFSET 0x00000004
  58. #define RX_REO_QUEUE_REFERENCE_RESERVED_1_LSB 8
  59. #define RX_REO_QUEUE_REFERENCE_RESERVED_1_MSB 15
  60. #define RX_REO_QUEUE_REFERENCE_RESERVED_1_MASK 0x0000ff00
  61. /* Description RECEIVE_QUEUE_NUMBER
  62. Indicates the MPDU queue ID to which this MPDU link descriptor
  63. belongs
  64. Used for tracking and debugging
  65. <legal all>
  66. */
  67. #define RX_REO_QUEUE_REFERENCE_RECEIVE_QUEUE_NUMBER_OFFSET 0x00000004
  68. #define RX_REO_QUEUE_REFERENCE_RECEIVE_QUEUE_NUMBER_LSB 16
  69. #define RX_REO_QUEUE_REFERENCE_RECEIVE_QUEUE_NUMBER_MSB 31
  70. #define RX_REO_QUEUE_REFERENCE_RECEIVE_QUEUE_NUMBER_MASK 0xffff0000
  71. #endif // RX_REO_QUEUE_REFERENCE