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-str-id;
import ieee802-dot1cb-stream-identification {
prefix cb-str-id;
}
import ieee802-dot1cb-stream-identification-types {
prefix cb-str-id-types;
}
import ietf-yang-types {
prefix yang;
}
import ietf-interfaces {
prefix if;
}
organization
"Institute of Electrical and Electronics Engineers";
contact
"WG-URL: http://ieee802.org/1/
WG-EMail: stds-802-1@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.
Augmentation to dot1cb-stream-identification-types module";
revision "2020-07-29" {
description
"Mask-and-match module revision based on identification-type
defined as an identity";
reference
"Clause 9.1.6 of IEEE Std 802.1CBdb Draft 1.0";
}
revision "2020-05-06" {
description
"Mask-and-match module revision based on identification-type
defined as an identity";
reference
"Clause 9.1.6 of IEEE Std 802.1CBdb Draft 0.6";
}
revision "2020-02-21" {
description
"Initial Mask-and-match augmentation version";
reference
"Clause 9.1.6 of IEEE Std 802.1CBdb Draft 0.5";
}
typedef uint48 {
type uint64 {
range "0..281474976710655";
}
description "48-bit unsigned integer.";
}
typedef msdu-mask-length-type {
type uint16 {
range "2..1024";
}
description
"unsigned integer between 2 and 1024";
}
identity mask-and-match-stream-identification {
base cb-str-id-types:strid-idty;
description
"Mask-and-match Stream Identification";
}
augment /cb-str-id:stream-identity-list/cb-str-id:parameters {
when
'derived-from-or-self(/cb-str-id:stream-identity-list/cb-str-id:identification-type, "mask-and-match-stream-identification")';
description
"Augmentation of the Stream identitification types defined in the
ieee802-dot1cb-stream-identification-types module with the
mask-and-match Stream identification type";
container mask-and-match-stream-identification {
description
"When instantiating an instance of the mask-and-match
identification function (6.8), the parameters in the
following subclauses replace the tsnStreamIdParameters
managed object (9.1.1.7).";
reference
"Clause 9.1.6 of IEEE Std 802.1CBdb Draft 1.0";
uses mask-and-match-stream-identification-group;
} // container mask-and-match-stream-identification
}
grouping mask-and-match-stream-identification-group {
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
"Clause 9.1.6 of IEEE Std 802.1CBdb Draft 1.0";
leaf destination-mac-mask {
type uint48;
mandatory true;
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
"Clause 9.1.6.1 of IEEE Std 802.1CBdb Draft 1.0";
}
leaf destination-mac-match {
when '../destination-mac-mask';
type uint48;
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
"Clause 9.1.6.2 of IEEE Std 802.1CBdb Draft 1.0";
}
leaf source-mac-mask {
type uint48;
mandatory true;
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
"Clause 9.1.6.3 of IEEE Std 802.1CBdb Draft 1.0";
}
leaf source-mac-match {
when '../source-mac-mask';
type uint48;
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
"Clause 9.1.6.4 of IEEE Std 802.1CBdb Draft 1.0";
}
leaf msdu-mask-max-length {
type msdu-mask-length-type;
mandatory true;
description
"variable defined for the specific Stream identity the
Mask-and-match Stream identification function’s instance is
applied to. It is defined as the minimum of
port-msdu-mask-max-length (9.4.1) over the list of ports
(9.1.1.2, 9.1.1.3, 9.1.1.4, 9.1.1.5) on which the instance of
the Mask-and-match Stream identification function is placed.
It is an integer value that specifies the maximum value of
msdu-mask-length in octets.
msdu-mask-max-length has a minimum value of 2.";
reference
"Clause 9.1.6.5 of IEEE Std 802.1CBdb Draft 1.0";
}
leaf msdu-mask-length {
type msdu-mask-length-type;
must ". <= ../msdu-mask-max-length" {
error-message
"The MSDU mask length must be less or equal
msdu-mask-max-length";
}
mandatory true;
description
"Integer value that specifies the length of msdu-mask in bytes.
It shall not exceed the value specified by
msdu-mask-max-length and has a minimum value of 2";
reference
"Clause 9.1.6.6 of IEEE Std 802.1CBdb Draft 1.0";
}
leaf msdu-mask {
type yang:hex-string {
length "2 .. 1024";
}
mandatory true;
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
"Clause 9.1.6.7 of IEEE Std 802.1CBdb Draft 1.0";
}
leaf msdu-match {
when '../msdu-mask';
type yang:hex-string {
length "2 .. 1024";
}
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
"Clause 9.1.6.8 of IEEE Std 802.1CBdb Draft 1.0";
}
} // grouping mask-and-match-stream-identification-group
list per-port-msdu-mask-max-length {
key "port-name";
description
"Table of the per-port maximum msdu mask lengthts";
reference
"Clause 9.4.1 of IEEE Std 802.1CBdb Draft 1.0";
leaf port-name {
type if:interface-ref;
description
"Identification of the port";
reference
"Clause 9.4.1 of IEEE Std 802.1CBdb Draft 1.0";
}
leaf port-msdu-mask-max-length {
type msdu-mask-length-type;
config false;
description
"read-only variable defined for each port the Mask-and-match
Stream identification function is to be ran on. It is an
integer value, in octets, that is used to determine the value
of msdu-mask-max-length (9.1.6.5).
port-msdu-mask-max-length has a minimum value of 2";
reference
"Clause 9.4.1 of IEEE Std 802.1CBdb Draft 1.0";
}
} // list per-port-msdu-mask-max-length
} // module ieee802-dot1cb-mask-and-match