X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fmodel%2Fmodel-flow-base%2Fsrc%2Fmain%2Fyang%2Fflow-types.yang;h=4145977f635c2cb59b2d9564712d087aad6a378b;hb=f27f2337e171c9f944de55a3ac6650b3b1ec0af2;hp=634c8dbd723832378ee7d62230c3d29628cdc5e9;hpb=a39244aeca4edc981c0645407cb53b8deafa7471;p=controller.git diff --git a/opendaylight/md-sal/model/model-flow-base/src/main/yang/flow-types.yang b/opendaylight/md-sal/model/model-flow-base/src/main/yang/flow-types.yang index 634c8dbd72..4145977f63 100644 --- a/opendaylight/md-sal/model/model-flow-base/src/main/yang/flow-types.yang +++ b/opendaylight/md-sal/model/model-flow-base/src/main/yang/flow-types.yang @@ -2,193 +2,82 @@ module opendaylight-flow-types { namespace "urn:opendaylight:flow:types"; prefix flow; - import ietf-inet-types {prefix inet;} - import opendaylight-match-types {prefix match;} - import ietf-yang-types {prefix yang;} - import opendaylight-l2-types {prefix l2t;} + import ietf-inet-types {prefix inet; revision-date "2010-09-24";} + import ietf-yang-types {prefix yang; revision-date "2010-09-24";} + import opendaylight-match-types {prefix match; revision-date 2013-10-26";} + import opendaylight-action-types {prefix action;} - revision "2013-08-19" { + revision "2013-10-26" { description "Initial revision of flow service"; } - - typedef vlan-cfi { - type int32; - } - - grouping address { - choice address { - case ipv4 { - leaf ipv4-address { - type inet:ipv4-prefix; - } - } - case ipv6 { - leaf ipv6-address { - type inet:ipv6-prefix; - } + grouping instruction-list { + list instruction { + key "order"; + leaf order { + type int32; } + uses instruction; } - } - - grouping action { - choice action { - case output-action { - leaf-list output-node-connector { - type inet:uri; - } - } - - case controller-action { - leaf max-length { - type uint16 { - range "0..65294"; - } - } - } - - case set-queue-action { - leaf queue { - type string; // TODO: define queues - } - } - - case pop-mpls-action { - leaf ethernet-type { - type uint16; // TODO: define ethertype type - } - } - - case set-mpls-ttl-action { - leaf mpls-ttl { - type uint8; - } - } + } - case set-nw-ttl-action { - leaf nw-ttl { + grouping instruction { + choice instruction { + case go-to-table { + leaf table_id { type uint8; } } - - case push-pbb-action { - - } - - case push-mpls-action { - - } - - case drop-action { - } - - case flood-action { - } - - case flood-all-action { - } - - case hw-path-action { - } - - case loopback-action { - } - - case pop-vlan-action { - } - case push-vlan-action { - leaf tag { // TPID - 16 bits - type int32; - } - leaf pcp { // PCP - 3 bits - type int32; - } - leaf cfi { // CFI - 1 bit (drop eligible) - type vlan-cfi; - } - leaf vlan-id { // VID - 12 bits - type l2t:vlan-id; + case write-metadata { + leaf metadata { + type uint64; } -// leaf tci { //TCI = [PCP + CFI + VID] -// } -// leaf header { //header = [TPID + TCI] -// } - } - case set-dl-dst-action { - leaf address { - type yang:mac-address; + + leaf metadata-mask { + type uint64; } } - case set-dl-src-action { - leaf address { - type yang:mac-address; - } - } - case set-dl-type-action { - leaf dl-type { - type l2t:ether-type; - } - } - case set-next-hop-action { - uses address; - } - case set-nw-dst-action { - uses address; - } - case set-nw-src-action{ - uses address; - } - case set-nw-tos-action { - leaf tos { - type int32; - } + case write-actions { + uses action:action-list; } - case set-tp-dst-action { - leaf port { - type inet:port-number; - } - } - case set-tp-src-action { - leaf port { - type inet:port-number; - } - } - case set-vlan-cfi-action { - leaf vlan-cfi { - type vlan-cfi; - } - } - case set-vlan-id-action { - leaf vlan-id { - type l2t:vlan-id; - } - } - case set-vlan-pcp-action { - leaf vlan-pcp { - type l2t:vlan-pcp; - } - } - case sw-path-action { + case apply-actions { + uses action:action-list; } + case clear-actions { + uses action:action-list; + } + case meter { + leaf meter { + type string; + } + } } } - + + typedef flow-mod-flags { + type bits { + bit CHECK_OVERLAP; + bit RESET_COUNTS; + bit NO_PKT_COUNTS; + bit NO_BYT_COUNTS; + bit SEND_FLOW_REM; + } + } + grouping flow { container match { uses match:match; } - list action { - key "order"; - leaf order { - type int32; - } - uses action; + + container instructions { + uses instruction-list; } + leaf priority { type uint16; } @@ -204,6 +93,52 @@ module opendaylight-flow-types { leaf cookie { type uint64; } + + leaf container-name { + type string; + } + + leaf cookie_mask { + type uint8; + } + + leaf table_id { + type uint8; + } + + leaf buffer_id { + type uint32; + } + + leaf out_port { + type uint64; + } + + leaf out_group { + type uint32; + } + + leaf flags{ + type flow-mod-flags; + } + + leaf flow-name{ + type string; + } + + leaf installHw { + type boolean; + } + + leaf barrier { + type boolean; + } + + leaf strict { + type boolean; + default "false"; + } + } grouping flow-statistics {