linux/drivers/infiniband/hw/hns/hns_roce_main.c

/*
 * Copyright (c) 2016 Hisilicon Limited.
 * Copyright (c) 2007, 2008 Mellanox Technologies. All rights reserved.
 *
 * This software is available to you under a choice of one of two
 * licenses.  You may choose to be licensed under the terms of the GNU
 * General Public License (GPL) Version 2, available from the file
 * COPYING in the main directory of this source tree, or the
 * OpenIB.org BSD license below:
 *
 *     Redistribution and use in source and binary forms, with or
 *     without modification, are permitted provided that the following
 *     conditions are met:
 *
 *      - Redistributions of source code must retain the above
 *        copyright notice, this list of conditions and the following
 *        disclaimer.
 *
 *      - Redistributions in binary form must reproduce the above
 *        copyright notice, this list of conditions and the following
 *        disclaimer in the documentation and/or other materials
 *        provided with the distribution.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
 * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
 * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 * SOFTWARE.
 */
#include <linux/acpi.h>
#include <linux/module.h>
#include <linux/pci.h>
#include <rdma/ib_addr.h>
#include <rdma/ib_smi.h>
#include <rdma/ib_user_verbs.h>
#include <rdma/ib_cache.h>
#include "hnae3.h"
#include "hns_roce_common.h"
#include "hns_roce_device.h"
#include "hns_roce_hem.h"
#include "hns_roce_hw_v2.h"

static int hns_roce_set_mac(struct hns_roce_dev *hr_dev, u32 port,
			    const u8 *addr)
{}

static int hns_roce_add_gid(const struct ib_gid_attr *attr, void **context)
{}

static int hns_roce_del_gid(const struct ib_gid_attr *attr, void **context)
{}

static int handle_en_event(struct hns_roce_dev *hr_dev, u32 port,
			   unsigned long event)
{}

static int hns_roce_netdev_event(struct notifier_block *self,
				 unsigned long event, void *ptr)
{}

static int hns_roce_setup_mtu_mac(struct hns_roce_dev *hr_dev)
{}

static int hns_roce_query_device(struct ib_device *ib_dev,
				 struct ib_device_attr *props,
				 struct ib_udata *uhw)
{}

static int hns_roce_query_port(struct ib_device *ib_dev, u32 port_num,
			       struct ib_port_attr *props)
{}

static enum rdma_link_layer hns_roce_get_link_layer(struct ib_device *device,
						    u32 port_num)
{}

static int hns_roce_query_pkey(struct ib_device *ib_dev, u32 port, u16 index,
			       u16 *pkey)
{}

static int hns_roce_modify_device(struct ib_device *ib_dev, int mask,
				  struct ib_device_modify *props)
{}

struct hns_user_mmap_entry *
hns_roce_user_mmap_entry_insert(struct ib_ucontext *ucontext, u64 address,
				size_t length,
				enum hns_roce_mmap_type mmap_type)
{}

static void hns_roce_dealloc_uar_entry(struct hns_roce_ucontext *context)
{}

static int hns_roce_alloc_uar_entry(struct ib_ucontext *uctx)
{}

static int hns_roce_alloc_ucontext(struct ib_ucontext *uctx,
				   struct ib_udata *udata)
{}

static void hns_roce_dealloc_ucontext(struct ib_ucontext *ibcontext)
{}

static int hns_roce_mmap(struct ib_ucontext *uctx, struct vm_area_struct *vma)
{}

static void hns_roce_free_mmap(struct rdma_user_mmap_entry *rdma_entry)
{}

static int hns_roce_port_immutable(struct ib_device *ib_dev, u32 port_num,
				   struct ib_port_immutable *immutable)
{}

static void hns_roce_disassociate_ucontext(struct ib_ucontext *ibcontext)
{}

static void hns_roce_get_fw_ver(struct ib_device *device, char *str)
{}

#define HNS_ROCE_HW_CNT(ename, cname)

static const struct rdma_stat_desc hns_roce_port_stats_descs[] =;

static struct rdma_hw_stats *hns_roce_alloc_hw_port_stats(
				struct ib_device *device, u32 port_num)
{}

static int hns_roce_get_hw_stats(struct ib_device *device,
				 struct rdma_hw_stats *stats,
				 u32 port, int index)
{}

static void hns_roce_unregister_device(struct hns_roce_dev *hr_dev)
{}

static const struct ib_device_ops hns_roce_dev_ops =;

static const struct ib_device_ops hns_roce_dev_hw_stats_ops =;

static const struct ib_device_ops hns_roce_dev_mr_ops =;

static const struct ib_device_ops hns_roce_dev_mw_ops =;

static const struct ib_device_ops hns_roce_dev_frmr_ops =;

static const struct ib_device_ops hns_roce_dev_srq_ops =;

static const struct ib_device_ops hns_roce_dev_xrcd_ops =;

static const struct ib_device_ops hns_roce_dev_restrack_ops =;

static int hns_roce_register_device(struct hns_roce_dev *hr_dev)
{}

static int hns_roce_init_hem(struct hns_roce_dev *hr_dev)
{}

static void hns_roce_teardown_hca(struct hns_roce_dev *hr_dev)
{}

/**
 * hns_roce_setup_hca - setup host channel adapter
 * @hr_dev: pointer to hns roce device
 * Return : int
 */
static int hns_roce_setup_hca(struct hns_roce_dev *hr_dev)
{}

static void check_and_get_armed_cq(struct list_head *cq_list, struct ib_cq *cq)
{}

void hns_roce_handle_device_err(struct hns_roce_dev *hr_dev)
{}

static int hns_roce_alloc_dfx_cnt(struct hns_roce_dev *hr_dev)
{}

static void hns_roce_dealloc_dfx_cnt(struct hns_roce_dev *hr_dev)
{}

int hns_roce_init(struct hns_roce_dev *hr_dev)
{}

void hns_roce_exit(struct hns_roce_dev *hr_dev)
{}

MODULE_LICENSE();
MODULE_AUTHOR();
MODULE_AUTHOR();
MODULE_AUTHOR();
MODULE_DESCRIPTION();