History

IB/uverbs: Expose MPLS flow spec to the user-kernel ABI header

Add ib_uverbs_flow_spec_mpls to define a rule to match the MPLS protocol. The spec includes the generic specs header, type, size and reserved fields while the filter itself is defined as ib_uverbs_flow_mpls_filter and includes a single 32bit field named 'label' which consists of: Bits 0:19 - The MPLS label. Bits 20:22 - Traffic class field. Bit 23 - Bottom of stack bit. Bits 24:31 - Time to live (TTL) field.

Ariel Levkovich committed 8 years ago

Commit 0d86bbe1 parent d90e5e51 file · +23 −0Browse files

Showing the changes to include/uapi (1 of 1 file). Show all

Unified · Split

include/uapi/rdma/ib_user_verbs.h+23−0
@@ -1060,6 +1060,29 @@ struct ib_uverbs_flow_spec_gre { · 1059 unmodified lines
10601060 struct ib_uverbs_flow_gre_filter mask;
10611061 };
10621062
1063+struct ib_uverbs_flow_mpls_filter {
1064+ /* The field includes the entire MPLS label:
1065+ * bits 0:19 - label field.
1066+ * bits 20:22 - traffic class field.
1067+ * bits 23 - bottom of stack bit.
1068+ * bits 24:31 - ttl field.
1069+ */
1070+ __be32 label;
1071+};
1072+
1073+struct ib_uverbs_flow_spec_mpls {
1074+ union {
1075+ struct ib_uverbs_flow_spec_hdr hdr;
1076+ struct {
1077+ __u32 type;
1078+ __u16 size;
1079+ __u16 reserved;
1080+ };
1081+ };
1082+ struct ib_uverbs_flow_mpls_filter val;
1083+ struct ib_uverbs_flow_mpls_filter mask;
1084+};
1085+
10631086 struct ib_uverbs_flow_attr {
10641087 __u32 type;
10651088 __u16 size;

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