linux/drivers/net/ethernet/marvell/octeontx2/af/rvu_cpt.c

// SPDX-License-Identifier: GPL-2.0-only
/* Marvell RVU Admin Function driver
 *
 * Copyright (C) 2020 Marvell.
 *
 */

#include <linux/bitfield.h>
#include <linux/pci.h>
#include "rvu_struct.h"
#include "rvu_reg.h"
#include "mbox.h"
#include "rvu.h"

/* CPT PF device id */
#define PCI_DEVID_OTX2_CPT_PF
#define PCI_DEVID_OTX2_CPT10K_PF

/* Length of initial context fetch in 128 byte words */
#define CPT_CTX_ILEN

#define cpt_get_eng_sts(e_min, e_max, rsp, etype)

static irqreturn_t cpt_af_flt_intr_handler(int vec, void *ptr)
{}

static irqreturn_t rvu_cpt_af_flt0_intr_handler(int irq, void *ptr)
{}

static irqreturn_t rvu_cpt_af_flt1_intr_handler(int irq, void *ptr)
{}

static irqreturn_t rvu_cpt_af_flt2_intr_handler(int irq, void *ptr)
{}

static irqreturn_t rvu_cpt_af_rvu_intr_handler(int irq, void *ptr)
{}

static irqreturn_t rvu_cpt_af_ras_intr_handler(int irq, void *ptr)
{}

static int rvu_cpt_do_register_interrupt(struct rvu_block *block, int irq_offs,
					 irq_handler_t handler,
					 const char *name)
{}

static void cpt_10k_unregister_interrupts(struct rvu_block *block, int off)
{}

static void cpt_unregister_interrupts(struct rvu *rvu, int blkaddr)
{}

void rvu_cpt_unregister_interrupts(struct rvu *rvu)
{}

static int cpt_10k_register_interrupts(struct rvu_block *block, int off)
{}

static int cpt_register_interrupts(struct rvu *rvu, int blkaddr)
{}

int rvu_cpt_register_interrupts(struct rvu *rvu)
{}

static int get_cpt_pf_num(struct rvu *rvu)
{}

static bool is_cpt_pf(struct rvu *rvu, u16 pcifunc)
{}

static bool is_cpt_vf(struct rvu *rvu, u16 pcifunc)
{}

static int validate_and_get_cpt_blkaddr(int req_blkaddr)
{}

int rvu_mbox_handler_cpt_lf_alloc(struct rvu *rvu,
				  struct cpt_lf_alloc_req_msg *req,
				  struct msg_rsp *rsp)
{}

static int cpt_lf_free(struct rvu *rvu, struct msg_req *req, int blkaddr)
{}

int rvu_mbox_handler_cpt_lf_free(struct rvu *rvu, struct msg_req *req,
				 struct msg_rsp *rsp)
{}

static int cpt_inline_ipsec_cfg_inbound(struct rvu *rvu, int blkaddr, u8 cptlf,
					struct cpt_inline_ipsec_cfg_msg *req)
{}

static int cpt_inline_ipsec_cfg_outbound(struct rvu *rvu, int blkaddr, u8 cptlf,
					 struct cpt_inline_ipsec_cfg_msg *req)
{}

int rvu_mbox_handler_cpt_inline_ipsec_cfg(struct rvu *rvu,
					  struct cpt_inline_ipsec_cfg_msg *req,
					  struct msg_rsp *rsp)
{}

static bool is_valid_offset(struct rvu *rvu, struct cpt_rd_wr_reg_msg *req)
{}

int rvu_mbox_handler_cpt_rd_wr_register(struct rvu *rvu,
					struct cpt_rd_wr_reg_msg *req,
					struct cpt_rd_wr_reg_msg *rsp)
{}

static void get_ctx_pc(struct rvu *rvu, struct cpt_sts_rsp *rsp, int blkaddr)
{}

static void get_eng_sts(struct rvu *rvu, struct cpt_sts_rsp *rsp, int blkaddr)
{}

int rvu_mbox_handler_cpt_sts(struct rvu *rvu, struct cpt_sts_req *req,
			     struct cpt_sts_rsp *rsp)
{}

#define RXC_ZOMBIE_THRES
#define RXC_ZOMBIE_LIMIT
#define RXC_ACTIVE_THRES
#define RXC_ACTIVE_LIMIT
#define RXC_ACTIVE_COUNT
#define RXC_ZOMBIE_COUNT

static void cpt_rxc_time_cfg(struct rvu *rvu, struct cpt_rxc_time_cfg_req *req,
			     int blkaddr, struct cpt_rxc_time_cfg_req *save)
{}

int rvu_mbox_handler_cpt_rxc_time_cfg(struct rvu *rvu,
				      struct cpt_rxc_time_cfg_req *req,
				      struct msg_rsp *rsp)
{}

int rvu_mbox_handler_cpt_ctx_cache_sync(struct rvu *rvu, struct msg_req *req,
					struct msg_rsp *rsp)
{}

int rvu_mbox_handler_cpt_lf_reset(struct rvu *rvu, struct cpt_lf_rst_req *req,
				  struct msg_rsp *rsp)
{}

int rvu_mbox_handler_cpt_flt_eng_info(struct rvu *rvu, struct cpt_flt_eng_info_req *req,
				      struct cpt_flt_eng_info_rsp *rsp)
{}

static void cpt_rxc_teardown(struct rvu *rvu, int blkaddr)
{}

#define INFLIGHT
#define GRB_CNT
#define GWB_CNT
#define XQ_XOR
#define DQPTR
#define NQPTR

static void cpt_lf_disable_iqueue(struct rvu *rvu, int blkaddr, int slot)
{}

int rvu_cpt_lf_teardown(struct rvu *rvu, u16 pcifunc, int blkaddr, int lf, int slot)
{}

#define CPT_RES_LEN
#define CPT_SE_IE_EGRP

static int cpt_inline_inb_lf_cmd_send(struct rvu *rvu, int blkaddr,
				      int nix_blkaddr)
{}

#define CTX_CAM_PF_FUNC
#define CTX_CAM_CPTR

int rvu_cpt_ctx_flush(struct rvu *rvu, u16 pcifunc)
{}

int rvu_cpt_init(struct rvu *rvu)
{}