summaryrefslogtreecommitdiffstats
path: root/include/linux/mlx5/port.h
diff options
context:
space:
mode:
authorHuy Nguyen <huyn@mellanox.com>2017-07-18 16:08:46 -0500
committerSaeed Mahameed <saeedm@mellanox.com>2017-11-04 21:26:21 -0700
commit415a64aa8dc6b4fc478609c549ca652d95a12f13 (patch)
tree8c72645e9ebdf569a384cb60540c54d329895afa /include/linux/mlx5/port.h
parent71c70eb21c33c60433b95e72a59d40bb128db649 (diff)
downloadlinux-415a64aa8dc6b4fc478609c549ca652d95a12f13.tar.gz
linux-415a64aa8dc6b4fc478609c549ca652d95a12f13.tar.bz2
linux-415a64aa8dc6b4fc478609c549ca652d95a12f13.zip
net/mlx5: QPTS and QPDPM register firmware command support
The QPTS register allows changing the priority trust state between pcp and dscp. Add support to get/set trust state from device. When the port is in pcp/dscp trust state, packet is routed by hardware to matching priority based on its pcp/dscp value respectively. The QPDPM register allow channing the dscp to priority mapping. Add support to get/set dscp to priority mapping from device. Note that to change a dscp mapping, the "e" bit of this dscp structure must be set in the QPDPM firmware command. Signed-off-by: Huy Nguyen <huyn@mellanox.com> Reviewed-by: Parav Pandit <parav@mellanox.com> Reviewed-by: Or Gerlitz <ogerlitz@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Diffstat (limited to 'include/linux/mlx5/port.h')
-rw-r--r--include/linux/mlx5/port.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/mlx5/port.h b/include/linux/mlx5/port.h
index c59af8ab753a..035f0d4dc9fe 100644
--- a/include/linux/mlx5/port.h
+++ b/include/linux/mlx5/port.h
@@ -179,4 +179,9 @@ int mlx5_query_module_eeprom(struct mlx5_core_dev *dev,
int mlx5_query_port_dcbx_param(struct mlx5_core_dev *mdev, u32 *out);
int mlx5_set_port_dcbx_param(struct mlx5_core_dev *mdev, u32 *in);
+
+int mlx5_set_trust_state(struct mlx5_core_dev *mdev, u8 trust_state);
+int mlx5_query_trust_state(struct mlx5_core_dev *mdev, u8 *trust_state);
+int mlx5_set_dscp2prio(struct mlx5_core_dev *mdev, u8 dscp, u8 prio);
+int mlx5_query_dscp2prio(struct mlx5_core_dev *mdev, u8 *dscp2prio);
#endif /* __MLX5_PORT_H__ */