cisco-bridge-domain

This YANG module describes the configuration and operational model for bridge domain. Terms and Acronyms AC : Attachment Circ...

  • Version: 2019-07-01

    cisco-bridge-domain@2019-07-01


    
      module cisco-bridge-domain {
    
        yang-version 1;
    
        namespace
          "urn:cisco:params:xml:ns:yang:cisco-bridge-domain";
    
        prefix bd;
    
        import cisco-semver {
          prefix cisco-semver;
        }
        import ietf-interfaces {
          prefix if;
        }
        import ietf-yang-types {
          prefix yang;
        }
        import cisco-bridge-common {
          prefix cbridge;
        }
        import cisco-storm-control {
          prefix cstormctrl;
        }
        import cisco-pw {
          prefix l2vpn-pw;
        }
    
        organization "Cisco Systems, Inc.";
    
        contact
          "Cisco Systems, Inc.
    Customer Service
    
    Postal: 170 W Tasman Drive
    San Jose, CA 95134
    
    Tel: +1 1800 553-NETS
    
    E-mail: cs-yang@cisco.com";
    
        description
          "This YANG module describes the configuration and operational
    model for bridge domain.
    
    Terms and Acronyms
      AC : Attachment Circuits
    
      BD : Bridge Domain
    
      BCB : Backbone Core Bridge
    
      BEB : Backbone Edge Bridge
    
      B-MAC : Backbone MAC Address
    
      CE : Customer Edge
    
      C-MAC : Customer/Client MAC Address
    
      DHCP : Dynamic Host Configuration Protocol
    
      DAI : Dynamic ARP Inspection
    
      EVC : Ethernet Virtual Circuit
    
      IGMP : Internet Group Management Protocol
    
      IPSG : IP Source Guard
    
      L2VPN : Layer 2 Virtual Private Network
    
      MLD : Multicast Listener Discovery
    
      PBB : Provider Backbone Bridge
    
      VLAN : Virtual Local Area Network
    ";
    
        revision "2019-07-01" {
          description
            "Establish semantic version baseline";
        }
    
        revision "2016-12-14" {
          description
            "Removed cisco govern extension";
        }
    
        revision "2014-12-01" {
          description "Proposed";
          reference
            "TODO";
    
        }
    
        cisco-semver:module-version "1.0.0";
    
        feature parameterized-bridge-domains {
          description
            "This feature represents ability to dynamically create
    bridge-domains.";
        }
    
        feature clear-bridge-domain {
          description
            "This features represents ability to clear mac-address table
    and restart bridge-domains.";
          reference
            "IOS-XR: clear l2vpn bridge-domain <>";
    
        }
    
        feature configurable-bd-groups {
          description
            "This feature represents ability to group bridge domains
    under bridge group.";
        }
    
        feature configurable-bd-mtu {
          description
            "This feature represents ability to configure MTU for the
    bridge domain.";
        }
    
        feature configurable-bd-mac-features {
          description
            "This feature represents ability to configure MAC
    features.
    
    This feature is applicable for both bridge domains and
    bridge domain members.";
        }
    
        feature configurable-bd-flooding-mode {
          description
            "This feature represents ability to configure flood mode
    for the bridge domains.";
        }
    
        feature configurable-bd-mac-event-action {
          description
            "This feature represents ability to configure mac event
    actions.
    
    This feature is applicable for both bridge domains and
    bridge domain members.";
        }
    
        feature configurable-bd-mac-secure {
          description
            "This feature represents ability to configure mac secure
    feature
    
    This feature is applicable for both bridge domains and
    bridge domain members.";
        }
    
        feature configurable-bd-flooding {
          description
            "This feature represents ability to configure flooding
    feature.
    
    This feature is applicable for both bridge domains and
    bridge domain members.";
        }
    
        feature configurable-bd-storm-control {
          description
            "This feature represents ability to configure storm control
    feature.
    
    This feature is applicable for both bridge domains and
    bridge domain members.";
        }
    
        feature configurable-bd-dai {
          description
            "This feature represents ability to configure Dynamic ARP
    inspection feature.
    
    This feature is applicable for both bridge domains and
    bridge domain members.";
        }
    
        feature configurable-bd-ipsg {
          description
            "This feature represents ability to configure IP source
    guard feature.
    
    This feature is applicable for both bridge domains and
    bridge domain members.";
        }
    
        feature configurable-bd-snooping-profiles {
          description
            "This feature represents ability to configure snooping
    profiles for the bridge domain.
    
    This feature is applicable for both bridge domains and
    bridge domain members.";
        }
    
        feature configurable-bd-static-mac {
          description
            "This feature represents ability to configure static
    mac list.";
        }
    
        feature configurable-bd-sh-group-number {
          description
            "This feature represents ability to configure split
    horizon group number config.";
        }
    
        feature configurable-bd-member-features {
          description
            "This feature represents ability to configure advance
    features on bridge-domain members.";
        }
    
        typedef bridge-domain-ref {
          type leafref {
            path "/bd:bridge-domain-config/bd:bridge-domains/bd:bridge-domain/bd:id";
          }
          description
            "Reference to bridge-domain instance id.";
        }
    
        typedef bridge-domain-oper-ref {
          type leafref {
            path "/bd:bridge-domain-state/bd:bridge-domains/bd:bridge-domain/bd:id";
          }
          description
            "Reference to bridge-domain instance id.";
        }
    
        typedef bridge-domain-state-type {
          type enumeration {
            enum "up" {
              value 0;
              description
                "Bridge domain is operationally Up.";
            }
            enum "down" {
              value 1;
              description
                "Bridge domain is operationally Down.";
            }
            enum "admin-down" {
              value 2;
              description
                "Bridge domain is shutdown by administrator.";
            }
          }
          description "Bridge domain states.";
        }
    
        container bridge-domain-config {
          description
            "This container defines overall configuration data for bridge
    -domains on a network device.";
          container global {
            description
              "Global configurations for bridge-domains.";
            leaf bd-state-notification-enabled {
              type boolean;
              description
                "If this leaf is set to true, then it enables the emission
    of 'bd-state-notification'; otherwise these notifications
    are not emitted.";
            }
    
            leaf bd-state-notification-rate {
              type uint32;
              description
                "This leaf defines the maximum number of 'bd-state-
    notification' that can be emitted from the device per
    second.";
            }
    
            container pbb {
              description
                "Provider Backbone Bridging (PBB) related global
    configurations.";
              leaf backbone-src-mac {
                type yang:mac-address;
                description
                  "Backbone source mac address configuration for Provider
    Backbone Bridging (PBB)";
              }
            }  // container pbb
          }  // container global
    
          container bridge-groups {
            if-feature configurable-bd-groups;
            description
              "Collection of bridge-groups.
    
    A Bridge-group is logical grouping construct for bridge
    domains. It defines grouping of bridge-domains under a
    named bridge-group. For example all bridge-domains
    belonging to a single customer can be grouped under a bridge
    -group";
            list bridge-group {
              key "name";
              description
                "Bridge-group configuration.";
              leaf name {
                type string {
                  length "1..32";
                }
                description "Bridge-group name";
              }
            }  // list bridge-group
          }  // container bridge-groups
    
          container bridge-domains {
            description
              "Collection of bridge domains.";
            list bridge-domain {
              key "id";
              description
                "Definition of a bridge-domain.";
              leaf id {
                type string;
                description
                  "Bridge domain name or number";
                reference
                  "CLI: bridge-domain <id>";
    
              }
    
              leaf bridge-group {
                if-feature configurable-bd-groups;
                type leafref {
                  path "/bd:bridge-domain-config/bd:bridge-groups/bd:bridge-group/bd:name";
                }
                mandatory true;
                description
                  "Reference to bridge-group name. If bridge-groups are
    supported, referred bridge-group MUST be created
    first.";
              }
    
              leaf enabled {
                type boolean;
                default "true";
                description
                  "This leaf represents configured admin status of the
    bridge domain";
                reference
                  "CLI: shutdown";
    
              }
    
              leaf bd-status-change-notification {
                type boolean;
                description
                  "Enable/disable bridge-domain status change notification.
    
    If true, any change in bridge-domain operational status
    will be notified to client via 'bd-status-change'
    notification.";
              }
    
              container members {
                description
                  "Collection of bridge-domain members.";
                list ac-member {
                  key "interface";
                  description
                    "List of Attachment circuits for current
    bridge-domain.";
                  leaf interface {
                    type if:interface-ref;
                    description
                      "Reference to an attchment circuit interface
    instance which is configured to be part of this
    bridge-domain.";
                  }
    
                  container split-horizon-group {
                    presence
                      "Existence of this container represents Split Horizon
    configuration.
    
    When Split Horizon group number is not configured, device
    assigns default group numbers to ACs or PWs";
                    description
                      "Bridge domain aggregates attachment circuits (ACs) and
    pseudowires (PWs) in one or more groups called Split Horizon
    Groups. When applied to bridge domains, Split Horizon refers
    to the flooding and forwarding behavior between members of a
    Split Horizon group. In general, frames received on one
    member of a split horizon group are not flooded out to the
    other members.";
                    leaf id {
                      if-feature configurable-bd-sh-group-number;
                      type uint16;
                      mandatory true;
                      description
                        "Split Horizon group number for bridge domain member.";
                    }
                  }  // container split-horizon-group
    
                  container mac {
                    description
                      "MAC features for bridge domain.";
                    leaf learning-enabled {
                      type boolean;
                      default "true";
                      description
                        "Enable disable mac learning";
                      reference
                        "CLI xr: mac learning disable";
    
                    }
    
                    container limit {
                      description
                        "MAC table learning limit.";
                      leaf maximum {
                        if-feature configurable-bd-mac-limit-max;
                        type uint32;
                        description
                          "Maximum number of mac addresses that can be learnt";
                      }
    
                      leaf action {
                        if-feature configurable-bd-mac-limit-actions;
                        type mac-limit-action;
                        description
                          "MAC limit violation actions.";
                        reference
                          "CLI xr: mac limit action { flood | no-flood | shutdown }";
    
                      }
    
                      leaf notification {
                        if-feature configurable-bd-mac-limit-notif;
                        type identityref {
                          base mac-limit-notification-type;
                        }
                        description
                          "MAC limit violation notifications.";
                        reference
                          "CLI xr: mac limit notification { none | both | trap }";
    
                      }
                    }  // container limit
    
                    container aging {
                      description
                        "MAC aging configurations.";
                      leaf time {
                        type uint32;
                        units "seconds";
                        default "300";
                        description
                          "The timeout period in seconds for aging out
    dynamically learned forwarding information";
                        reference
                          "CLI: mac aging time <seconds>";
    
                      }
    
                      leaf type {
                        if-feature configurable-bd-mac-aging-types;
                        type mac-aging-type;
                        description
                          "MAC aging type.";
                        reference
                          "CLI xr: mac aging type absolute";
    
                      }
                    }  // container aging
    
                    container port-down {
                      description
                        "Port down event";
                      reference
                        "CLI xr: mac port-down flush";
    
                      leaf flush {
                        type boolean;
                        default "true";
                        description
                          "Enable/Disable mac table flush when port moves to down
    state.";
                      }
                    }  // container port-down
    
                    container secure {
                      description
                        "MAC secure parameters.";
                      leaf action {
                        type mac-secure-action;
                        default "restrict";
                        description
                          "MAC secure action for violating packets.";
                        reference
                          "CLI xr: mac secure action {none | shutdown}";
    
                      }
    
                      leaf logging {
                        type boolean;
                        default "false";
                        description
                          "Enable/Disable logging.";
                        reference
                          "CLI xr: mac secure logging";
    
                      }
    
                      leaf enabled {
                        type boolean;
                        description
                          "Enable or disable mac secure feature";
                      }
                    }  // container secure
                  }  // container mac
    
                  container igmp-snooping {
                    description
                      "Enable IGMP snooping.";
                    leaf profile-name {
                      type string;
                      mandatory true;
                      description
                        "IGMP snooping profile name";
                      reference
                        "CLI xr: igmp snooping { disable | profile <name> }";
    
                    }
                  }  // container igmp-snooping
    
                  container mld-snooping {
                    description
                      "Enable MLD snooping";
                    leaf profile-name {
                      type string;
                      mandatory true;
                      description
                        "MLD snooping profile name.";
                      reference
                        "CLI xr: mld snooping profile <name>";
    
                    }
                  }  // container mld-snooping
    
                  container dhcp-ipv4-snooping {
                    description
                      "Enable DHCP IPv4 snooping.";
                    leaf profile-name {
                      type string;
                      mandatory true;
                      description
                        "DHCPv4 snooping profile name";
                      reference
                        "CLI xr: dhcp ipv4 snooping profile <name>";
    
                    }
                  }  // container dhcp-ipv4-snooping
    
                  container flooding {
                    description
                      "Flooding configurations.";
                    reference
                      "CLI xr: flooding [unknown-unicast] disabled";
    
                    leaf disabled {
                      type empty;
                      description
                        "Disable flooding";
                    }
    
                    leaf disabled-unknown-unicast {
                      type empty;
                      description
                        "Disable unknown unicast flooding";
                    }
                  }  // container flooding
    
                  container storm-control {
                    description
                      "A collection of storm control threshold and action
    configurations.";
                    list thresholds {
                      key "traffic-class";
                      description
                        "A collection of storm control threshold configuration
    entries.";
                      leaf traffic-class {
                        type cbridge:eth-traffic-class;
                        description
                          "This leaf identifies a ethernet traffic type for
    which an administrator desires to configure storm
    control.";
                      }
    
                      leaf value {
                        type uint32;
                        mandatory true;
                        description
                          "Traffic threshold value. Unit of the value is indicated by
    leaf 'unit'.";
                      }
    
                      leaf unit {
                        type enumeration {
                          enum "bps" {
                            value 0;
                            description
                              "Bits per second.";
                          }
                          enum "kbps" {
                            value 1;
                            description
                              "Kilobits per second.";
                          }
                          enum "pps" {
                            value 2;
                            description
                              "Packets per seconds.";
                          }
                        }
                        mandatory true;
                        description
                          "This enumeration define unit of the traffic threshold
    value.";
                      }
                    }  // list thresholds
    
                    leaf action {
                      if-feature configurable-storm-control-actions;
                      type identityref {
                        base storm-control-action;
                      }
                      description
                        "This leaf represents the storm control action taken when
    the traffic of a particular type exceeds the configured
    threshold values.";
                    }
                  }  // container storm-control
    
                  container dynamic-arp-inspection {
                    description
                      "Dynamic ARP Inspection (DAI) configurations.";
                    reference
                      "CLI xr: dynamic-arp-inspection [<address-validation |
                      	logging>]";
    
                    container address-validation {
                      presence
                        "Existence of this container indicates that address
    validation is enabled.";
                      description
                        "Enable address validation.";
                      leaf dst-mac {
                        type empty;
                        description
                          "Match Destination MAC Address";
                      }
    
                      leaf src-mac {
                        type empty;
                        description
                          "Match Source MAC Address";
                      }
    
                      leaf ipv4 {
                        type empty;
                        description
                          "Match IPv4 Address";
                      }
                    }  // container address-validation
    
                    leaf logging {
                      type boolean;
                      description
                        "Enable DAI logging";
                    }
    
                    leaf enable {
                      type boolean;
                      description
                        "Enable or disable Dynamic ARP Inspection.";
                    }
                  }  // container dynamic-arp-inspection
    
                  container ip-source-guard {
                    description
                      "IP source guard (IPSG) configurations.";
                    reference
                      "CLI xr: ip-source-guard [logging]";
    
                    leaf logging {
                      type boolean;
                      default "false";
                      description
                        "Enable IPSG logging";
                    }
    
                    leaf enable {
                      type boolean;
                      description
                        "Enable or disable IP source guard feature.";
                    }
                  }  // container ip-source-guard
                }  // list ac-member
    
                list vfi-member {
                  key "interface";
                  description
                    "List of Virtual Forrwarding Interfaces for current
    bridge-domain.";
                  leaf interface {
                    type if:interface-ref;
                    must
                      "/if:interfaces/if:interface/if:type = 'ifVfiType'" {
                      description
                        "Refernce to VFI type interface.";
                    }
                    description
                      "Reference to an Virtual Forwarding Interface
    instance which is configured to be part of this
    bridge-domain";
                  }
                }  // list vfi-member
    
                container access-pw-member {
                  description
                    "Collection of access pseudowire members.
    
    A Pseudowires can be a regular interface with ifType
    'ifPwType' or it can represented as a non-interface
    context. This container provides model definition for
    both types of the pseudowires.";
                  list access-pw-if-member {
                    key "interface";
                    description
                      "List of interface based access pseudowires for
    current bridge-domain.";
                    leaf interface {
                      type if:interface-ref;
                      must
                        "/if:interfaces/if:interface/if:type = 'ifPwType'" {
                        description
                          "Refernce to pseudo-wire type interface.";
                      }
                      description
                        "Reference to an access pseudo-wire interface
    instance which is configured to be part of this
    bridge domain";
                    }
                  }  // list access-pw-if-member
    
                  list pw-neighbor-spec {
                    key "neighbor-ip-address vc-id";
                    description
                      "Collection of neighbor specification based
    pseudo-wires.";
                    leaf neighbor-ip-address {
                      type inet:ip-address;
                      description
                        "IPv4 or IPv6 address of the neighbor.";
                    }
    
                    leaf vc-id {
                      type uint32 {
                        range "1..4294967295";
                      }
                      description
                        "Pseudowire VC ID";
                    }
    
                    container static-label {
                      if-feature static-label-direct-config;
                      description
                        "Statically configured labels, signalling should be none";
                      leaf local-label {
                        type uint32 {
                          range "16..1048575";
                        }
                        description
                          "Local MPLS label ID";
                      }
    
                      leaf remote-label {
                        type uint32 {
                          range "16..1048575";
                        }
                        description
                          "Remote MPLS label ID";
                      }
                    }  // container static-label
    
                    choice pw-class-or-specs {
                      description
                        "Inherit attributes from a pseudowire class or provide
    configuration";
                      leaf pw-class-template {
                        type pw-template-ref;
                        description
                          "Reference to a pseudowire template";
                      }
    
                      case specs {
                        leaf encap-type {
                          if-feature pw-short-config;
                          type identityref {
                            base pw-encapsulation-type;
                          }
                          description
                            "Encapsulation configuration for this neighbor";
                        }
    
                        leaf tag-impose-vlan {
                          if-feature pw-tag-impose-vlan-id;
                          type uint16 {
                            range "1..4094";
                          }
                          description
                            "Specify a tag for a VLAN ID for the pseudowire";
                        }
    
                        leaf source-ipv6 {
                          if-feature pw-ipv6-source;
                          type inet:ipv6-address;
                          description
                            "The local source IPv6 address. Note this should only be
    configured when neighbor address is IPv6 type";
                        }
                      }  // case specs
                    }  // choice pw-class-or-specs
    
                    container split-horizon-group {
                      presence
                        "Existence of this container represents Split Horizon
    configuration.
    
    When Split Horizon group number is not configured, device
    assigns default group numbers to ACs or PWs";
                      description
                        "Bridge domain aggregates attachment circuits (ACs) and
    pseudowires (PWs) in one or more groups called Split Horizon
    Groups. When applied to bridge domains, Split Horizon refers
    to the flooding and forwarding behavior between members of a
    Split Horizon group. In general, frames received on one
    member of a split horizon group are not flooded out to the
    other members.";
                      leaf id {
                        if-feature configurable-bd-sh-group-number;
                        type uint16;
                        mandatory true;
                        description
                          "Split Horizon group number for bridge domain member.";
                      }
                    }  // container split-horizon-group
    
                    container mac {
                      description
                        "MAC features for bridge domain.";
                      leaf learning-enabled {
                        type boolean;
                        default "true";
                        description
                          "Enable disable mac learning";
                        reference
                          "CLI xr: mac learning disable";
    
                      }
    
                      container limit {
                        description
                          "MAC table learning limit.";
                        leaf maximum {
                          if-feature configurable-bd-mac-limit-max;
                          type uint32;
                          description
                            "Maximum number of mac addresses that can be learnt";
                        }
    
                        leaf action {
                          if-feature configurable-bd-mac-limit-actions;
                          type mac-limit-action;
                          description
                            "MAC limit violation actions.";
                          reference
                            "CLI xr: mac limit action { flood | no-flood | shutdown }";
    
                        }
    
                        leaf notification {
                          if-feature configurable-bd-mac-limit-notif;
                          type identityref {
                            base mac-limit-notification-type;
                          }
                          description
                            "MAC limit violation notifications.";
                          reference
                            "CLI xr: mac limit notification { none | both | trap }";
    
                        }
                      }  // container limit
    
                      container aging {
                        description
                          "MAC aging configurations.";
                        leaf time {
                          type uint32;
                          units "seconds";
                          default "300";
                          description
                            "The timeout period in seconds for aging out
    dynamically learned forwarding information";
                          reference
                            "CLI: mac aging time <seconds>";
    
                        }
    
                        leaf type {
                          if-feature configurable-bd-mac-aging-types;
                          type mac-aging-type;
                          description
                            "MAC aging type.";
                          reference
                            "CLI xr: mac aging type absolute";
    
                        }
                      }  // container aging
    
                      container port-down {
                        description
                          "Port down event";
                        reference
                          "CLI xr: mac port-down flush";
    
                        leaf flush {
                          type boolean;
                          default "true";
                          description
                            "Enable/Disable mac table flush when port moves to down
    state.";
                        }
                      }  // container port-down
    
                      container secure {
                        description
                          "MAC secure parameters.";
                        leaf action {
                          type mac-secure-action;
                          default "restrict";
                          description
                            "MAC secure action for violating packets.";
                          reference
                            "CLI xr: mac secure action {none | shutdown}";
    
                        }
    
                        leaf logging {
                          type boolean;
                          default "false";
                          description
                            "Enable/Disable logging.";
                          reference
                            "CLI xr: mac secure logging";
    
                        }
    
                        leaf enabled {
                          type boolean;
                          description
                            "Enable or disable mac secure feature";
                        }
                      }  // container secure
                    }  // container mac
    
                    container igmp-snooping {
                      description
                        "Enable IGMP snooping.";
                      leaf profile-name {
                        type string;
                        mandatory true;
                        description
                          "IGMP snooping profile name";
                        reference
                          "CLI xr: igmp snooping { disable | profile <name> }";
    
                      }
                    }  // container igmp-snooping
    
                    container mld-snooping {
                      description
                        "Enable MLD snooping";
                      leaf profile-name {
                        type string;
                        mandatory true;
                        description
                          "MLD snooping profile name.";
                        reference
                          "CLI xr: mld snooping profile <name>";
    
                      }
                    }  // container mld-snooping
    
                    container dhcp-ipv4-snooping {
                      description
                        "Enable DHCP IPv4 snooping.";
                      leaf profile-name {
                        type string;
                        mandatory true;
                        description
                          "DHCPv4 snooping profile name";
                        reference
                          "CLI xr: dhcp ipv4 snooping profile <name>";
    
                      }
                    }  // container dhcp-ipv4-snooping
    
                    container flooding {
                      description
                        "Flooding configurations.";
                      reference
                        "CLI xr: flooding [unknown-unicast] disabled";
    
                      leaf disabled {
                        type empty;
                        description
                          "Disable flooding";
                      }
    
                      leaf disabled-unknown-unicast {
                        type empty;
                        description
                          "Disable unknown unicast flooding";
                      }
                    }  // container flooding
    
                    container storm-control {
                      description
                        "A collection of storm control threshold and action
    configurations.";
                      list thresholds {
                        key "traffic-class";
                        description
                          "A collection of storm control threshold configuration
    entries.";
                        leaf traffic-class {
                          type cbridge:eth-traffic-class;
                          description
                            "This leaf identifies a ethernet traffic type for
    which an administrator desires to configure storm
    control.";
                        }
    
                        leaf value {
                          type uint32;
                          mandatory true;
                          description
                            "Traffic threshold value. Unit of the value is indicated by
    leaf 'unit'.";
                        }
    
                        leaf unit {
                          type enumeration {
                            enum "bps" {
                              value 0;
                              description
                                "Bits per second.";
                            }
                            enum "kbps" {
                              value 1;
                              description
                                "Kilobits per second.";
                            }
                            enum "pps" {
                              value 2;
                              description
                                "Packets per seconds.";
                            }
                          }
                          mandatory true;
                          description
                            "This enumeration define unit of the traffic threshold
    value.";
                        }
                      }  // list thresholds
    
                      leaf action {
                        if-feature configurable-storm-control-actions;
                        type identityref {
                          base storm-control-action;
                        }
                        description
                          "This leaf represents the storm control action taken when
    the traffic of a particular type exceeds the configured
    threshold values.";
                      }
                    }  // container storm-control
    
                    container backup {
                      description
                        "Backup pseudo-wire.";
                      leaf neighbor-ip-address {
                        type inet:ip-address;
                        description
                          "IPv4 or IPv6 address of the neighbor.";
                      }
    
                      leaf vc-id {
                        type uint32 {
                          range "1..4294967295";
                        }
                        description
                          "Pseudowire VC ID";
                      }
    
                      leaf pw-class-template {
                        type pw-template-ref;
                        description
                          "Reference to a pseudowire template";
                      }
                    }  // container backup
                  }  // list pw-neighbor-spec
                }  // container access-pw-member
              }  // container members
    
              leaf mtu {
                if-feature configurable-bd-mtu;
                type uint16 {
                  range "46..65535";
                }
                description
                  "The MTU size for bridge domain. All bridge domain
    members must have same MTU size to be operational
    in the domain";
                reference
                  "CLI xr: mtu <>";
    
              }
    
              leaf flooding-mode {
                if-feature configurable-bd-flooding-mode;
                type enumeration {
                  enum "convergence-optimized" {
                    value 0;
                    description
                      "Flood mode optimized for convergence.";
                  }
                  enum "resilience-optimized" {
                    value 1;
                    description
                      "Flood mode optimized for resiliency";
                  }
                }
                description
                  "Flood modes for optimization.";
                reference
                  "CLI xr: flood-mode { convergence-optimized |
                  		     resilience-optimized } ";
    
              }
    
              container mac {
                description
                  "MAC features for bridge domain.";
                leaf learning-enabled {
                  type boolean;
                  default "true";
                  description
                    "Enable disable mac learning";
                  reference
                    "CLI xr: mac learning disable";
    
                }
    
                container limit {
                  description
                    "MAC table learning limit.";
                  leaf maximum {
                    if-feature configurable-bd-mac-limit-max;
                    type uint32;
                    description
                      "Maximum number of mac addresses that can be learnt";
                  }
    
                  leaf action {
                    if-feature configurable-bd-mac-limit-actions;
                    type mac-limit-action;
                    description
                      "MAC limit violation actions.";
                    reference
                      "CLI xr: mac limit action { flood | no-flood | shutdown }";
    
                  }
    
                  leaf notification {
                    if-feature configurable-bd-mac-limit-notif;
                    type identityref {
                      base mac-limit-notification-type;
                    }
                    description
                      "MAC limit violation notifications.";
                    reference
                      "CLI xr: mac limit notification { none | both | trap }";
    
                  }
                }  // container limit
    
                container aging {
                  description
                    "MAC aging configurations.";
                  leaf time {
                    type uint32;
                    units "seconds";
                    default "300";
                    description
                      "The timeout period in seconds for aging out
    dynamically learned forwarding information";
                    reference
                      "CLI: mac aging time <seconds>";
    
                  }
    
                  leaf type {
                    if-feature configurable-bd-mac-aging-types;
                    type mac-aging-type;
                    description
                      "MAC aging type.";
                    reference
                      "CLI xr: mac aging type absolute";
    
                  }
                }  // container aging
    
                container port-down {
                  description "Port down event";
                  reference
                    "CLI xr: mac port-down flush";
    
                  leaf flush {
                    type boolean;
                    default "true";
                    description
                      "Enable/Disable mac table flush when port moves to down
    state.";
                  }
                }  // container port-down
    
                container flooding {
                  description
                    "Flooding configurations.";
                  reference
                    "CLI xr: flooding [unknown-unicast] disabled";
    
                  leaf disabled {
                    type empty;
                    description
                      "Disable flooding";
                  }
    
                  leaf disabled-unknown-unicast {
                    type empty;
                    description
                      "Disable unknown unicast flooding";
                  }
                }  // container flooding
    
                container secure {
                  presence
                    "Existence of this container represents that MAC
    secure is enabled on the bridge domain.";
                  description
                    "MAC secure parameters.";
                  leaf action {
                    type mac-secure-action;
                    default "restrict";
                    description
                      "MAC secure action for violating packets.";
                    reference
                      "CLI xr: mac secure action {none | shutdown}";
    
                  }
    
                  leaf logging {
                    type boolean;
                    default "false";
                    description
                      "Enable/Disable logging.";
                    reference
                      "CLI xr: mac secure logging";
    
                  }
                }  // container secure
    
                container static {
                  description
                    "Static mac address list parameters.";
                  list mac-addresses {
                    key "mac-addr";
                    description
                      "MAC address entry.";
                    leaf mac-addr {
                      type yang:mac-address;
                      description
                        "Static MAC address.";
                    }
    
                    leaf drop {
                      type boolean;
                      mandatory true;
                      description "Drop packet.";
                    }
                  }  // list mac-addresses
                }  // container static
              }  // container mac
    
              container dynamic-arp-inspection {
                presence
                  "Existence of this container represents that Dynamic
    ARP inspection is enabled on the bridge domain";
                description
                  "Dynamic ARP Inspection (DAI) configurations.";
                reference
                  "CLI xr: dynamic-arp-inspection [<address-validation |
                  	logging>]";
    
                container address-validation {
                  presence
                    "Existence of this container indicates that address
    validation is enabled.";
                  description
                    "Enable address validation.";
                  leaf dst-mac {
                    type empty;
                    description
                      "Match Destination MAC Address";
                  }
    
                  leaf src-mac {
                    type empty;
                    description
                      "Match Source MAC Address";
                  }
    
                  leaf ipv4 {
                    type empty;
                    description
                      "Match IPv4 Address";
                  }
                }  // container address-validation
    
                leaf logging {
                  type boolean;
                  description
                    "Enable DAI logging";
                }
              }  // container dynamic-arp-inspection
    
              container ip-source-guard {
                presence
                  "Existence of this container represents that IP source
    guard is enabled on the bridge domain";
                description
                  "IP source guard (IPSG) configurations.";
                reference
                  "CLI xr: ip-source-guard [logging]";
    
                leaf logging {
                  type boolean;
                  default "false";
                  description
                    "Enable IPSG logging";
                }
              }  // container ip-source-guard
    
              container storm-control {
                description
                  "A collection of storm control threshold and action
    configurations.";
                list thresholds {
                  key "traffic-class";
                  description
                    "A collection of storm control threshold configuration
    entries.";
                  leaf traffic-class {
                    type cbridge:eth-traffic-class;
                    description
                      "This leaf identifies a ethernet traffic type for
    which an administrator desires to configure storm
    control.";
                  }
    
                  leaf value {
                    type uint32;
                    mandatory true;
                    description
                      "Traffic threshold value. Unit of the value is indicated by
    leaf 'unit'.";
                  }
    
                  leaf unit {
                    type enumeration {
                      enum "bps" {
                        value 0;
                        description
                          "Bits per second.";
                      }
                      enum "kbps" {
                        value 1;
                        description
                          "Kilobits per second.";
                      }
                      enum "pps" {
                        value 2;
                        description
                          "Packets per seconds.";
                      }
                    }
                    mandatory true;
                    description
                      "This enumeration define unit of the traffic threshold
    value.";
                  }
                }  // list thresholds
    
                leaf action {
                  if-feature configurable-storm-control-actions;
                  type identityref {
                    base storm-control-action;
                  }
                  description
                    "This leaf represents the storm control action taken when
    the traffic of a particular type exceeds the configured
    threshold values.";
                }
              }  // container storm-control
    
              container igmp-snooping {
                description
                  "Enable IGMP snooping.";
                leaf profile-name {
                  type string;
                  description
                    "IGMP snooping profile name";
                  reference
                    "CLI xr: igmp snooping { disable | profile <name> }";
    
                }
    
                leaf disabled {
                  type empty;
                  description
                    "Disable IGMP snooping.";
                }
              }  // container igmp-snooping
    
              container mld-snooping {
                description
                  "Enable MLD snooping";
                leaf profile-name {
                  type string;
                  mandatory true;
                  description
                    "MLD snooping profile name.";
                  reference
                    "CLI xr: mld snooping profile <name>";
    
                }
              }  // container mld-snooping
    
              container dhcp-ipv4-snooping {
                description
                  "Enable DHCP IPv4 snooping.";
                leaf profile-name {
                  type string;
                  mandatory true;
                  description
                    "DHCPv4 snooping profile name";
                  reference
                    "CLI xr: dhcp ipv4 snooping profile <name>";
    
                }
              }  // container dhcp-ipv4-snooping
            }  // list bridge-domain
          }  // container bridge-domains
        }  // container bridge-domain-config
    
        container bridge-domain-state {
          config false;
          description
            "This container defines bridge-domain operational data.";
          container system-capabilities {
            description
              "This container defines system capabilities for bridge
    domain.";
            leaf max-bd {
              type uint32;
              description
                "Maximum number of bridge-domains suported.";
            }
    
            leaf max-ac-per-bd {
              type uint32;
              description
                "Maximum number of attachment circuits per
    bridge-domains.";
            }
    
            leaf max-pw-per-bd {
              type uint32;
              description
                "Maximum number of access pseudowires per
    bridge-domains";
            }
    
            leaf max-vfi-per-bd {
              type uint32;
              description
                "Maximum number of virtual forwarding instances per
    bridge-domains.";
            }
    
            leaf max-sh-group-per-bd {
              type uint32;
              description
                "Maximum number of Split Horizon groups per
    bridge-domains.";
            }
    
            leaf max-interflex-if-per-bd {
              type uint32;
              description
                "Maximum number of Interflex interfaces per
    bridge-domains.";
            }
          }  // container system-capabilities
    
          container module-capabilities {
            description
              "This container defines module capabilities for bridge
    domain.";
            list modules {
              key "name";
              description
                "Collection of capabillity statements for hardware
    module in the system.";
              leaf name {
                type string;
                description
                  "Name of the hardware module such as linecards, for
    which capability is described.";
              }
    
              leaf max-mac-per-bd {
                type uint32;
                description
                  "Maximum number of MAC addresses per bridge-domains
    supported by this module.";
              }
    
              leaf max-pdd-edge-bd {
                type uint32;
                description
                  "Maximum number of PBB Edge type bridge-domains
    supported by this module.";
              }
    
              leaf max-bd {
                type uint32;
                description
                  "Maximum number of bridge-domains suported.";
              }
    
              leaf max-ac-per-bd {
                type uint32;
                description
                  "Maximum number of attachment circuits per
    bridge-domains.";
              }
    
              leaf max-pw-per-bd {
                type uint32;
                description
                  "Maximum number of access pseudowires per
    bridge-domains";
              }
    
              leaf max-vfi-per-bd {
                type uint32;
                description
                  "Maximum number of virtual forwarding instances per
    bridge-domains.";
              }
    
              leaf max-sh-group-per-bd {
                type uint32;
                description
                  "Maximum number of Split Horizon groups per
    bridge-domains.";
              }
            }  // list modules
          }  // container module-capabilities
    
          container bridge-domains {
            description
              "Bridge domain state data.";
            list bridge-domain {
              key "id";
              description
                "Collection of bridge-domain state data.";
              leaf id {
                type string;
                description
                  "Bridge domain name or number";
              }
    
              leaf bd-state {
                type bridge-domain-state-type;
                mandatory true;
                description
                  "Bridge domain operational/admin status.";
              }
    
              leaf create-time {
                type yang:timestamp;
                description
                  "System time when this bridge-domain was created";
              }
    
              leaf last-status-change {
                type yang:timeticks;
                description
                  "Number of consecutive ticks since bridge-domain status
    was changed last time.";
              }
    
              leaf mac-limit-reached {
                type boolean;
                description
                  "This leaf indicates if MAC address limit has been
    reached.";
              }
    
              leaf p2mp-pw-disabled {
                type boolean;
                description
                  "Point to Mutipoint pseudowire state";
              }
    
              container members {
                description
                  "Collection of bridge-domain members.";
                list ac-member {
                  key "interface";
                  description
                    "List of attachment circuits for this bridge domains";
                  leaf interface {
                    type if:interface-state-ref;
                    description
                      "Reference to an instance of Bridge domain attachment
    circuit (AC) interface name.";
                  }
    
                  leaf static-mac-count {
                    type uint32;
                    description
                      "Number of static MAC address configured on this
    bridge-domain member interface.";
                  }
    
                  container dai-stats {
                    description
                      "Dynamic ARP Inspection (DAI) statistics.";
                    leaf packet-drops {
                      type yang:counter64;
                      description
                        "Number of packets dropped by interface due to DAI
    actions.";
                    }
    
                    leaf byte-drops {
                      type yang:counter64;
                      description
                        "Number of bytes dropped by interface due to DAI
    actions.";
                    }
                  }  // container dai-stats
    
                  container ipsg-stats {
                    description "IPSG stats.";
                    leaf packet-drops {
                      type yang:counter64;
                      description
                        "Number of packets dropped by interface due to IPSG
    actions.";
                    }
    
                    leaf byte-drops {
                      type yang:counter64;
                      description
                        "Number of bytes dropped by interface due to IPSG
    actions.";
                    }
                  }  // container ipsg-stats
    
                  container storm-control {
                    description
                      "Storm control statistics.";
                    list drop-counter {
                      key "traffic-class";
                      description
                        "Collection of packet drop statistics for ethernet traffic
    clasess.";
                      leaf traffic-class {
                        type cbridge:eth-traffic-class;
                        description
                          "Ethernet traffic class i.e. broadcast, multicast or
    unknown unicast.";
                      }
    
                      leaf packet-drops {
                        type yang:counter64;
                        description
                          "The total number of dropped packets due to storm
    control violations.";
                      }
    
                      leaf octate-drops {
                        type yang:counter64;
                        description
                          "The total number of bytes of traffic dropped due to
    storm control violations.";
                      }
                    }  // list drop-counter
                  }  // container storm-control
                }  // list ac-member
    
                list vfi-member {
                  key "interface";
                  description
                    "Reference to an instance of Bridge domain Virtual
    Forwarding Instance (VFI) name.";
                  leaf interface {
                    type if:interface-state-ref;
                    must
                      "/if:interfaces-state/if:interface/if:type = 'ifVfiType'" {
                      description
                        "Filter only VFI interfaces";
                    }
                    description
                      "Bridge domain memeber interface name.";
                  }
    
                  container flooding {
                    description
                      "Flooding operational status";
                    list status {
                      key "traffic-class";
                      description
                        "A collection of storm control threshold configuration
    entries.";
                      leaf traffic-class {
                        type eth-traffic-class;
                        description
                          "This leaf identifies a ethernet traffic type.";
                      }
    
                      leaf enabled {
                        type boolean;
                        description
                          "This leaf indicates if flooding is enabled for
    corresponding traffic class";
                      }
                    }  // list status
                  }  // container flooding
                }  // list vfi-member
    
                list access-pw-member {
                  key "vc-peer-address vc-id";
                  description
                    "Collection of access pseudowire members of the bridge
    domain.";
                  leaf vc-peer-address {
                    type pw-oper-vc-peer-addr-ref;
                    description
                      "Reference to peer ip address of a pseudowire instance.";
                  }
    
                  leaf vc-id {
                    type pw-oper-vc-id-ref;
                    description
                      "Reference to vc-id of a pseudowire instance.";
                  }
    
                  container flooding {
                    description
                      "Flooding operational status";
                    list status {
                      key "traffic-class";
                      description
                        "A collection of storm control threshold configuration
    entries.";
                      leaf traffic-class {
                        type eth-traffic-class;
                        description
                          "This leaf identifies a ethernet traffic type.";
                      }
    
                      leaf enabled {
                        type boolean;
                        description
                          "This leaf indicates if flooding is enabled for
    corresponding traffic class";
                      }
                    }  // list status
                  }  // container flooding
                }  // list access-pw-member
              }  // container members
            }  // list bridge-domain
          }  // container bridge-domains
    
          list mac-table {
            key "bd-id mac-address";
            description
              "This list contains mac-address entries for bridge
    domains.";
            leaf bd-id {
              type string;
              description
                "Bridge-domain name where MAC entry is learnt.";
            }
    
            leaf mac-address {
              type yang:mac-address;
              description "MAC address.";
            }
    
            leaf mac-type {
              type enumeration {
                enum "static" {
                  value 0;
                  description
                    "MAC address is configured statically.";
                }
                enum "dynamic" {
                  value 1;
                  description
                    "MAC address is learnt dynamicaly.";
                }
              }
              description "MAC address type.";
            }
    
            leaf interface {
              type if:interface-ref;
              mandatory true;
              description
                "Reference to an interface instance where MAC
    address is learnt.";
            }
    
            leaf secure-mac {
              type boolean;
              description "Secure MAC address.";
            }
    
            leaf ntfy-mac {
              type boolean;
              description "TBD ?NTFY?";
            }
    
            leaf age {
              type yang:timeticks;
              description
                "Time since mac address was learnt on the interface.";
            }
    
            leaf location {
              type string;
              description
                "Linecard / Module where mac address was learnt.";
            }
          }  // list mac-table
        }  // container bridge-domain-state
    
        notification bd-state-notification {
          description
            "This notification is generated when bridge domain state is
    changed.
    
    This notification can be enabled/disabled via configuration
    leaf 'bd-state-notification-enabled'";
          leaf id {
            type bridge-domain-oper-ref;
            description
              "Reference to bridge-domain instance.";
          }
    
          leaf bd-state {
            type bridge-domain-state-type;
            description
              "New state of the bridge-domain.";
          }
    
          leaf time {
            type yang:timestamp;
            description
              "Timestamp of the state change event.";
          }
        }  // notification bd-state-notification
    
        rpc clear-bridge-domain {
          if-feature clear-bridge-domain;
          description
            "Clear mac-address table for bridge-domain and allows a bridge
    to forward again after it was put in shutdown state as a
    result of exceeding the configured MAC limit.";
          reference
            "XR: clear l2vpn bridge-domain <>";
    
          input {
            choice bridge-domains {
              mandatory true;
              description
                "Select bridge-domains to clear.";
              leaf all {
                type empty;
                description
                  "Clear all bridge-domains configured on the device.";
              }
              leaf bd-id {
                type string;
                description
                  "Clear a single bridge-domain";
              }
              leaf bg-id {
                if-feature configurable-bd-groups;
                type string;
                description
                  "Clears all bridge-domains under this bridge-group.";
              }
            }  // choice bridge-domains
          }
    
          output {
            leaf errstr {
              type string;
              description
                "Error message from the device if RPC failed.";
            }
          }
        }  // rpc clear-bridge-domain
    
        rpc clear-mac-address {
          description
            "This RPC allows to clear dynamically learnt mac-address
    entries from the mac-address table.";
          reference
            "XR:  clear l2vpn forwarding mac-address-table <>
            IOS: clear bridge-domain <> mac table <>";
    
          input {
            container bridge-domain {
              description
                "Clear mac-address entries for given bridge-domain(s).";
              leaf bd-id {
                type string;
                mandatory true;
                description
                  "Bridge-domain identifier, clear all mac-address entries
    dynamically learnt on this bridge-domain";
              }
    
              leaf bg-id {
                if-feature configurable-bd-groups;
                type string;
                mandatory true;
                description
                  "Bridge-group identifier, clear all mac-address entries
    from all bridge-domains under this bridge-group.";
              }
            }  // container bridge-domain
    
            leaf interface {
              type if:interface-ref;
              description
                "Reference to an interface. Clear mac-addesses learnt by
    by this interface.";
            }
    
            leaf mac-address {
              type yang:mac-address;
              description
                "Clear a specific mac-address entry from the mac-table.";
            }
          }
    
          output {
            leaf errstr {
              type string;
              description
                "Error message from the device if RPC failed.";
            }
          }
        }  // rpc clear-mac-address
    
        rpc create-parameterized-bridge-domains {
          if-feature parameterized-bridge-domains;
          description
            "Create bridge domains automatically from user defined
    parameters.";
          input {
            leaf parameter {
              type enumeration {
                enum "vlan" {
                  value 0;
                  description
                    "Create bridge-domains from vlan encapsulations of the
    member interfaces.";
                }
              }
              description
                "Parameter for automatic bridge domain creation.";
            }
    
            list member {
              key "interface";
              description
                "Bridge-domain member interface.";
              leaf interface {
                type if:interface-ref;
                description
                  "Reference to an interface instance which is
    configured to be part of this bridge domain";
              }
            }  // list member
          }
    
          output {
            leaf errstr {
              type string;
              description
                "Error message from the device if RPC failed.";
            }
          }
        }  // rpc create-parameterized-bridge-domains
      }  // module cisco-bridge-domain
    

© 2023 YumaWorks, Inc. All rights reserved.