linux/drivers/net/ethernet/mellanox/mlxfw/mlxfw.h

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

#ifndef _MLXFW_H
#define _MLXFW_H

#include <linux/firmware.h>
#include <linux/netlink.h>
#include <linux/device.h>
#include <net/devlink.h>

struct mlxfw_dev {};

static inline
struct device *mlxfw_dev_dev(struct mlxfw_dev *mlxfw_dev)
{}

#define MLXFW_PRFX

#define mlxfw_info(mlxfw_dev, fmt, ...)
#define mlxfw_err(mlxfw_dev, fmt, ...)
#define mlxfw_dbg(mlxfw_dev, fmt, ...)

enum mlxfw_fsm_state {};

enum mlxfw_fsm_state_err {};

enum mlxfw_fsm_reactivate_status {};

struct mlxfw_dev_ops {};

#if IS_REACHABLE(CONFIG_MLXFW)
int mlxfw_firmware_flash(struct mlxfw_dev *mlxfw_dev,
			 const struct firmware *firmware,
			 struct netlink_ext_ack *extack);
#else
static inline
int mlxfw_firmware_flash(struct mlxfw_dev *mlxfw_dev,
			 const struct firmware *firmware,
			 struct netlink_ext_ack *extack)
{
	return -EOPNOTSUPP;
}
#endif

#endif