/space/home/slher/rel/Beken/v6_4_5/macsw/ip/lmac/src/rx/rxl/v20/rxl_hwdesc.c File Reference

Implementation of the API function used to initialize the pools. More...

#include "rxl_hwdesc.h"
#include "ke_event.h"
#include "rxl_cntrl.h"
#include "rxu_cntrl.h"
#include "co_utils.h"
#include "macif.h"
#include "txl_cfm.h"
#include "co_endian.h"
#include "reg_mac_pl.h"
#include "reg_mac_core.h"

Go to the source code of this file.

Data Structures

struct  rxl_buffer_tag
 Structure caching the RX buffers parameters. More...
struct  rxl_hwdesc_env_tag
 Buffer Management control structure. More...

Defines

#define RXL_WRAP   CO_BIT(31)
 Bit indicating a buffer wrap in the read and write addresses.
#define RXL_RXDESC_SIZE   (sizeof_b(struct rxdesc))
 RX descriptor size.
#define RXL_RHD_HEADER   (sizeof_b(struct rx_upload_cntrl_tag) / 4)
 Head room for RHD.
#define RXL_RHD_FOOTER   ((RXL_RXDESC_SIZE - sizeof_b(struct rx_hd)) / 4 - RXL_RHD_HEADER)
 Tail room for RHD.
#define RXL_RBD_HEADER   0
 Head room for RBD.
#define RXL_RBD_FOOTER   ((sizeof_b(struct rx_payloaddesc) - sizeof_b(struct rx_pbd)) / 4)
 Tail room for RBD.
#define RXL_BUFFER1_SIZE   ((RWNX_MAX_AMSDU_RX + RXL_RXDESC_SIZE) / 2)
 Size of the RX buffer 1 (the size of 2 big A-MSDUs + their descriptors).
#define RXL_BUFFER2_SIZE   ((512 + RXL_RXDESC_SIZE) / 4)
 Size of the RX buffer 2 (512 bytes + the size of a RX descriptor).
#define RXL_HW_BUFFER_INIT(id)
 Macro initializing the buffer pointers to the HW.

Enumerations

enum  rx_buf_id { DH_BUF = 0, IH_BUF = 1 }
 

RX buffers identifiers.

More...

Functions

__INLINE bool rxl_dh_buf_has_data (void)
 Return the DH buffer status.
__INLINE bool rxl_ih_buf_has_data (void)
 Return the IH buffer status.
__INLINE uint32_t rxl_add_wrap_bit (uint32_t new_read, uint32_t old_read)
 Set correctly the wrap bit (bit 31) to the new read address, based on the previous read address.
__INLINE void rxl_update_hw_buf_read (uint32_t new_read, int id)
 Update the read address HW register.
__INLINE void rxl_update_sw_buf_read (uint32_t new_read, struct rxl_buffer_tag *buf)
 Update the read address of the FW.
__INLINE void rxl_adjust_sw_buf_read (struct rxl_buffer_tag *buf)
 Check if there is enough space between the SW read address and the end of the buffer.
__INLINE void rxl_adjust_frmlen (struct rx_hd *rhd)
 Remove the MIC/ICV/FCS length from the frame length.
static bool rxl_rxcntrl_frame (struct rxdesc *rxdesc)
 This function processes the received control frames.
static struct rx_payloaddescrxl_payload_transfer (struct rx_payloaddesc **curr_pd, uint16_t upload_len, uint32_t hostbuf, uint16_t *payl_offset, int dma_idx, int irq_en)
 Upload a payload to a higher layer buffer.
static void rxl_go_to_last_rbd (struct rxdesc *rxdesc, struct rx_payloaddesc *pd, struct rx_payloaddesc *prev_pd)
 Loop on the payload descriptors until the RX_PD_LASTBUF flag is found.
void rxl_hwdesc_init (void)
 Initialize the pools of element Function to initialize the Rx buffer and descriptor pools.
void rxl_hwdesc_monitor (bool enable)
 This function is called when an interface is changing its type, in order to configure correctly the RX path for either monitor or active mode.
void rxl_frame_release (struct rxdesc *rxdesc)
 This function cleans up the complete frame data structures.
void rxl_mpdu_copy (struct rx_pbd *pbd, uint16_t length, uint16_t offset, uint32_t *dst)
 Do a SW copy of a received MPDU.
void rxl_mpdu_partial_transfer (struct rxdesc *rxdesc, uint16_t upload_len, uint32_t hostbuf, uint16_t payl_offset, cb_rx_dma_func_ptr cb, void *env)
 Do a partial upload of a MPDU to a host buffer.
void rxl_mpdu_transfer (struct rxdesc *rxdesc)
 This function programs the DMA transfer of the received payload to the host memory.
void rxl_mpdu_free (struct rxdesc *rxdesc)
 Free the HW descriptors attached to the SW descriptor passed as parameter.
struct rxdescrxl_rxdesc_get (void)
 Get the RX descriptor pointing to the first MPDU ready for processing.
void rxl_rxdesc_ready_for_processing (struct rxdesc *rxdesc)
 Indicate that the MPDU associated to the descriptor is ready for processing.
void rxl_mpdu_isr (void)
 Service routine for the MAC HW RX interrupt.
void rxl_immediate_frame_get (void)
 Function used to get the immediate frame that was indicated from its dedicated interrupt.
void rxl_current_desc_get (struct rx_hd **rhd, struct rx_pbd **rbd)
 This function returns the pointer to the first RX Header and Buffer descriptors chained to the MAC HW.

Variables

static struct rxl_hwdesc_env_tag rx_hwdesc_env
 RXL HW descriptor environment variable.
static uint32_t rxl_hw_buffer1 [RXL_BUFFER1_SIZE]
 RX buffer 1, i.e.
static uint32_t rxl_hw_buffer2 [RXL_BUFFER2_SIZE]
 RX buffer 2, i.e.

Detailed Description

Implementation of the API function used to initialize the pools.

Copyright (C) RivieraWaves 2011-2019

Definition in file rxl_hwdesc.c.


Generated on 14 Jan 2020 for Ceva-RW WLAN FullMAC SW documentation by  doxygen 1.6.1