aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mlx4/device.h
diff options
context:
space:
mode:
authorHadar Hen Zion <hadarh@mellanox.com>2015-07-27 07:46:31 -0400
committerDavid S. Miller <davem@davemloft.net>2015-07-27 18:00:36 -0400
commit77fc29c4bbbbd01ee22c50ce8260fd0f2e08c124 (patch)
tree2f82cc8116136695d0301745223e22ea8ca7ae2b /include/linux/mlx4/device.h
parent0b42c2863b3b9f79c42f0b877249007e5adfc921 (diff)
net/mlx4_core: Preparations for 802.1ad VLAN support
mlx4_core preparation to support hardware accelerated 802.1ad VLAN device. To allow 802.1ad accelerated device, "packet has vlan" (phv) Firmware capability should be available. Firmware without the phv capability won't behave properly and can't support 802.1ad device acceleration. The driver checks the Firmware capability and sets the phv bit accordingly in SET_PORT command. Signed-off-by: Hadar Hen Zion <hadarh@mellanox.com> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/mlx4/device.h')
-rw-r--r--include/linux/mlx4/device.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/mlx4/device.h b/include/linux/mlx4/device.h
index fd13c1ce3b4a..bcbf8c72a77b 100644
--- a/include/linux/mlx4/device.h
+++ b/include/linux/mlx4/device.h
@@ -211,6 +211,8 @@ enum {
211 MLX4_DEV_CAP_FLAG2_ETS_CFG = 1LL << 26, 211 MLX4_DEV_CAP_FLAG2_ETS_CFG = 1LL << 26,
212 MLX4_DEV_CAP_FLAG2_PORT_BEACON = 1LL << 27, 212 MLX4_DEV_CAP_FLAG2_PORT_BEACON = 1LL << 27,
213 MLX4_DEV_CAP_FLAG2_IGNORE_FCS = 1LL << 28, 213 MLX4_DEV_CAP_FLAG2_IGNORE_FCS = 1LL << 28,
214 MLX4_DEV_CAP_FLAG2_PHV_EN = 1LL << 29,
215 MLX4_DEV_CAP_FLAG2_SKIP_OUTER_VLAN = 1LL << 30,
214}; 216};
215 217
216enum { 218enum {
@@ -581,6 +583,7 @@ struct mlx4_caps {
581 u64 phys_port_id[MLX4_MAX_PORTS + 1]; 583 u64 phys_port_id[MLX4_MAX_PORTS + 1];
582 int tunnel_offload_mode; 584 int tunnel_offload_mode;
583 u8 rx_checksum_flags_port[MLX4_MAX_PORTS + 1]; 585 u8 rx_checksum_flags_port[MLX4_MAX_PORTS + 1];
586 u8 phv_bit[MLX4_MAX_PORTS + 1];
584 u8 alloc_res_qp_mask; 587 u8 alloc_res_qp_mask;
585 u32 dmfs_high_rate_qpn_base; 588 u32 dmfs_high_rate_qpn_base;
586 u32 dmfs_high_rate_qpn_range; 589 u32 dmfs_high_rate_qpn_range;
@@ -1332,6 +1335,8 @@ int mlx4_SET_PORT_BEACON(struct mlx4_dev *dev, u8 port, u16 time);
1332int mlx4_SET_PORT_fcs_check(struct mlx4_dev *dev, u8 port, 1335int mlx4_SET_PORT_fcs_check(struct mlx4_dev *dev, u8 port,
1333 u8 ignore_fcs_value); 1336 u8 ignore_fcs_value);
1334int mlx4_SET_PORT_VXLAN(struct mlx4_dev *dev, u8 port, u8 steering, int enable); 1337int mlx4_SET_PORT_VXLAN(struct mlx4_dev *dev, u8 port, u8 steering, int enable);
1338int set_phv_bit(struct mlx4_dev *dev, u8 port, int new_val);
1339int get_phv_bit(struct mlx4_dev *dev, u8 port, int *phv);
1335int mlx4_find_cached_mac(struct mlx4_dev *dev, u8 port, u64 mac, int *idx); 1340int mlx4_find_cached_mac(struct mlx4_dev *dev, u8 port, u64 mac, int *idx);
1336int mlx4_find_cached_vlan(struct mlx4_dev *dev, u8 port, u16 vid, int *idx); 1341int mlx4_find_cached_vlan(struct mlx4_dev *dev, u8 port, u16 vid, int *idx);
1337int mlx4_register_vlan(struct mlx4_dev *dev, u8 port, u16 vlan, int *index); 1342int mlx4_register_vlan(struct mlx4_dev *dev, u8 port, u16 vlan, int *index);