-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
interface: implement VLAN subinterfaces configuration
Example configuration (CLI): ``` [snip] interfaces interface eth-rt2.10 type ietf-if-extensions:ethSubInterface encapsulation dot1q-vlan outer-tag vlan-id 10 parent-interface eth-rt2 ! ``` Example configuration (JSON): ``` { "ietf-interfaces:interfaces": { "interface": [ [snip] { "name": "eth-rt2.10", "type": "ietf-if-extensions:ethSubInterface", "ietf-if-extensions:encapsulation": { "ietf-if-vlan-encapsulation:dot1q-vlan": { "outer-tag": { "vlan-id": 10 } } }, "ietf-if-extensions:parent-interface": "eth-rt2" } ] } } ``` Signed-off-by: Renato Westphal <[email protected]>
- Loading branch information
Showing
12 changed files
with
1,862 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
holo-yang/modules/deviations/ietf-if-extensions-holo-deviations.yang
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
module ietf-if-extensions-holo-deviations { | ||
yang-version 1.1; | ||
namespace "http://holo-routing.org/yang/ietf-if-extensions-holo-deviations"; | ||
prefix ietf-if-extensions-holo-deviations; | ||
|
||
import ietf-interfaces { | ||
prefix if; | ||
} | ||
|
||
import ietf-if-extensions { | ||
prefix if-ext; | ||
} | ||
|
||
organization | ||
"Holo Routing Stack"; | ||
|
||
description | ||
"This module defines deviation statements for the ietf-if-extensions | ||
module."; | ||
|
||
deviation "/if:interfaces/if:interface/if:statistics/if-ext:in-discard-unknown-encaps" { | ||
deviate not-supported; | ||
} | ||
|
||
deviation "/if:interfaces/if:interface/if-ext:forwarding-mode" { | ||
deviate not-supported; | ||
} | ||
} |
51 changes: 51 additions & 0 deletions
51
holo-yang/modules/deviations/ietf-if-vlan-encapsulation-holo-deviations.yang
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
module ietf-if-vlan-encapsulation-holo-deviations { | ||
yang-version 1.1; | ||
namespace "http://holo-routing.org/yang/ietf-if-vlan-encapsulation-holo-deviations"; | ||
prefix ietf-if-vlan-encapsulation-holo-deviations; | ||
|
||
import ietf-interfaces { | ||
prefix if; | ||
} | ||
|
||
import ietf-if-extensions { | ||
prefix if-ext; | ||
} | ||
|
||
import ietf-if-vlan-encapsulation { | ||
prefix if-vlan; | ||
} | ||
|
||
organization | ||
"Holo Routing Stack"; | ||
|
||
description | ||
"This module defines deviation statements for the ietf-if-vlan-encapsulation | ||
module."; | ||
|
||
deviation "/if:interfaces/if:interface/if-ext:encapsulation/if-ext:encaps-type/if-vlan:dot1q-vlan/if-vlan:dot1q-vlan/if-vlan:outer-tag" { | ||
deviate delete { | ||
must 'tag-type = "dot1q-types:s-vlan" or ' | ||
+ 'tag-type = "dot1q-types:c-vlan"'; | ||
} | ||
} | ||
|
||
deviation "/if:interfaces/if:interface/if-ext:encapsulation/if-ext:encaps-type/if-vlan:dot1q-vlan/if-vlan:dot1q-vlan/if-vlan:outer-tag/if-vlan:tag-type" { | ||
deviate not-supported; | ||
} | ||
|
||
deviation "/if:interfaces/if:interface/if-ext:encapsulation/if-ext:encaps-type/if-vlan:dot1q-vlan/if-vlan:dot1q-vlan/if-vlan:second-tag" { | ||
deviate not-supported; | ||
} | ||
|
||
/* | ||
deviation "/if:interfaces/if:interface/if-ext:encapsulation/if-ext:encaps-type/if-vlan:dot1q-vlan/if-vlan:dot1q-vlan/if-vlan:second-tag/if-vlan:tag-type" { | ||
deviate not-supported; | ||
} | ||
*/ | ||
|
||
/* | ||
deviation "/if:interfaces/if:interface/if-ext:encapsulation/if-ext:encaps-type/if-vlan:dot1q-vlan/if-vlan:dot1q-vlan/if-vlan:second-tag/if-vlan:vlan-id" { | ||
deviate not-supported; | ||
} | ||
*/ | ||
} |
Oops, something went wrong.