linux/drivers/net/netdevsim/health.c

// SPDX-License-Identifier: GPL-2.0
/* Copyright (c) 2019 Mellanox Technologies. All rights reserved */

#include <linux/debugfs.h>
#include <linux/err.h>
#include <linux/kernel.h>
#include <linux/slab.h>

#include "netdevsim.h"

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

static int
nsim_dev_empty_reporter_diagnose(struct devlink_health_reporter *reporter,
				 struct devlink_fmsg *fmsg,
				 struct netlink_ext_ack *extack)
{}

static const
struct devlink_health_reporter_ops nsim_dev_empty_reporter_ops =;

struct nsim_dev_dummy_reporter_ctx {};

static int
nsim_dev_dummy_reporter_recover(struct devlink_health_reporter *reporter,
				void *priv_ctx,
				struct netlink_ext_ack *extack)
{}

static int nsim_dev_dummy_fmsg_put(struct devlink_fmsg *fmsg, u32 binary_len)
{}

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

static int
nsim_dev_dummy_reporter_diagnose(struct devlink_health_reporter *reporter,
				 struct devlink_fmsg *fmsg,
				 struct netlink_ext_ack *extack)
{}

static const
struct devlink_health_reporter_ops nsim_dev_dummy_reporter_ops =;

static ssize_t nsim_dev_health_break_write(struct file *file,
					   const char __user *data,
					   size_t count, loff_t *ppos)
{}

static const struct file_operations nsim_dev_health_break_fops =;

int nsim_dev_health_init(struct nsim_dev *nsim_dev, struct devlink *devlink)
{}

void nsim_dev_health_exit(struct nsim_dev *nsim_dev)
{}