History

net/mlx5: Add flow counter bulk allocation hardware bits and command

Add a handle to invoke the new FW capability of allocating a bulk of flow counters.

Gavi Teitz committed 7 years ago

Commit 8536a6b1 parent 6f06e043 files · +31 −3Browse files

Showing the changes to include/linux (1 of 3 files). Show all

Unified · Split

include/linux/mlx5/mlx5_ifc.h+19−2
@@ -1040,6 +1040,21 @@ enum { · 1039 unmodified lines
10401040 MLX5_UCTX_CAP_INTERNAL_DEV_RES = 1UL << 1,
10411041 };
10421042
1043+#define MLX5_FC_BULK_SIZE_FACTOR 128
1044+
1045+enum mlx5_fc_bulk_alloc_bitmask {
1046+ MLX5_FC_BULK_128 = (1 << 0),
1047+ MLX5_FC_BULK_256 = (1 << 1),
1048+ MLX5_FC_BULK_512 = (1 << 2),
1049+ MLX5_FC_BULK_1024 = (1 << 3),
1050+ MLX5_FC_BULK_2048 = (1 << 4),
1051+ MLX5_FC_BULK_4096 = (1 << 5),
1052+ MLX5_FC_BULK_8192 = (1 << 6),
1053+ MLX5_FC_BULK_16384 = (1 << 7),
1054+};
1055+
1056+#define MLX5_FC_BULK_NUM_FCS(fc_enum) (MLX5_FC_BULK_SIZE_FACTOR * (fc_enum))
1057+
10431058 struct mlx5_ifc_cmd_hca_cap_bits {
10441059 u8 reserved_at_0[0x30];
10451060 u8 vhca_id[0x10];
@@ -1244,7 +1259,8 @@ struct mlx5_ifc_cmd_hca_cap_bits { · 198 unmodified lines
12441259 u8 reserved_at_2e0[0x7];
12451260 u8 max_qp_mcg[0x19];
12461261
1247− u8 reserved_at_300[0x18];
1262+ u8 reserved_at_300[0x10];
1263+ u8 flow_counter_bulk_alloc[0x8];
12481264 u8 log_max_mcg[0x8];
12491265
12501266 u8 reserved_at_320[0x3];
@@ -7815,7 +7831,8 @@ struct mlx5_ifc_alloc_flow_counter_in_bits { · 6564 unmodified lines
78157831 u8 reserved_at_20[0x10];
78167832 u8 op_mod[0x10];
78177833
7818− u8 reserved_at_40[0x40];
7834+ u8 reserved_at_40[0x38];
7835+ u8 flow_counter_bulk[0x8];
78197836 };
78207837
78217838 struct mlx5_ifc_add_vxlan_udp_dport_out_bits {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t