linux/drivers/net/ethernet/microchip/sparx5/sparx5_dcb.c

// SPDX-License-Identifier: GPL-2.0+
/* Microchip Sparx5 Switch driver
 *
 * Copyright (c) 2022 Microchip Technology Inc. and its subsidiaries.
 */

#include <net/dcbnl.h>

#include "sparx5_port.h"

enum sparx5_dcb_apptrust_values {};

static const struct sparx5_dcb_apptrust {} *sparx5_port_apptrust[SPX5_PORTS];

static const char *sparx5_dcb_apptrust_names[__SPARX5_DCB_APPTRUST_MAX] =;

/* Sparx5 supported apptrust policies */
static const struct sparx5_dcb_apptrust
	sparx5_dcb_apptrust_policies[__SPARX5_DCB_APPTRUST_MAX] =;

/* Validate app entry.
 *
 * Check for valid selectors and valid protocol and priority ranges.
 */
static int sparx5_dcb_app_validate(struct net_device *dev,
				   const struct dcb_app *app)
{}

/* Validate apptrust configuration.
 *
 * Return index of supported apptrust configuration if valid, otherwise return
 * error.
 */
static int sparx5_dcb_apptrust_validate(struct net_device *dev, u8 *selectors,
					int nselectors, int *err)
{}

static bool sparx5_dcb_apptrust_contains(int portno, u8 selector)
{}

static int sparx5_dcb_app_update(struct net_device *dev)
{}

/* Set or delete DSCP app entry.
 *
 * DSCP mapping is global for all ports, so set and delete app entries are
 * replicated for each port.
 */
static int sparx5_dcb_ieee_dscp_setdel(struct net_device *dev,
				       struct dcb_app *app,
				       int (*setdel)(struct net_device *,
						     struct dcb_app *))
{}

static int sparx5_dcb_ieee_delapp(struct net_device *dev, struct dcb_app *app)
{}

static int sparx5_dcb_ieee_setapp(struct net_device *dev, struct dcb_app *app)
{}

static int sparx5_dcb_setapptrust(struct net_device *dev, u8 *selectors,
				  int nselectors)
{}

static int sparx5_dcb_getapptrust(struct net_device *dev, u8 *selectors,
				  int *nselectors)
{}

static int sparx5_dcb_delrewr(struct net_device *dev, struct dcb_app *app)
{}

static int sparx5_dcb_setrewr(struct net_device *dev, struct dcb_app *app)
{}

const struct dcbnl_rtnl_ops sparx5_dcbnl_ops =;

int sparx5_dcb_init(struct sparx5 *sparx5)
{}