#include <linux/bitfield.h>
#include <linux/bits.h>
#include <linux/device.h>
#include <linux/dma-direction.h>
#include <linux/types.h>
#include "gsi.h"
#include "gsi_trans.h"
#include "ipa.h"
#include "ipa_cmd.h"
#include "ipa_endpoint.h"
#include "ipa_mem.h"
#include "ipa_reg.h"
#include "ipa_table.h"
enum pipeline_clear_options { … };
struct ipa_cmd_hw_ip_fltrt_init { … };
#define IP_FLTRT_FLAGS_HASH_SIZE_FMASK …
#define IP_FLTRT_FLAGS_HASH_ADDR_FMASK …
#define IP_FLTRT_FLAGS_NHASH_SIZE_FMASK …
#define IP_FLTRT_FLAGS_NHASH_ADDR_FMASK …
struct ipa_cmd_hw_hdr_init_local { … };
#define HDR_INIT_LOCAL_FLAGS_TABLE_SIZE_FMASK …
#define HDR_INIT_LOCAL_FLAGS_HDR_ADDR_FMASK …
#define REGISTER_WRITE_OPCODE_SKIP_CLEAR_FMASK …
#define REGISTER_WRITE_OPCODE_CLEAR_OPTION_FMASK …
struct ipa_cmd_register_write { … };
#define REGISTER_WRITE_FLAGS_OFFSET_HIGH_FMASK …
#define REGISTER_WRITE_FLAGS_SKIP_CLEAR_FMASK …
#define REGISTER_WRITE_CLEAR_OPTIONS_FMASK …
struct ipa_cmd_ip_packet_init { … };
#define IPA_PACKET_INIT_DEST_ENDPOINT_FMASK …
#define DMA_SHARED_MEM_OPCODE_SKIP_CLEAR_FMASK …
#define DMA_SHARED_MEM_OPCODE_CLEAR_OPTION_FMASK …
struct ipa_cmd_hw_dma_mem_mem { … };
#define DMA_SHARED_MEM_CLEAR_AFTER_READ …
#define DMA_SHARED_MEM_FLAGS_DIRECTION_FMASK …
#define DMA_SHARED_MEM_FLAGS_SKIP_CLEAR_FMASK …
#define DMA_SHARED_MEM_FLAGS_CLEAR_OPTIONS_FMASK …
struct ipa_cmd_ip_packet_tag_status { … };
#define IP_PACKET_TAG_STATUS_TAG_FMASK …
ipa_cmd_payload;
static void ipa_cmd_validate_build(void)
{ … }
bool ipa_cmd_table_init_valid(struct ipa *ipa, const struct ipa_mem *mem,
bool route)
{ … }
static bool ipa_cmd_header_init_local_valid(struct ipa *ipa)
{ … }
static bool ipa_cmd_register_write_offset_valid(struct ipa *ipa,
const char *name, u32 offset)
{ … }
static bool ipa_cmd_register_write_valid(struct ipa *ipa)
{ … }
int ipa_cmd_pool_init(struct gsi_channel *channel, u32 tre_max)
{ … }
void ipa_cmd_pool_exit(struct gsi_channel *channel)
{ … }
static union ipa_cmd_payload *
ipa_cmd_payload_alloc(struct ipa *ipa, dma_addr_t *addr)
{ … }
void ipa_cmd_table_init_add(struct gsi_trans *trans,
enum ipa_cmd_opcode opcode, u16 size, u32 offset,
dma_addr_t addr, u16 hash_size, u32 hash_offset,
dma_addr_t hash_addr)
{ … }
void ipa_cmd_hdr_init_local_add(struct gsi_trans *trans, u32 offset, u16 size,
dma_addr_t addr)
{ … }
void ipa_cmd_register_write_add(struct gsi_trans *trans, u32 offset, u32 value,
u32 mask, bool clear_full)
{ … }
static void ipa_cmd_ip_packet_init_add(struct gsi_trans *trans, u8 endpoint_id)
{ … }
void ipa_cmd_dma_shared_mem_add(struct gsi_trans *trans, u32 offset, u16 size,
dma_addr_t addr, bool toward_ipa)
{ … }
static void ipa_cmd_ip_tag_status_add(struct gsi_trans *trans)
{ … }
static void ipa_cmd_transfer_add(struct gsi_trans *trans)
{ … }
void ipa_cmd_pipeline_clear_add(struct gsi_trans *trans)
{ … }
u32 ipa_cmd_pipeline_clear_count(void)
{ … }
void ipa_cmd_pipeline_clear_wait(struct ipa *ipa)
{ … }
struct gsi_trans *ipa_cmd_trans_alloc(struct ipa *ipa, u32 tre_count)
{ … }
int ipa_cmd_init(struct ipa *ipa)
{ … }