#include <linux/etherdevice.h>
#include <linux/moduleparam.h>
#include <linux/prefetch.h>
#include <linux/types.h>
#include <linux/list.h>
#include <linux/ip.h>
#include <linux/ipv6.h>
#include "wil6210.h"
#include "txrx_edma.h"
#include "txrx.h"
#include "trace.h"
#define WIL_EDMA_TX_SRING_UPDATE_HW_TAIL …
#define WIL_EDMA_MAX_DATA_OFFSET …
#define WIL_EDMA_RX_BUF_LEN_DEFAULT …
#define MAX_INVALID_BUFF_ID_RETRY …
static void wil_tx_desc_unmap_edma(struct device *dev,
union wil_tx_desc *desc,
struct wil_ctx *ctx)
{ … }
static int wil_find_free_sring(struct wil6210_priv *wil)
{ … }
static void wil_sring_free(struct wil6210_priv *wil,
struct wil_status_ring *sring)
{ … }
static int wil_sring_alloc(struct wil6210_priv *wil,
struct wil_status_ring *sring)
{ … }
static int wil_tx_init_edma(struct wil6210_priv *wil)
{ … }
static int wil_ring_alloc_skb_edma(struct wil6210_priv *wil,
struct wil_ring *ring, u32 i)
{ … }
static inline
void wil_get_next_rx_status_msg(struct wil_status_ring *sring, u8 *dr_bit,
void *msg)
{ … }
static inline void wil_sring_advance_swhead(struct wil_status_ring *sring)
{ … }
static int wil_rx_refill_edma(struct wil6210_priv *wil)
{ … }
static void wil_move_all_rx_buff_to_free_list(struct wil6210_priv *wil,
struct wil_ring *ring)
{ … }
static void wil_free_rx_buff_arr(struct wil6210_priv *wil)
{ … }
static int wil_init_rx_buff_arr(struct wil6210_priv *wil,
size_t size)
{ … }
static int wil_init_rx_sring(struct wil6210_priv *wil,
u16 status_ring_size,
size_t elem_size,
u16 ring_id)
{ … }
static int wil_ring_alloc_desc_ring(struct wil6210_priv *wil,
struct wil_ring *ring)
{ … }
static void wil_ring_free_edma(struct wil6210_priv *wil, struct wil_ring *ring)
{ … }
static int wil_init_rx_desc_ring(struct wil6210_priv *wil, u16 desc_ring_size,
int status_ring_id)
{ … }
static void wil_get_reorder_params_edma(struct wil6210_priv *wil,
struct sk_buff *skb, int *tid,
int *cid, int *mid, u16 *seq,
int *mcast, int *retry)
{ … }
static void wil_get_netif_rx_params_edma(struct sk_buff *skb, int *cid,
int *security)
{ … }
static int wil_rx_crypto_check_edma(struct wil6210_priv *wil,
struct sk_buff *skb)
{ … }
static bool wil_is_rx_idle_edma(struct wil6210_priv *wil)
{ … }
static void wil_rx_buf_len_init_edma(struct wil6210_priv *wil)
{ … }
static int wil_rx_init_edma(struct wil6210_priv *wil, uint desc_ring_order)
{ … }
static int wil_ring_init_tx_edma(struct wil6210_vif *vif, int ring_id,
int size, int cid, int tid)
{ … }
static int wil_tx_ring_modify_edma(struct wil6210_vif *vif, int ring_id,
int cid, int tid)
{ … }
static int wil_check_bar(struct wil6210_priv *wil, void *msg, int cid,
struct sk_buff *skb, struct wil_net_stats *stats)
{ … }
static int wil_rx_error_check_edma(struct wil6210_priv *wil,
struct sk_buff *skb,
struct wil_net_stats *stats)
{ … }
static struct sk_buff *wil_sring_reap_rx_edma(struct wil6210_priv *wil,
struct wil_status_ring *sring)
{ … }
void wil_rx_handle_edma(struct wil6210_priv *wil, int *quota)
{ … }
static int wil_tx_desc_map_edma(union wil_tx_desc *desc,
dma_addr_t pa,
u32 len,
int ring_index)
{ … }
static inline void
wil_get_next_tx_status_msg(struct wil_status_ring *sring, u8 *dr_bit,
struct wil_ring_tx_status *msg)
{ … }
int wil_tx_sring_handler(struct wil6210_priv *wil,
struct wil_status_ring *sring)
{ … }
static void wil_tx_desc_offload_setup_tso_edma(struct wil_tx_enhanced_desc *d,
int tso_desc_type, bool is_ipv4,
int tcp_hdr_len,
int skb_net_hdr_len,
int mss)
{ … }
static int wil_tx_tso_gen_desc(struct wil6210_priv *wil, void *buff_addr,
int len, uint i, int tso_desc_type,
skb_frag_t *frag, struct wil_ring *ring,
struct sk_buff *skb, bool is_ipv4,
int tcp_hdr_len, int skb_net_hdr_len,
int mss, int *descs_used)
{ … }
static int __wil_tx_ring_tso_edma(struct wil6210_priv *wil,
struct wil6210_vif *vif,
struct wil_ring *ring,
struct sk_buff *skb)
{ … }
static int wil_ring_init_bcast_edma(struct wil6210_vif *vif, int ring_id,
int size)
{ … }
static void wil_tx_fini_edma(struct wil6210_priv *wil)
{ … }
static void wil_rx_data_free(struct wil_status_ring *sring)
{ … }
static void wil_rx_fini_edma(struct wil6210_priv *wil)
{ … }
void wil_init_txrx_ops_edma(struct wil6210_priv *wil)
{ … }