linux/drivers/infiniband/sw/rxe/rxe_qp.c

// SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB
/*
 * Copyright (c) 2016 Mellanox Technologies Ltd. All rights reserved.
 * Copyright (c) 2015 System Fabric Works, Inc. All rights reserved.
 */

#include <linux/skbuff.h>
#include <linux/delay.h>
#include <linux/sched.h>
#include <linux/vmalloc.h>
#include <rdma/uverbs_ioctl.h>

#include "rxe.h"
#include "rxe_loc.h"
#include "rxe_queue.h"
#include "rxe_task.h"

static int rxe_qp_chk_cap(struct rxe_dev *rxe, struct ib_qp_cap *cap,
			  int has_srq)
{}

int rxe_qp_chk_init(struct rxe_dev *rxe, struct ib_qp_init_attr *init)
{}

static int alloc_rd_atomic_resources(struct rxe_qp *qp, unsigned int n)
{}

static void free_rd_atomic_resources(struct rxe_qp *qp)
{}

void free_rd_atomic_resource(struct resp_res *res)
{}

static void cleanup_rd_atomic_resources(struct rxe_qp *qp)
{}

static void rxe_qp_init_misc(struct rxe_dev *rxe, struct rxe_qp *qp,
			     struct ib_qp_init_attr *init)
{}

static int rxe_init_sq(struct rxe_qp *qp, struct ib_qp_init_attr *init,
		       struct ib_udata *udata,
		       struct rxe_create_qp_resp __user *uresp)
{}

static int rxe_qp_init_req(struct rxe_dev *rxe, struct rxe_qp *qp,
			   struct ib_qp_init_attr *init, struct ib_udata *udata,
			   struct rxe_create_qp_resp __user *uresp)
{}

static int rxe_init_rq(struct rxe_qp *qp, struct ib_qp_init_attr *init,
		       struct ib_udata *udata,
		       struct rxe_create_qp_resp __user *uresp)
{}

static int rxe_qp_init_resp(struct rxe_dev *rxe, struct rxe_qp *qp,
			    struct ib_qp_init_attr *init,
			    struct ib_udata *udata,
			    struct rxe_create_qp_resp __user *uresp)
{}

/* called by the create qp verb */
int rxe_qp_from_init(struct rxe_dev *rxe, struct rxe_qp *qp, struct rxe_pd *pd,
		     struct ib_qp_init_attr *init,
		     struct rxe_create_qp_resp __user *uresp,
		     struct ib_pd *ibpd,
		     struct ib_udata *udata)
{}

/* called by the query qp verb */
int rxe_qp_to_init(struct rxe_qp *qp, struct ib_qp_init_attr *init)
{}

int rxe_qp_chk_attr(struct rxe_dev *rxe, struct rxe_qp *qp,
		    struct ib_qp_attr *attr, int mask)
{}

/* move the qp to the reset state */
static void rxe_qp_reset(struct rxe_qp *qp)
{}

/* move the qp to the error state */
void rxe_qp_error(struct rxe_qp *qp)
{}

static void rxe_qp_sqd(struct rxe_qp *qp, struct ib_qp_attr *attr,
		       int mask)
{}

/* caller should hold qp->state_lock */
static int __qp_chk_state(struct rxe_qp *qp, struct ib_qp_attr *attr,
			    int mask)
{}

static const char *const qps2str[] =;

/* called by the modify qp verb */
int rxe_qp_from_attr(struct rxe_qp *qp, struct ib_qp_attr *attr, int mask,
		     struct ib_udata *udata)
{}

/* called by the query qp verb */
int rxe_qp_to_attr(struct rxe_qp *qp, struct ib_qp_attr *attr, int mask)
{}

int rxe_qp_chk_destroy(struct rxe_qp *qp)
{}

/* called when the last reference to the qp is dropped */
static void rxe_qp_do_cleanup(struct work_struct *work)
{}

/* called when the last reference to the qp is dropped */
void rxe_qp_cleanup(struct rxe_pool_elem *elem)
{}