Cisco-IOS-XE-ptp-synce-oper

This module contains a collection of YANG definitions for PTP (Precision Time Protocol) and Synchronous Ethernet operational dat...

  • Version: 2020-03-01

    Cisco-IOS-XE-ptp-synce-oper@2020-03-01


    
      module Cisco-IOS-XE-ptp-synce-oper {
    
        yang-version 1;
    
        namespace
          "http://cisco.com/ns/yang/Cisco-IOS-XE-ptp-synce-oper";
    
        prefix ptp-synce-ios-xe-oper;
    
        import ietf-inet-types {
          prefix inet;
        }
        import ietf-yang-types {
          prefix yang;
        }
        import cisco-semver {
          prefix cisco-semver;
        }
    
        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 module contains a collection of YANG definitions
         for PTP (Precision Time Protocol) and
         Synchronous Ethernet operational data.
         Copyright (c) 2019, 2020 by Cisco Systems, Inc.
         All rights reserved.";
    
        revision "2020-03-01" {
          description "Initial revision";
          reference
            "1.0.0";
    
        }
    
        cisco-semver:module-version "1.0.0";
    
        typedef ptp-clock-type {
          type enumeration {
            enum "ptp-clock-type-not-set" {
              value 0;
              description
                "PTP Clock type not set";
            }
            enum "ptp-clock-type-ordinary" {
              value 1;
              description
                "PTP Clock type Ordinary";
            }
            enum "ptp-clock-type-boundary" {
              value 2;
              description
                "PTP Clock type Boundary";
            }
            enum
              "ptp-clock-type-e2e-transparent" {
              value 3;
              description
                "PTP Clock type edge to edge transparent";
            }
            enum "ptp-clock-type-invalid" {
              value 4;
              description
                "PTP Clock type reserved";
            }
          }
          description "PTP Clock type";
        }
    
        typedef ptp-clock-state {
          type enumeration {
            enum "ptp-clock-state-unknown" {
              value 0;
              description
                "PTP clock state unknown";
            }
            enum "ptp-clock-state-initializing" {
              value 1;
              description
                "PTP clock state initializing";
            }
            enum "ptp-clock-state-freerun" {
              value 2;
              description
                "PTP clock state free run";
            }
            enum "ptp-clock-state-holdover" {
              value 3;
              description
                "PTP clock state hold over";
            }
            enum "ptp-clock-state-acquiring" {
              value 4;
              description
                "PTP clock state acquiring";
            }
            enum "ptp-clock-state-freq-locked" {
              value 5;
              description
                "PTP clock state freq locked";
            }
            enum "ptp-clock-state-phase-aligned" {
              value 6;
              description
                "PTP clock state phase aligned";
            }
            enum "ptp-clock-state-invalid" {
              value 7;
              description
                "PTP clock state invalid";
            }
          }
          description "PTP clock state";
        }
    
        typedef ptp-clock-time-source {
          type enumeration {
            enum "ptp-time-source-atomic-clock" {
              value 0;
              description
                "PTP clock time source atomic clock";
            }
            enum "ptp-time-source-gps" {
              value 1;
              description
                "PTP clock time source GPS";
            }
            enum
              "ptp-time-source-terrestrial-radio" {
              value 2;
              description
                "PTP clock time source terrestrial radio";
            }
            enum "ptp-time-source-ptp" {
              value 3;
              description
                "PTP clock time source PTP";
            }
            enum "ptp-time-source-ntp" {
              value 4;
              description
                "PTP clock time source NTP";
            }
            enum "ptp-time-source-hand-set" {
              value 5;
              description
                "PTP clock time source hand set";
            }
            enum "ptp-time-source-other" {
              value 6;
              description
                "PTP clock time source other";
            }
            enum
              "ptp-time-source-internal-oscillator" {
              value 7;
              description
                "PTP clock time source internal oscillator";
            }
            enum "ptp-time-source-invalid" {
              value 8;
              description
                "PTP clock time source invalid";
            }
          }
          description "PTP clock time source";
        }
    
        typedef peer-address-type {
          type enumeration {
            enum "peer-address-mac" {
              value 0;
              description
                "Peer address is an MAC address";
            }
            enum "peer-address-ip" {
              value 1;
              description
                "Peer address is an IP address";
            }
          }
          description "Peer address types";
        }
    
        typedef netsync-ql {
          type enumeration {
            enum "netsync-ql-null" {
              value 0;
              description
                "Network-clock Synchronization Quality Level Null";
            }
            enum "netsync-ql-dnu" {
              value 1;
              description
                "Network-clock Synchronization Quality Level Do Not Use for Sync";
            }
            enum "netsync-ql-dus" {
              value 2;
              description
                "Network-clock Synchronization Quality Level Do Not Use for Sync";
            }
            enum "netsync-ql-failed" {
              value 3;
              description
                "Network-clock Synchronization Quality Level failed";
            }
            enum "netsync-ql-inv0" {
              value 4;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM(Synchronization Status Message)  Value 0";
            }
            enum "netsync-ql-inv1" {
              value 5;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 1";
            }
            enum "netsync-ql-inv2" {
              value 6;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 2";
            }
            enum "netsync-ql-inv3" {
              value 7;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 3";
            }
            enum "netsync-ql-inv4" {
              value 8;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 4";
            }
            enum "netsync-ql-inv5" {
              value 9;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 5";
            }
            enum "netsync-ql-inv6" {
              value 10;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 6";
            }
            enum "netsync-ql-inv7" {
              value 11;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 7";
            }
            enum "netsync-ql-inv8" {
              value 12;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 8";
            }
            enum "netsync-ql-inv9" {
              value 13;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 9";
            }
            enum "netsync-ql-inv10" {
              value 14;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 10";
            }
            enum "netsync-ql-inv11" {
              value 15;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 11";
            }
            enum "netsync-ql-inv12" {
              value 16;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 12";
            }
            enum "netsync-ql-inv13" {
              value 17;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 13";
            }
            enum "netsync-ql-inv14" {
              value 18;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 14";
            }
            enum "netsync-ql-inv15" {
              value 19;
              description
                "Network-clock Synchronization Quality Level Unallocated SSM Value 15";
            }
            enum "netsync-ql-nsupp" {
              value 20;
              description
                "Network-clock Synchronization Quality Level Not Supporting SSM Processing";
            }
            enum "netsync-ql-prc" {
              value 21;
              description
                "Network-clock Synchronization Quality Level Primary Clock Reference";
            }
            enum "netsync-ql-prov" {
              value 22;
              description
                "Network-clock Synchronization Quality Level Provisional by Network Operator";
            }
            enum "netsync-ql-prs" {
              value 23;
              description
                "Network-clock Synchronization Quality Level PRS(Primary Reference Source) Traceable";
            }
            enum "netsync-ql-sec" {
              value 24;
              description
                "Network-clock Synchronization Quality Level Synchronous Equipment Clock";
            }
            enum "netsync-ql-smc" {
              value 25;
              description
                "Network-clock Synchronization Quality Level SONET(Synchronous Optical Networking) Clock Self timed";
            }
            enum "netsync-ql-ssu-a" {
              value 26;
              description
                "Network-clock Synchronization Quality Level Type I or V Slave Clock";
            }
            enum "netsync-ql-ssu-b" {
              value 27;
              description
                "Network-clock Synchronization Quality Level Type VI Slave Clock";
            }
            enum "netsync-ql-st2" {
              value 28;
              description
                "Network-clock Synchronization Quality Level Stratum 2";
            }
            enum "netsync-ql-st3" {
              value 29;
              description
                "Network-clock Synchronization Quality Level Stratum 3";
            }
            enum "netsync-ql-st3e" {
              value 30;
              description
                "Network-clock Synchronization Quality Level Stratum 3E";
            }
            enum "netsync-ql-st4" {
              value 31;
              description
                "Network-clock Synchronization Quality Level Stratum 4 Free Run";
            }
            enum "netsync-ql-stu" {
              value 32;
              description
                "Network-clock Synchronization Quality Level Synchronized Trace ability Unknown";
            }
            enum "netsync-ql-tnc" {
              value 33;
              description
                "Network-clock Synchronization Quality Level Transit Node Clock";
            }
            enum "netsync-ql-unc" {
              value 34;
              description
                "Network-clock Synchronization Quality Level Unconnected to an Input";
            }
            enum "netsync-ql-unk" {
              value 35;
              description
                "Network-clock Synchronization Quality Level Unknown Clock Source";
            }
            enum "netsync-ql-max" {
              value 36;
              description
                "Network-clock Synchronization Quality Level maximum";
            }
          }
          description
            "Network-clock Synchronization define Quality level value";
        }
    
        typedef signal-type {
          type enumeration {
            enum "na" {
              value 0;
              description
                "Network-clock Synchronization signal type unknown ethernet interfaces";
            }
            enum "t1-sf" {
              value 1;
              description
                "Network-clock Synchronization signal type";
            }
            enum "t1-esf" {
              value 2;
              description
                "Network-clock Synchronization signal type";
            }
            enum "t1-d4" {
              value 3;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1" {
              value 4;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-crc4" {
              value 5;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-crc4-120ohm" {
              value 6;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-crc4-75ohm" {
              value 7;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-fas" {
              value 8;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-fas-120ohm" {
              value 9;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-fas-75ohm" {
              value 10;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-cas" {
              value 11;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-cas-120ohm" {
              value 12;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-cas-75ohm" {
              value 13;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-cas-crc4" {
              value 14;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-cas-crc4-120ohm" {
              value 15;
              description
                "Network-clock Synchronization signal type";
            }
            enum "e1-cas-crc4-75ohm" {
              value 16;
              description
                "Network-clock Synchronization signal type";
            }
            enum "j1" {
              value 17;
              description
                "Network-clock Synchronization signal type";
            }
            enum "2m" {
              value 18;
              description
                "Network-clock Synchronization signal type";
            }
            enum "10m" {
              value 19;
              description
                "Network-clock Synchronization signal type";
            }
            enum "2048k" {
              value 20;
              description
                "Network-clock Synchronization signal type";
            }
            enum "invalid" {
              value 21;
              description
                "Network-clock Synchronization signal type invalid";
            }
          }
          description
            "Network-clock Synchronization signal types";
        }
    
        grouping ptp-clock-quality {
          description "PTP clock quality";
          leaf clock-class {
            type uint8;
            description
              "Clock class value sent to slaves";
          }
    
          leaf offset-scaled-log-var {
            type uint16;
            description "Offset scaled log var";
          }
        }  // grouping ptp-clock-quality
    
        grouping ptp-clock-quality-received {
          description
            "PTP clock quality received";
          container clock-quality {
            description "Clock quality";
            uses ptp-synce-ios-xe-oper:ptp-clock-quality;
          }  // container clock-quality
    
          leaf protocol-address {
            type inet:ip-address;
            description
              "IP address of master device";
          }
        }  // grouping ptp-clock-quality-received
    
        grouping peer-address-data {
          description
            "Peer address of the PTP session";
          choice peer-address-choice {
            description
              "Indicates whether peer address is MAC or IP";
            leaf mac {
              type yang:mac-address;
              description
                "MAC address of the session";
            }
            leaf ip {
              type inet:ip-address;
              description
                "IP address of the session";
            }
          }  // choice peer-address-choice
        }  // grouping peer-address-data
    
        grouping ptp-operational-session {
          description "PTP operational session";
          container address-type {
            description "Peer (MAC/IP) address";
            uses ptp-synce-ios-xe-oper:peer-address-data;
          }  // container address-type
    
          leaf pkts-in {
            type uint64;
            description
              "Number of packets received from peer";
          }
    
          leaf pkts-out {
            type uint64;
            description
              "Number of packets sent to peer";
          }
    
          leaf err-in {
            type uint64;
            description
              "Number of error packets received";
          }
    
          leaf err-out {
            type uint64;
            description
              "Number of error packets sent";
          }
        }  // grouping ptp-operational-session
    
        grouping ptp-clock-runtime-state {
          description "PTP clock runtime state";
          leaf clock-state {
            type ptp-clock-state;
            description "Clock State";
          }
    
          leaf clock-domain {
            type uint8;
            description "Clock domain";
          }
    
          leaf pkts-sent {
            type uint64;
            description
              "Number of packets sent to peer";
          }
    
          leaf pkts-rcvd {
            type uint64;
            description
              "Number of packets received from peer";
          }
    
          list ptp-master {
            description
              "List of PTP masters attached to slave port";
            uses ptp-synce-ios-xe-oper:ptp-operational-session;
          }  // list ptp-master
    
          list ptp-slave {
            description
              "List of PTP slaves connected to master port";
            uses ptp-synce-ios-xe-oper:ptp-operational-session;
          }  // list ptp-slave
        }  // grouping ptp-clock-runtime-state
    
        grouping ptp-clock-time-properties {
          description
            "PTP clock time properties data set";
          leaf current-utc-offset {
            when
              'boolean(../current-utc-offset-valid)';
            type uint16;
            description
              "Current UTC clock offset value";
          }
    
          leaf current-utc-offset-valid {
            type empty;
            description
              "Is Current UTC clock offset value valid";
          }
    
          leaf leap59 {
            type boolean;
            description "Is leap 59";
          }
    
          leaf leap61 {
            type boolean;
            description "Is leap 61";
          }
    
          leaf time-traceable {
            type boolean;
            description "Is Time Traceable";
          }
    
          leaf frequency-traceable {
            type boolean;
            description "Is frequency Traceable";
          }
    
          leaf ptp-time-scale {
            type boolean;
            description "PTP time scale";
          }
    
          leaf time-source {
            type ptp-clock-time-source;
            description "Time Source";
          }
        }  // grouping ptp-clock-time-properties
    
        grouping ptp-time-interval {
          description
            "An IEEE-1588 defined representation of a time interval";
          leaf scaled-nano-seconds {
            type int64;
            units "nanoseconds";
            description
              "Time interval in nanoseconds multiplied by 2<SUP>16</SUP>";
          }
        }  // grouping ptp-time-interval
    
        grouping ptp-clock-current-data-set {
          description
            "An IEEE-1588 defined data set containing attributes related to clock synchronization";
          leaf steps-removed {
            type uint16;
            description
              "Number communication path traversed with grandmaster";
          }
    
          container offset-from-master {
            description
              "Time difference between slave and master";
            uses ptp-synce-ios-xe-oper:ptp-time-interval;
          }  // container offset-from-master
    
          container mean-path-delay {
            description
              "Mean propagation time between master and slave";
            uses ptp-synce-ios-xe-oper:ptp-time-interval;
          }  // container mean-path-delay
        }  // grouping ptp-clock-current-data-set
    
        grouping ptp-key {
          description "PTP key values";
          leaf clock-type {
            type ptp-clock-type;
            description "PTP clock type";
          }
    
          leaf clock-domain {
            type uint64;
            description "PTP clock domain";
          }
    
          leaf clock-inst {
            type uint64;
            description "PTP clock instance";
          }
        }  // grouping ptp-key
    
        grouping ptp-data {
          description "PTP data values";
          container clock-quality {
            description "PTP clock quality sent";
            uses ptp-synce-ios-xe-oper:ptp-clock-quality;
          }  // container clock-quality
    
          list clock-quality-received {
            description
              "PTP clock quality received";
            uses ptp-synce-ios-xe-oper:ptp-clock-quality-received;
          }  // list clock-quality-received
    
          container runtime-state {
            description
              "PTP clock runtime state";
            uses ptp-synce-ios-xe-oper:ptp-clock-runtime-state;
          }  // container runtime-state
    
          container time-properties {
            description
              "PTP clock time properties data set";
            uses ptp-synce-ios-xe-oper:ptp-clock-time-properties;
          }  // container time-properties
    
          container current-dataset {
            description
              "PTP clock current dataset";
            uses ptp-synce-ios-xe-oper:ptp-clock-current-data-set;
          }  // container current-dataset
        }  // grouping ptp-data
    
        grouping netsync-ql-data {
          description
            "Holds Quality Level values";
          leaf ql-tx {
            type netsync-ql;
            description
              "Quality Level value transmitted";
          }
    
          leaf ql-rx {
            type netsync-ql;
            description
              "Actual quality Level value received";
          }
    
          leaf cfg-ql-rx {
            type netsync-ql;
            description
              "Configured quality Level value";
          }
        }  // grouping netsync-ql-data
    
        grouping netsync-key {
          description
            "Holds key, interface name and signal type";
          leaf interface {
            type string;
            description "Interface name";
          }
    
          leaf sig-type {
            type signal-type;
            description "Interface signal type";
          }
        }  // grouping netsync-key
    
        container ptp-synce-oper-data {
          config false;
          description
            "PTP (Precision Time Protocol) operational data";
          list ptp-dataset {
            key "clock-type clock-domain clock-inst";
            description
              "PTP (Precision Time Protocol) dataset";
            uses ptp-synce-ios-xe-oper:ptp-key;
    
            uses ptp-synce-ios-xe-oper:ptp-data;
          }  // list ptp-dataset
    
          list netsync-ql {
            key "interface sig-type";
            description
              "Sync-E (Synchronous Ethernet) operational data";
            uses ptp-synce-ios-xe-oper:netsync-ql-data;
    
            uses ptp-synce-ios-xe-oper:netsync-key;
          }  // list netsync-ql
        }  // container ptp-synce-oper-data
      }  // module Cisco-IOS-XE-ptp-synce-oper
    

© 2023 YumaWorks, Inc. All rights reserved.