linux/drivers/net/ethernet/netronome/nfp/devlink_param.c

// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
/* Copyright (C) 2019 Netronome Systems, Inc. */

#include <net/devlink.h>

#include "nfpcore/nfp.h"
#include "nfpcore/nfp_nsp.h"
#include "nfp_main.h"

/**
 * struct nfp_devlink_param_u8_arg - Devlink u8 parameter get/set arguments
 * @hwinfo_name:	HWinfo key name
 * @default_hi_val:	Default HWinfo value if HWinfo doesn't exist
 * @invalid_dl_val:	Devlink value to use if HWinfo is unknown/invalid.
 *			-errno if there is no unknown/invalid value available
 * @hi_to_dl:	HWinfo to devlink value mapping
 * @dl_to_hi:	Devlink to hwinfo value mapping
 * @max_dl_val:	Maximum devlink value supported, for validation only
 * @max_hi_val:	Maximum HWinfo value supported, for validation only
 */
struct nfp_devlink_param_u8_arg {};

static const struct nfp_devlink_param_u8_arg nfp_devlink_u8_args[] =;

static int
nfp_devlink_param_u8_get(struct devlink *devlink, u32 id,
			 struct devlink_param_gset_ctx *ctx)
{}

static int
nfp_devlink_param_u8_set(struct devlink *devlink, u32 id,
			 struct devlink_param_gset_ctx *ctx,
			 struct netlink_ext_ack *extack)
{}

static int
nfp_devlink_param_u8_validate(struct devlink *devlink, u32 id,
			      union devlink_param_value val,
			      struct netlink_ext_ack *extack)
{}

static const struct devlink_param nfp_devlink_params[] =;

static int nfp_devlink_supports_params(struct nfp_pf *pf)
{}

int nfp_devlink_params_register(struct nfp_pf *pf)
{}

void nfp_devlink_params_unregister(struct nfp_pf *pf)
{}