linux/drivers/net/ethernet/freescale/dpaa2/dpsw-cmd.h

/* SPDX-License-Identifier: GPL-2.0 */
/*
 * Copyright 2014-2016 Freescale Semiconductor Inc.
 * Copyright 2017-2021 NXP
 *
 */

#ifndef __FSL_DPSW_CMD_H
#define __FSL_DPSW_CMD_H

#include "dpsw.h"

/* DPSW Version */
#define DPSW_VER_MAJOR
#define DPSW_VER_MINOR

#define DPSW_CMD_BASE_VERSION
#define DPSW_CMD_VERSION_2
#define DPSW_CMD_ID_OFFSET

#define DPSW_CMD_ID(id)
#define DPSW_CMD_V2(id)

/* Command IDs */
#define DPSW_CMDID_CLOSE
#define DPSW_CMDID_OPEN

#define DPSW_CMDID_GET_API_VERSION

#define DPSW_CMDID_ENABLE
#define DPSW_CMDID_DISABLE
#define DPSW_CMDID_GET_ATTR
#define DPSW_CMDID_RESET

#define DPSW_CMDID_SET_IRQ_ENABLE

#define DPSW_CMDID_SET_IRQ_MASK

#define DPSW_CMDID_GET_IRQ_STATUS
#define DPSW_CMDID_CLEAR_IRQ_STATUS

#define DPSW_CMDID_SET_REFLECTION_IF

#define DPSW_CMDID_IF_SET_TCI
#define DPSW_CMDID_IF_SET_STP

#define DPSW_CMDID_IF_GET_COUNTER

#define DPSW_CMDID_IF_ADD_REFLECTION
#define DPSW_CMDID_IF_REMOVE_REFLECTION

#define DPSW_CMDID_IF_ENABLE
#define DPSW_CMDID_IF_DISABLE

#define DPSW_CMDID_IF_GET_ATTR

#define DPSW_CMDID_IF_SET_MAX_FRAME_LENGTH

#define DPSW_CMDID_IF_GET_LINK_STATE

#define DPSW_CMDID_IF_GET_TCI

#define DPSW_CMDID_IF_SET_LINK_CFG

#define DPSW_CMDID_VLAN_ADD
#define DPSW_CMDID_VLAN_ADD_IF
#define DPSW_CMDID_VLAN_ADD_IF_UNTAGGED

#define DPSW_CMDID_VLAN_REMOVE_IF
#define DPSW_CMDID_VLAN_REMOVE_IF_UNTAGGED
#define DPSW_CMDID_VLAN_REMOVE_IF_FLOODING
#define DPSW_CMDID_VLAN_REMOVE

#define DPSW_CMDID_FDB_ADD
#define DPSW_CMDID_FDB_REMOVE
#define DPSW_CMDID_FDB_ADD_UNICAST
#define DPSW_CMDID_FDB_REMOVE_UNICAST
#define DPSW_CMDID_FDB_ADD_MULTICAST
#define DPSW_CMDID_FDB_REMOVE_MULTICAST
#define DPSW_CMDID_FDB_DUMP

#define DPSW_CMDID_ACL_ADD
#define DPSW_CMDID_ACL_REMOVE
#define DPSW_CMDID_ACL_ADD_ENTRY
#define DPSW_CMDID_ACL_REMOVE_ENTRY
#define DPSW_CMDID_ACL_ADD_IF
#define DPSW_CMDID_ACL_REMOVE_IF

#define DPSW_CMDID_IF_GET_PORT_MAC_ADDR

#define DPSW_CMDID_CTRL_IF_GET_ATTR
#define DPSW_CMDID_CTRL_IF_SET_POOLS
#define DPSW_CMDID_CTRL_IF_ENABLE
#define DPSW_CMDID_CTRL_IF_DISABLE
#define DPSW_CMDID_CTRL_IF_SET_QUEUE

#define DPSW_CMDID_SET_EGRESS_FLOOD
#define DPSW_CMDID_IF_SET_LEARNING_MODE

/* Macros for accessing command fields smaller than 1byte */
#define DPSW_MASK(field)
#define dpsw_set_field(var, field, val)
#define dpsw_get_field(var, field)
#define dpsw_get_bit(var, bit)

#pragma pack(push, 1)
struct dpsw_cmd_open {};

#define DPSW_COMPONENT_TYPE_SHIFT
#define DPSW_COMPONENT_TYPE_SIZE

struct dpsw_cmd_create {};

struct dpsw_cmd_destroy {};

#define DPSW_ENABLE_SHIFT
#define DPSW_ENABLE_SIZE

struct dpsw_rsp_is_enabled {};

struct dpsw_cmd_set_irq_enable {};

struct dpsw_cmd_get_irq_enable {};

struct dpsw_rsp_get_irq_enable {};

struct dpsw_cmd_set_irq_mask {};

struct dpsw_cmd_get_irq_mask {};

struct dpsw_rsp_get_irq_mask {};

struct dpsw_cmd_get_irq_status {};

struct dpsw_rsp_get_irq_status {};

struct dpsw_cmd_clear_irq_status {};

#define DPSW_COMPONENT_TYPE_SHIFT
#define DPSW_COMPONENT_TYPE_SIZE

#define DPSW_FLOODING_CFG_SHIFT
#define DPSW_FLOODING_CFG_SIZE

#define DPSW_BROADCAST_CFG_SHIFT
#define DPSW_BROADCAST_CFG_SIZE

struct dpsw_rsp_get_attr {};

#define DPSW_VLAN_ID_SHIFT
#define DPSW_VLAN_ID_SIZE
#define DPSW_DEI_SHIFT
#define DPSW_DEI_SIZE
#define DPSW_PCP_SHIFT
#define DPSW_PCP_SIZE

struct dpsw_cmd_if_set_tci {};

struct dpsw_cmd_if_get_tci {};

struct dpsw_rsp_if_get_tci {};

#define DPSW_STATE_SHIFT
#define DPSW_STATE_SIZE

struct dpsw_cmd_if_set_stp {};

#define DPSW_COUNTER_TYPE_SHIFT
#define DPSW_COUNTER_TYPE_SIZE

struct dpsw_cmd_if_get_counter {};

struct dpsw_rsp_if_get_counter {};

struct dpsw_cmd_if {};

#define DPSW_ADMIT_UNTAGGED_SHIFT
#define DPSW_ADMIT_UNTAGGED_SIZE
#define DPSW_ENABLED_SHIFT
#define DPSW_ENABLED_SIZE
#define DPSW_ACCEPT_ALL_VLAN_SHIFT
#define DPSW_ACCEPT_ALL_VLAN_SIZE

struct dpsw_rsp_if_get_attr {};

struct dpsw_cmd_if_set_max_frame_length {};

struct dpsw_cmd_if_set_link_cfg {};

struct dpsw_cmd_if_get_link_state {};

#define DPSW_UP_SHIFT
#define DPSW_UP_SIZE

struct dpsw_rsp_if_get_link_state {};

struct dpsw_vlan_add {};

struct dpsw_cmd_vlan_add_if {};

struct dpsw_cmd_vlan_manage_if {};

struct dpsw_cmd_vlan_remove {};

struct dpsw_cmd_fdb_add {};

struct dpsw_rsp_fdb_add {};

struct dpsw_cmd_fdb_remove {};

#define DPSW_ENTRY_TYPE_SHIFT
#define DPSW_ENTRY_TYPE_SIZE

struct dpsw_cmd_fdb_unicast_op {};

struct dpsw_cmd_fdb_multicast_op {};

struct dpsw_cmd_fdb_dump {};

struct dpsw_rsp_fdb_dump {};

struct dpsw_rsp_ctrl_if_get_attr {};

#define DPSW_BACKUP_POOL(val, order)
struct dpsw_cmd_ctrl_if_set_pools {};

#define DPSW_DEST_TYPE_SHIFT
#define DPSW_DEST_TYPE_SIZE

struct dpsw_cmd_ctrl_if_set_queue {};

struct dpsw_rsp_get_api_version {};

struct dpsw_rsp_if_get_mac_addr {};

struct dpsw_cmd_set_egress_flood {};

#define DPSW_LEARNING_MODE_SHIFT
#define DPSW_LEARNING_MODE_SIZE

struct dpsw_cmd_if_set_learning_mode {};

struct dpsw_cmd_acl_add {};

struct dpsw_rsp_acl_add {};

struct dpsw_cmd_acl_remove {};

struct dpsw_cmd_acl_if {};

struct dpsw_prep_acl_entry {};

#define DPSW_RESULT_ACTION_SHIFT
#define DPSW_RESULT_ACTION_SIZE

struct dpsw_cmd_acl_entry {};

struct dpsw_cmd_set_reflection_if {};

#define DPSW_FILTER_SHIFT
#define DPSW_FILTER_SIZE

struct dpsw_cmd_if_reflection {};
#pragma pack(pop)
#endif /* __FSL_DPSW_CMD_H */