linux/drivers/net/ethernet/huawei/hinic/hinic_devlink.c

// SPDX-License-Identifier: GPL-2.0
/* Huawei HiNIC PCI Express Linux driver
 * Copyright(c) 2017 Huawei Technologies Co., Ltd
 *
 * This program is free software; you can redistribute it and/or modify it
 * under the terms and conditions of the GNU General Public License,
 * version 2, as published by the Free Software Foundation.
 *
 * This program is distributed in the hope it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 * for more details.
 *
 */
#include <linux/netlink.h>
#include <net/devlink.h>
#include <linux/firmware.h>

#include "hinic_port.h"
#include "hinic_devlink.h"
#include "hinic_hw_dev.h"

static bool check_image_valid(struct hinic_devlink_priv *priv, const u8 *buf,
			      u32 image_size, struct host_image_st *host_image)
{}

static bool check_image_integrity(struct hinic_devlink_priv *priv,
				  struct host_image_st *host_image,
				  u32 update_type)
{}

static int check_image_device_type(struct hinic_devlink_priv *priv,
				   u32 image_device_type)
{}

static int hinic_flash_fw(struct hinic_devlink_priv *priv, const u8 *data,
			  struct host_image_st *host_image)
{}

static int hinic_firmware_update(struct hinic_devlink_priv *priv,
				 const struct firmware *fw,
				 struct netlink_ext_ack *extack)
{}

static int hinic_devlink_flash_update(struct devlink *devlink,
				      struct devlink_flash_update_params *params,
				      struct netlink_ext_ack *extack)
{}

static const struct devlink_ops hinic_devlink_ops =;

struct devlink *hinic_devlink_alloc(struct device *dev)
{}

void hinic_devlink_free(struct devlink *devlink)
{}

void hinic_devlink_register(struct hinic_devlink_priv *priv)
{}

void hinic_devlink_unregister(struct hinic_devlink_priv *priv)
{}

static void chip_fault_show(struct devlink_fmsg *fmsg,
			    struct hinic_fault_event *event)
{}

static void fault_report_show(struct devlink_fmsg *fmsg,
			      struct hinic_fault_event *event)
{}

static int hinic_hw_reporter_dump(struct devlink_health_reporter *reporter,
				  struct devlink_fmsg *fmsg, void *priv_ctx,
				  struct netlink_ext_ack *extack)
{}

static void mgmt_watchdog_report_show(struct devlink_fmsg *fmsg,
				      struct hinic_mgmt_watchdog_info *winfo)
{}

static int hinic_fw_reporter_dump(struct devlink_health_reporter *reporter,
				  struct devlink_fmsg *fmsg, void *priv_ctx,
				  struct netlink_ext_ack *extack)
{}

static const struct devlink_health_reporter_ops hinic_hw_fault_reporter_ops =;

static const struct devlink_health_reporter_ops hinic_fw_fault_reporter_ops =;

int hinic_health_reporters_create(struct hinic_devlink_priv *priv)
{}

void hinic_health_reporters_destroy(struct hinic_devlink_priv *priv)
{}