xref: /wlan-driver/fw-api/hw/peach/v1/coex_tx_status.h (revision 5113495b16420b49004c444715d2daae2066e7dc)
1*5113495bSYour Name /*
2*5113495bSYour Name  * Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
3*5113495bSYour Name  *
4*5113495bSYour Name  * Permission to use, copy, modify, and/or distribute this software for any
5*5113495bSYour Name  * purpose with or without fee is hereby granted, provided that the above
6*5113495bSYour Name  * copyright notice and this permission notice appear in all copies.
7*5113495bSYour Name  *
8*5113495bSYour Name  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9*5113495bSYour Name  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10*5113495bSYour Name  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11*5113495bSYour Name  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12*5113495bSYour Name  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13*5113495bSYour Name  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14*5113495bSYour Name  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15*5113495bSYour Name  */
16*5113495bSYour Name 
17*5113495bSYour Name 
18*5113495bSYour Name #ifndef _COEX_TX_STATUS_H_
19*5113495bSYour Name #define _COEX_TX_STATUS_H_
20*5113495bSYour Name 
21*5113495bSYour Name #define NUM_OF_DWORDS_COEX_TX_STATUS 3
22*5113495bSYour Name 
23*5113495bSYour Name struct coex_tx_status {
24*5113495bSYour Name #ifndef WIFI_BIT_ORDER_BIG_ENDIAN
25*5113495bSYour Name              uint32_t reserved_0a                                             :  7,
26*5113495bSYour Name                       tx_bw                                                   :  3,
27*5113495bSYour Name                       tx_status_reason                                        :  3,
28*5113495bSYour Name                       tx_wait_ack                                             :  1,
29*5113495bSYour Name                       fes_tx_is_gen_frame                                     :  1,
30*5113495bSYour Name                       sch_tx_burst_ongoing                                    :  1,
31*5113495bSYour Name                       current_tx_duration                                     : 16;
32*5113495bSYour Name              uint32_t next_rx_active_time                                     : 16,
33*5113495bSYour Name                       remaining_fes_time                                      : 16;
34*5113495bSYour Name              uint32_t tx_antenna_mask                                         :  8,
35*5113495bSYour Name                       shared_ant_tx_pwr                                       :  8,
36*5113495bSYour Name                       other_ant_tx_pwr                                        :  8,
37*5113495bSYour Name                       reserved_2                                              :  8;
38*5113495bSYour Name #else
39*5113495bSYour Name              uint32_t current_tx_duration                                     : 16,
40*5113495bSYour Name                       sch_tx_burst_ongoing                                    :  1,
41*5113495bSYour Name                       fes_tx_is_gen_frame                                     :  1,
42*5113495bSYour Name                       tx_wait_ack                                             :  1,
43*5113495bSYour Name                       tx_status_reason                                        :  3,
44*5113495bSYour Name                       tx_bw                                                   :  3,
45*5113495bSYour Name                       reserved_0a                                             :  7;
46*5113495bSYour Name              uint32_t remaining_fes_time                                      : 16,
47*5113495bSYour Name                       next_rx_active_time                                     : 16;
48*5113495bSYour Name              uint32_t reserved_2                                              :  8,
49*5113495bSYour Name                       other_ant_tx_pwr                                        :  8,
50*5113495bSYour Name                       shared_ant_tx_pwr                                       :  8,
51*5113495bSYour Name                       tx_antenna_mask                                         :  8;
52*5113495bSYour Name #endif
53*5113495bSYour Name };
54*5113495bSYour Name 
55*5113495bSYour Name #define COEX_TX_STATUS_RESERVED_0A_OFFSET                                           0x00000000
56*5113495bSYour Name #define COEX_TX_STATUS_RESERVED_0A_LSB                                              0
57*5113495bSYour Name #define COEX_TX_STATUS_RESERVED_0A_MSB                                              6
58*5113495bSYour Name #define COEX_TX_STATUS_RESERVED_0A_MASK                                             0x0000007f
59*5113495bSYour Name 
60*5113495bSYour Name #define COEX_TX_STATUS_TX_BW_OFFSET                                                 0x00000000
61*5113495bSYour Name #define COEX_TX_STATUS_TX_BW_LSB                                                    7
62*5113495bSYour Name #define COEX_TX_STATUS_TX_BW_MSB                                                    9
63*5113495bSYour Name #define COEX_TX_STATUS_TX_BW_MASK                                                   0x00000380
64*5113495bSYour Name 
65*5113495bSYour Name #define COEX_TX_STATUS_TX_STATUS_REASON_OFFSET                                      0x00000000
66*5113495bSYour Name #define COEX_TX_STATUS_TX_STATUS_REASON_LSB                                         10
67*5113495bSYour Name #define COEX_TX_STATUS_TX_STATUS_REASON_MSB                                         12
68*5113495bSYour Name #define COEX_TX_STATUS_TX_STATUS_REASON_MASK                                        0x00001c00
69*5113495bSYour Name 
70*5113495bSYour Name #define COEX_TX_STATUS_TX_WAIT_ACK_OFFSET                                           0x00000000
71*5113495bSYour Name #define COEX_TX_STATUS_TX_WAIT_ACK_LSB                                              13
72*5113495bSYour Name #define COEX_TX_STATUS_TX_WAIT_ACK_MSB                                              13
73*5113495bSYour Name #define COEX_TX_STATUS_TX_WAIT_ACK_MASK                                             0x00002000
74*5113495bSYour Name 
75*5113495bSYour Name #define COEX_TX_STATUS_FES_TX_IS_GEN_FRAME_OFFSET                                   0x00000000
76*5113495bSYour Name #define COEX_TX_STATUS_FES_TX_IS_GEN_FRAME_LSB                                      14
77*5113495bSYour Name #define COEX_TX_STATUS_FES_TX_IS_GEN_FRAME_MSB                                      14
78*5113495bSYour Name #define COEX_TX_STATUS_FES_TX_IS_GEN_FRAME_MASK                                     0x00004000
79*5113495bSYour Name 
80*5113495bSYour Name #define COEX_TX_STATUS_SCH_TX_BURST_ONGOING_OFFSET                                  0x00000000
81*5113495bSYour Name #define COEX_TX_STATUS_SCH_TX_BURST_ONGOING_LSB                                     15
82*5113495bSYour Name #define COEX_TX_STATUS_SCH_TX_BURST_ONGOING_MSB                                     15
83*5113495bSYour Name #define COEX_TX_STATUS_SCH_TX_BURST_ONGOING_MASK                                    0x00008000
84*5113495bSYour Name 
85*5113495bSYour Name #define COEX_TX_STATUS_CURRENT_TX_DURATION_OFFSET                                   0x00000000
86*5113495bSYour Name #define COEX_TX_STATUS_CURRENT_TX_DURATION_LSB                                      16
87*5113495bSYour Name #define COEX_TX_STATUS_CURRENT_TX_DURATION_MSB                                      31
88*5113495bSYour Name #define COEX_TX_STATUS_CURRENT_TX_DURATION_MASK                                     0xffff0000
89*5113495bSYour Name 
90*5113495bSYour Name #define COEX_TX_STATUS_NEXT_RX_ACTIVE_TIME_OFFSET                                   0x00000004
91*5113495bSYour Name #define COEX_TX_STATUS_NEXT_RX_ACTIVE_TIME_LSB                                      0
92*5113495bSYour Name #define COEX_TX_STATUS_NEXT_RX_ACTIVE_TIME_MSB                                      15
93*5113495bSYour Name #define COEX_TX_STATUS_NEXT_RX_ACTIVE_TIME_MASK                                     0x0000ffff
94*5113495bSYour Name 
95*5113495bSYour Name #define COEX_TX_STATUS_REMAINING_FES_TIME_OFFSET                                    0x00000004
96*5113495bSYour Name #define COEX_TX_STATUS_REMAINING_FES_TIME_LSB                                       16
97*5113495bSYour Name #define COEX_TX_STATUS_REMAINING_FES_TIME_MSB                                       31
98*5113495bSYour Name #define COEX_TX_STATUS_REMAINING_FES_TIME_MASK                                      0xffff0000
99*5113495bSYour Name 
100*5113495bSYour Name #define COEX_TX_STATUS_TX_ANTENNA_MASK_OFFSET                                       0x00000008
101*5113495bSYour Name #define COEX_TX_STATUS_TX_ANTENNA_MASK_LSB                                          0
102*5113495bSYour Name #define COEX_TX_STATUS_TX_ANTENNA_MASK_MSB                                          7
103*5113495bSYour Name #define COEX_TX_STATUS_TX_ANTENNA_MASK_MASK                                         0x000000ff
104*5113495bSYour Name 
105*5113495bSYour Name #define COEX_TX_STATUS_SHARED_ANT_TX_PWR_OFFSET                                     0x00000008
106*5113495bSYour Name #define COEX_TX_STATUS_SHARED_ANT_TX_PWR_LSB                                        8
107*5113495bSYour Name #define COEX_TX_STATUS_SHARED_ANT_TX_PWR_MSB                                        15
108*5113495bSYour Name #define COEX_TX_STATUS_SHARED_ANT_TX_PWR_MASK                                       0x0000ff00
109*5113495bSYour Name 
110*5113495bSYour Name #define COEX_TX_STATUS_OTHER_ANT_TX_PWR_OFFSET                                      0x00000008
111*5113495bSYour Name #define COEX_TX_STATUS_OTHER_ANT_TX_PWR_LSB                                         16
112*5113495bSYour Name #define COEX_TX_STATUS_OTHER_ANT_TX_PWR_MSB                                         23
113*5113495bSYour Name #define COEX_TX_STATUS_OTHER_ANT_TX_PWR_MASK                                        0x00ff0000
114*5113495bSYour Name 
115*5113495bSYour Name #define COEX_TX_STATUS_RESERVED_2_OFFSET                                            0x00000008
116*5113495bSYour Name #define COEX_TX_STATUS_RESERVED_2_LSB                                               24
117*5113495bSYour Name #define COEX_TX_STATUS_RESERVED_2_MSB                                               31
118*5113495bSYour Name #define COEX_TX_STATUS_RESERVED_2_MASK                                              0xff000000
119*5113495bSYour Name 
120*5113495bSYour Name #endif
121