#include <linux/hardirq.h>
#include <linux/export.h>
#include <linux/mlx4/cmd.h>
#include <linux/mlx4/cq.h>
#include "mlx4.h"
#include "icm.h"
#define MLX4_CQ_STATUS_OK …
#define MLX4_CQ_STATUS_OVERFLOW …
#define MLX4_CQ_STATUS_WRITE_FAIL …
#define MLX4_CQ_FLAG_CC …
#define MLX4_CQ_FLAG_OI …
#define MLX4_CQ_STATE_ARMED …
#define MLX4_CQ_STATE_ARMED_SOL …
#define MLX4_EQ_STATE_FIRED …
#define TASKLET_MAX_TIME …
#define TASKLET_MAX_TIME_JIFFIES …
void mlx4_cq_tasklet_cb(struct tasklet_struct *t)
{ … }
static void mlx4_add_cq_to_tasklet(struct mlx4_cq *cq)
{ … }
void mlx4_cq_completion(struct mlx4_dev *dev, u32 cqn)
{ … }
void mlx4_cq_event(struct mlx4_dev *dev, u32 cqn, int event_type)
{ … }
static int mlx4_SW2HW_CQ(struct mlx4_dev *dev, struct mlx4_cmd_mailbox *mailbox,
int cq_num, u8 opmod)
{ … }
static int mlx4_MODIFY_CQ(struct mlx4_dev *dev, struct mlx4_cmd_mailbox *mailbox,
int cq_num, u32 opmod)
{ … }
static int mlx4_HW2SW_CQ(struct mlx4_dev *dev, struct mlx4_cmd_mailbox *mailbox,
int cq_num)
{ … }
int mlx4_cq_modify(struct mlx4_dev *dev, struct mlx4_cq *cq,
u16 count, u16 period)
{ … }
EXPORT_SYMBOL_GPL(…);
int mlx4_cq_resize(struct mlx4_dev *dev, struct mlx4_cq *cq,
int entries, struct mlx4_mtt *mtt)
{ … }
EXPORT_SYMBOL_GPL(…);
int __mlx4_cq_alloc_icm(struct mlx4_dev *dev, int *cqn)
{ … }
static int mlx4_cq_alloc_icm(struct mlx4_dev *dev, int *cqn, u8 usage)
{ … }
void __mlx4_cq_free_icm(struct mlx4_dev *dev, int cqn)
{ … }
static void mlx4_cq_free_icm(struct mlx4_dev *dev, int cqn)
{ … }
static int mlx4_init_user_cqes(void *buf, int entries, int cqe_size)
{ … }
static void mlx4_init_kernel_cqes(struct mlx4_buf *buf,
int entries,
int cqe_size)
{ … }
int mlx4_cq_alloc(struct mlx4_dev *dev, int nent,
struct mlx4_mtt *mtt, struct mlx4_uar *uar, u64 db_rec,
struct mlx4_cq *cq, unsigned vector, int collapsed,
int timestamp_en, void *buf_addr, bool user_cq)
{ … }
EXPORT_SYMBOL_GPL(…);
void mlx4_cq_free(struct mlx4_dev *dev, struct mlx4_cq *cq)
{ … }
EXPORT_SYMBOL_GPL(…);
int mlx4_init_cq_table(struct mlx4_dev *dev)
{ … }
void mlx4_cleanup_cq_table(struct mlx4_dev *dev)
{ … }