module ieee802-dot1cb-mask-and-match { yang-version 1.1; namespace "urn:ieee:std:802.1CB:yang:ieee802-dot1cb-mask-and-match"; prefix dot1cb-mm-sid; import ieee802-dot1cb-stream-identification { prefix dot1cb-sid; } import ieee802-dot1cb-stream-identification-types { prefix dot1cb-sid-types; } import ieee802-types { prefix ieee802; } import ietf-interfaces { prefix if; } organization "Institute of Electrical and Electronics Engineers"; contact "WG-URL: http://ieee802.org/1/ WG-EMail: stds-802-1-l@ieee.org Contact: IEEE 802.1 Working Group Chair Postal: C/O IEEE 802.1 Working Group IEEE Standards Association 445 Hoes Lane Piscataway, NJ 08854 USA E-mail: stds-802-1-chairs@ieee.org"; description "Management objects that control the Mask-and-match Stream identification function from IEEE Std 802.1CBdb-2021. Augmentation to the ieee802-dot1cb-stream-identification module. This YANG data model conforms to the Network Management Datastore Architecture defined in RFC 8342. Copyright (C) IEEE (2022). This version of this YANG module is part of IEEE Std 802.1CBdb-2021; see the draft itself for full legal notices."; revision 2021-12-09 { description "Published as part of IEEE Std 802.1CBdb-2021. Initial version."; reference "IEEE Std 802.1CBdb-2021, Frame Replication and Elimination for Reliability - Extended Stream identification functions."; } typedef msdu-mask-match-hex-string { type string { pattern '[0-9a-fA-F]{2}(-[0-9a-fA-F]{2}){1,1983}'; } description "Hex string representing a series of 2 to 1984 octets, each separated by a '-' separator"; } typedef msdu-mask-length-type { type uint16 { range "2..1984"; } description "unsigned integer between 2 and 1984"; } identity mask-and-match-stream-identification { base dot1cb-sid-types:strid-idty; description "Mask-and-match Stream Identification"; } augment "/dot1cb-sid:stream-identity/dot1cb-sid:parameters" { description "Controlling parameters for the Mask-and-match Stream identification method"; container mask-and-match-stream-identification { description "When instantiating an instance of the Mask-and-match Stream identification function (6.8), the parameters in the following subclauses replace the tsnStreamIdParameters managed object (9.1.1.7)."; reference "9.1.6 of IEEE Std 802.1CBdb-2021"; container identification-type { config false; description "The identification type indicating the method used to identify packets belonging to the Stream. The identification type contains a type number and an Organizationally Unique Identifier (OUI) or Company ID (CID) to identify the organization defining the identification method."; reference "9.1.1.6 of IEEE Std 802.1CB-2017"; leaf type-number { type dot1cb-sid-types:stream-id-function; default "mask-and-match"; description "The Stream identification type used for the Mask-and-match Stream identification method."; reference "9.1.1.6 of IEEE Std 802.1CBdb-2021"; } leaf oui-cid { type string { pattern "[0-9A-F]{2}(-[0-9A-F]{2}){2}"; } default "00-80-C2"; description "The Organizationally Unique Identifier (OUI) or Company ID (CID) to identify the organization defining the identification method. For identification methods defined in IEEE Std 802.1CB-2017 the OUI/CID is always 00-80-C2."; reference "9.1.1.6 of IEEE Std 802.1CB-2017"; } } leaf destination-mac-mask { type ieee802:mac-address; description "Specifies a 48-bit mask. A bitwise AND operation is performed between destination-mac-mask and the destination_address_parameter passed by the ISS indication primitive to the Mask-and-match Stream identification function. The resulting 48-bit information is the masked destination_address that is used as input for the instance of the Mask-and-match Stream identification function. If destination-mac-mask has a value of 0, the destination-address parameter is ignored."; reference "9.1.6.1 of IEEE Std 802.1CBdb-2021"; } leaf destination-mac-match { when '../destination-mac-mask'; type ieee802:mac-address; description "Specifies the 48-bit value of the masked destination_address, to be matched by the instance of the Mask-and-match Stream identification function."; reference "9.1.6.2 of IEEE Std 802.1CBdb-2021"; } leaf source-mac-mask { type ieee802:mac-address; description "Specifies a 48-bit mask. A bitwise AND operation is performed between source-mac-mask and the source_address_parameter passed by the ISS indication primitive to the Mask-and-match Stream identification function. The resulting 48-bit information is the masked source_address that is used as input for the instance of the Mask-and-match Stream identification function. If source-mac-mask has a value of 0, the source-address parameter is ignored."; reference "9.1.6.3 of IEEE Std 802.1CBdb-2021"; } leaf source-mac-match { when '../source-mac-mask'; type ieee802:mac-address; description "Specifies the 48-bit value of the masked source_address, to be matched by the instance of the Mask-and-match Stream identification function."; reference "9.1.6.4 of IEEE Std 802.1CBdb-2021"; } leaf msdu-mask-length { type msdu-mask-length-type; description "Integer value that specifies the length, in octets, of tsnCpeMmIdMsduMask (9.1.6.6) and tsnCpeMmIdMsduMatch (9.1.6.7). The behavior of the Mask-and-match Stream identification function is undefined on any port where the value of tsnCpeMmIdMsduMaskLength exceeds the per-port mac_service_data_unit mask maximum length (9.4.1). tsnCpeMmIdMsduMaskLength has a minimum value of 2. If the length of the frame's mac_service_data_unit is shorter than tsnCpeMmIdMsduMaskLength, then the identification fails."; reference "9.1.6.5 of IEEE Std 802.1CBdb-2021"; } leaf msdu-mask { type msdu-mask-match-hex-string; description "Specifies a mask of msdu-mask-length bytes. A bitwise AND operation is performed between the msdu-mask-length first bytes of the mac_service_data_unit parameter passed by the ISS indication primitive to the Mask-and-match Stream identification function. The resulting 'msdu-mask-length'-byte information is the masked mac_service_data_unit that is used as input for the instance of the Mask-and-match Stream identification function. If msdu-mask has a value of 0, the mac-service-data-unit parameter is ignored."; reference "9.1.6.6 of IEEE Std 802.1CBdb-2021"; } leaf msdu-match { when '../msdu-mask'; type msdu-mask-match-hex-string; description "Specifies the 'msdu-mask-length'-byte value of the masked mac_service_data_unit to be matched by the instance of the Mask-and-match Stream identification function"; reference "9.1.6.7 of IEEE Std 802.1CBdb-2021"; } } } list per-port-msdu-mask-max-length { key "port-name"; description "Table of the per-port maximum msdu mask lengths"; reference "9.4.1 of IEEE Std 802.1CBdb-2021"; leaf port-name { type if:interface-ref; description "Identification of the port"; reference "9.4.1 of IEEE Std 802.1CBdb-2021"; } leaf port-msdu-mask-max-length { type msdu-mask-length-type; config false; description "tsnPpMmIdMsduMaskMaxLength is a read-only variable defined for each port the Mask-and-match Stream identification function is to be ran on. It defines the maximum length a mac_service_data_unit mask can have. It is an integer value, in octets, with a minimum value of 2."; reference "9.4.1 of IEEE Std 802.1CBdb-2021"; } } }