From b13ce19ce2744245306b35faeef90ff9c48d9753 Mon Sep 17 00:00:00 2001 From: Robert Varga Date: Sat, 28 Jul 2018 19:37:45 +0200 Subject: [PATCH] Add iana-hardware and odl-mdsal-model-rfc8348 This starts the addition of {iana,ietf}-hardware models. Change-Id: I586be5c181c2504ddb30c52888b38028850e79e6 Signed-off-by: Robert Varga --- model/artifacts/pom.xml | 16 +- model/features/features-mdsal-model/pom.xml | 6 + .../features/odl-mdsal-model-rfc8348/pom.xml | 50 +++++ model/features/pom.xml | 1 + model/iana/iana-hardware/pom.xml | 27 +++ .../main/yang/iana-hardware@2018-03-13.yang | 189 ++++++++++++++++++ model/iana/iana-routing-types/pom.xml | 2 +- model/iana/pom.xml | 3 + 8 files changed, 292 insertions(+), 2 deletions(-) create mode 100644 model/features/odl-mdsal-model-rfc8348/pom.xml create mode 100644 model/iana/iana-hardware/pom.xml create mode 100644 model/iana/iana-hardware/src/main/yang/iana-hardware@2018-03-13.yang diff --git a/model/artifacts/pom.xml b/model/artifacts/pom.xml index b051cbd64e..b791a75711 100644 --- a/model/artifacts/pom.xml +++ b/model/artifacts/pom.xml @@ -97,7 +97,7 @@ 1.0.0-SNAPSHOT - + org.opendaylight.mdsal.binding.model.ietf rfc8294 @@ -172,6 +172,13 @@ 1.0.0-SNAPSHOT + + + org.opendaylight.mdsal.binding.model.iana + iana-hardware + 1.0.0-SNAPSHOT + + org.opendaylight.mdsal.binding.model.ietf @@ -357,6 +364,13 @@ features xml + + org.opendaylight.mdsal.model + odl-mdsal-model-rfc8348 + 1.0.0-SNAPSHOT + features + xml + org.opendaylight.mdsal.model odl-mdsal-model-rfc8349 diff --git a/model/features/features-mdsal-model/pom.xml b/model/features/features-mdsal-model/pom.xml index feb3c83d3f..377b03bae9 100644 --- a/model/features/features-mdsal-model/pom.xml +++ b/model/features/features-mdsal-model/pom.xml @@ -106,6 +106,12 @@ features xml + + org.opendaylight.mdsal.model + odl-mdsal-model-rfc8348 + features + xml + org.opendaylight.mdsal.model odl-mdsal-model-rfc8349 diff --git a/model/features/odl-mdsal-model-rfc8348/pom.xml b/model/features/odl-mdsal-model-rfc8348/pom.xml new file mode 100644 index 0000000000..d32bcfea7e --- /dev/null +++ b/model/features/odl-mdsal-model-rfc8348/pom.xml @@ -0,0 +1,50 @@ + + + + 4.0.0 + + + org.opendaylight.odlparent + single-feature-parent + 3.1.3 + + + + org.opendaylight.mdsal.model + odl-mdsal-model-rfc8348 + 1.0.0-SNAPSHOT + feature + + OpenDaylight :: MD-SAL :: Model :: RFC8348 + + + + + org.opendaylight.mdsal.model + mdsal-model-artifacts + 0.13.0-SNAPSHOT + import + pom + + + + + + + org.opendaylight.mdsal.model + odl-mdsal-model-rfc6991 + features + xml + + + org.opendaylight.mdsal.binding.model.iana + iana-hardware + + + diff --git a/model/features/pom.xml b/model/features/pom.xml index 1d48b0c0fd..c6779eb147 100644 --- a/model/features/pom.xml +++ b/model/features/pom.xml @@ -37,6 +37,7 @@ odl-mdsal-model-rfc8344 odl-mdsal-model-rfc8345 odl-mdsal-model-rfc8345-non-nmda + odl-mdsal-model-rfc8348 odl-mdsal-model-rfc8349 diff --git a/model/iana/iana-hardware/pom.xml b/model/iana/iana-hardware/pom.xml new file mode 100644 index 0000000000..e0aafa576b --- /dev/null +++ b/model/iana/iana-hardware/pom.xml @@ -0,0 +1,27 @@ + + + + + + + org.opendaylight.mdsal + binding-parent + 0.13.0-SNAPSHOT + ../../../binding/binding-parent + + + 4.0.0 + org.opendaylight.mdsal.binding.model.iana + iana-hardware + 1.0.0-SNAPSHOT + bundle + + ${project.artifactId} + iana-hardware@2018-03-13 + diff --git a/model/iana/iana-hardware/src/main/yang/iana-hardware@2018-03-13.yang b/model/iana/iana-hardware/src/main/yang/iana-hardware@2018-03-13.yang new file mode 100644 index 0000000000..5cd52648ff --- /dev/null +++ b/model/iana/iana-hardware/src/main/yang/iana-hardware@2018-03-13.yang @@ -0,0 +1,189 @@ +module iana-hardware { + yang-version 1.1; + namespace "urn:ietf:params:xml:ns:yang:iana-hardware"; + prefix ianahw; + + organization "IANA"; + contact + " Internet Assigned Numbers Authority + + Postal: ICANN + 12025 Waterfront Drive, Suite 300 + Los Angeles, CA 90094-2536 + United States of America + + Tel: +1 310 301 5800 + E-Mail: iana@iana.org>"; + + description + "IANA-defined identities for hardware class. + + The latest revision of this YANG module can be obtained from + the IANA website. + + Requests for new values should be made to IANA via + email (iana@iana.org). + + Copyright (c) 2018 IETF Trust and the persons identified as + authors of the code. All rights reserved. + + Redistribution and use in source and binary forms, with or + without modification, is permitted pursuant to, and subject + to the license terms contained in, the Simplified BSD License + + set forth in Section 4.c of the IETF Trust's Legal Provisions + Relating to IETF Documents + (https://trustee.ietf.org/license-info). + + The initial version of this YANG module is part of RFC 8348; + see the RFC itself for full legal notices."; + reference + "https://www.iana.org/assignments/yang-parameters"; + + revision 2018-03-13 { + description + "Initial revision."; + reference + "RFC 8348: A YANG Data Model for Hardware Management"; + } + + /* + * Identities + */ + + identity hardware-class { + description + "This identity is the base for all hardware class + identifiers."; + } + + identity unknown { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is unknown + to the server."; + } + + identity chassis { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is an + overall container for networking equipment. Any class of + physical component, except a stack, may be contained within a + chassis; a chassis may only be contained within a stack."; + } + + identity backplane { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is some sort + of device for aggregating and forwarding networking traffic, + such as a shared backplane in a modular ethernet switch. Note + that an implementation may model a backplane as a single + physical component, which is actually implemented as multiple + discrete physical components (within a chassis or stack)."; + } + + identity container { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is capable + of containing one or more removable physical entities, + possibly of different types. For example, each (empty or + full) slot in a chassis will be modeled as a container. Note + that all removable physical components should be modeled + within a container component, such as field-replaceable + modules, fans, or power supplies. Note that all known + containers should be modeled by the agent, including empty + containers."; + } + + identity power-supply { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is a + power-supplying component."; + } + + identity fan { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is a fan or + other heat-reduction component."; + } + + identity sensor { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is some sort + of sensor, such as a temperature sensor within a router + chassis."; + } + + identity module { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is some sort + of self-contained sub-system. If a module component is + removable, then it should be modeled within a container + + component; otherwise, it should be modeled directly within + another physical component (e.g., a chassis or another + module)."; + } + + identity port { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is some sort + of networking port capable of receiving and/or transmitting + networking traffic."; + } + + identity stack { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is some sort + of super-container (possibly virtual) intended to group + together multiple chassis entities. A stack may be realized + by a virtual cable, a real interconnect cable attached to + multiple chassis, or multiple interconnect cables. A stack + should not be modeled within any other physical components, + but a stack may be contained within another stack. Only + chassis components should be contained within a stack."; + } + + identity cpu { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is some sort + of central processing unit."; + } + + identity energy-object { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is some sort + of energy object, i.e., it is a piece of equipment that is + part of or attached to a communications network that is + monitored, it is controlled, or it aids in the management of + another device for Energy Management."; + } + + identity battery { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is some sort + of battery."; + } + + identity storage-drive { + base ianahw:hardware-class; + description + "This identity is applicable if the hardware class is some sort + of component with data storage capability as its main + functionality, e.g., hard disk drive (HDD), solid-state device + (SSD), solid-state hybrid drive (SSHD), object storage device + (OSD), or other."; + } +} diff --git a/model/iana/iana-routing-types/pom.xml b/model/iana/iana-routing-types/pom.xml index 3d2ca9aab1..4fdc98e806 100644 --- a/model/iana/iana-routing-types/pom.xml +++ b/model/iana/iana-routing-types/pom.xml @@ -1,7 +1,7 @@ iana-routing-types + + + iana-hardware -- 2.36.6