openconfig-p4rt

This module defines a set of extensions that provide P4Runtime (P4RT) specific extensions to the OpenConfig data models. Specifi...

  • Version: 2021-07-20

    openconfig-p4rt@2021-07-20


    
      module openconfig-p4rt {
    
        yang-version 1;
    
        namespace
          "http://openconfig.net/yang/p4rt";
    
        prefix oc-p4rt;
    
        import openconfig-extensions {
          prefix oc-ext;
        }
        import openconfig-interfaces {
          prefix oc-if;
        }
        import openconfig-platform {
          prefix oc-platform;
        }
        import openconfig-system-grpc {
          prefix oc-grpc;
        }
    
        organization "OpenConfig Working Group";
    
        contact "www.openconfig.net";
    
        description
          "This module defines a set of extensions that provide P4Runtime (P4RT)
        specific extensions to the OpenConfig data models. Specifically, these
        parameters for configuration and state provide extensions that control
        the P4RT service, or allow it to be used alongside other OpenConfig
        data models.
    
        The P4RT protocol specification is linkde from https://p4.org/specs/
        under the P4Runtime heading.";
    
        revision "2021-07-20" {
          description
            "Add identity for P4RT as a gRPC service.";
          reference
            "0.2.0";
    
        }
    
        revision "2021-04-06" {
          description "Initial revision.";
          reference
            "0.1.0";
    
        }
    
        oc-ext:openconfig-version "0.2.0";
    
        identity P4RT {
          base oc-grpc:GRPC_SERVICE;
          description
            "P4RT: P4 Runtime (P4RT) Service.";
        }
    
        grouping p4rt-interface-config {
          description
            "Interface-specific configuration that is applicable to devices that
          are running the P4RT service.";
          leaf id {
            type uint32;
            description
              "The numeric identifier used by the controller to address the interface.
            This ID is assigned by an external-to-the-device entity (e.g., an SDN
            management system) to establish an externally deterministic numeric
            reference for the interface. The programming entity must ensure that
            the ID is unique within the required context.
    
            Note that this identifier is used only when a numeric reference to the
            interface is required, it does not replace the unique name assigned to
            the interface.";
          }
        }  // grouping p4rt-interface-config
    
        augment /oc-if:interfaces/oc-if:interface/oc-if:config {
          description
            "Add interface-specific intended configuration for P4RT.";
          uses p4rt-interface-config;
        }
    
        augment /oc-if:interfaces/oc-if:interface/oc-if:state {
          description
            "Add interface-specific applied configuration for P4RT.";
          uses p4rt-interface-config;
        }
    
        grouping p4rt-ic-config {
          description
            "Integrated-circuit specific configuration that is applicable to devices
          that are running the P4RT service.";
          leaf node-id {
            type uint64;
            description
              "The numeric ID used by the controller to address the integrated circuit,
            which may be referred to as a 'device', 'node' or 'target' by the P4RT
            specification.
    
            Each switching ASIC (i.e., node) is addressed by the external entity
            based on its numeric identifier.
    
            The node ID is specified in addition to the string identifier assigned to
            the integrated circuit within the /components/component list.";
          }
        }  // grouping p4rt-ic-config
    
        augment /oc-platform:components/oc-platform:component/oc-platform:integrated-circuit/oc-platform:config {
          description
            "Add integrated circuit specific intended configuration that is required
          for P4RT.";
          uses p4rt-ic-config;
        }
    
        augment /oc-platform:components/oc-platform:component/oc-platform:integrated-circuit/oc-platform:state {
          description
            "Add integrated circuit specific operational state that is required
          for P4RT.";
          uses p4rt-ic-config;
        }
      }  // module openconfig-p4rt
    

© 2023 YumaWorks, Inc. All rights reserved.