#include <linux/rtnetlink.h>
#include <net/devlink.h>
#include "nfpcore/nfp.h"
#include "nfpcore/nfp_nsp.h"
#include "nfp_app.h"
#include "nfp_main.h"
#include "nfp_port.h"
static int
nfp_devlink_fill_eth_port(struct nfp_port *port,
struct nfp_eth_table_port *copy)
{ … }
static int
nfp_devlink_fill_eth_port_from_id(struct nfp_pf *pf,
struct devlink_port *dl_port,
struct nfp_eth_table_port *copy)
{ … }
static int
nfp_devlink_set_lanes(struct nfp_pf *pf, unsigned int idx, unsigned int lanes)
{ … }
static int
nfp_devlink_port_split(struct devlink *devlink, struct devlink_port *port,
unsigned int count, struct netlink_ext_ack *extack)
{ … }
static int
nfp_devlink_port_unsplit(struct devlink *devlink, struct devlink_port *port,
struct netlink_ext_ack *extack)
{ … }
static int
nfp_devlink_sb_pool_get(struct devlink *devlink, unsigned int sb_index,
u16 pool_index, struct devlink_sb_pool_info *pool_info)
{ … }
static int
nfp_devlink_sb_pool_set(struct devlink *devlink, unsigned int sb_index,
u16 pool_index,
u32 size, enum devlink_sb_threshold_type threshold_type,
struct netlink_ext_ack *extack)
{ … }
static int nfp_devlink_eswitch_mode_get(struct devlink *devlink, u16 *mode)
{ … }
static int nfp_devlink_eswitch_mode_set(struct devlink *devlink, u16 mode,
struct netlink_ext_ack *extack)
{ … }
static const struct nfp_devlink_versions_simple { … } nfp_devlink_versions_hwinfo[] = …;
static int
nfp_devlink_versions_get_hwinfo(struct nfp_pf *pf, struct devlink_info_req *req)
{ … }
static const struct nfp_devlink_versions { … } nfp_devlink_versions_nsp[] = …;
static int
nfp_devlink_versions_get_nsp(struct devlink_info_req *req, bool flash,
const u8 *buf, unsigned int size)
{ … }
static int
nfp_devlink_info_get(struct devlink *devlink, struct devlink_info_req *req,
struct netlink_ext_ack *extack)
{ … }
static int
nfp_devlink_flash_update(struct devlink *devlink,
struct devlink_flash_update_params *params,
struct netlink_ext_ack *extack)
{ … }
const struct devlink_ops nfp_devlink_ops = …;
static const struct devlink_port_ops nfp_devlink_port_ops = …;
int nfp_devlink_port_register(struct nfp_app *app, struct nfp_port *port)
{ … }
void nfp_devlink_port_unregister(struct nfp_port *port)
{ … }