Install fan monitor yaml
The phosphor-fan-monitor-config-native recipe will
install the fan monitor configuration yaml so other
recipes can use it.
To install a system specific version of the yaml,
a .bbappend in that system's layer should be used,
otherwise an empty yaml file will be installed.
Change-Id: I310704846915320b5644eda1d5b933471436b2f9
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
diff --git a/meta-openbmc-machines/meta-openpower/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config-native.bbappend b/meta-openbmc-machines/meta-openpower/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config-native.bbappend
new file mode 100644
index 0000000..05dc725
--- /dev/null
+++ b/meta-openbmc-machines/meta-openpower/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config-native.bbappend
@@ -0,0 +1 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/phosphor-fan-monitor-config:"
diff --git a/meta-phosphor/classes/phosphor-fan.bbclass b/meta-phosphor/classes/phosphor-fan.bbclass
index 198b292..d0ffd99 100644
--- a/meta-phosphor/classes/phosphor-fan.bbclass
+++ b/meta-phosphor/classes/phosphor-fan.bbclass
@@ -1,2 +1,3 @@
presence_datadir="${datadir}/phosphor-fan-presence"
control_datadir="${datadir}/phosphor-fan-control"
+monitor_datadir="${datadir}/phosphor-fan-monitor"
diff --git a/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-monitor-config-native.bb b/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-monitor-config-native.bb
new file mode 100644
index 0000000..02420e4
--- /dev/null
+++ b/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-monitor-config-native.bb
@@ -0,0 +1,15 @@
+SUMMARY = "Phosphor fan monitor definition default data"
+PR = "r1"
+
+inherit native
+inherit obmc-phosphor-license
+inherit phosphor-fan
+
+SRC_URI += "file://monitor.yaml"
+
+S = "${WORKDIR}"
+
+do_install() {
+ DEST=${D}${monitor_datadir}
+ install -D monitor.yaml ${DEST}/monitor.yaml
+}
diff --git a/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-monitor-config/monitor.yaml b/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-monitor-config/monitor.yaml
new file mode 100644
index 0000000..ce60a22
--- /dev/null
+++ b/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-monitor-config/monitor.yaml
@@ -0,0 +1,2 @@
+#Default fan monitor definition YAML - empty.
+#For format, see documentation in fan monitor code repository example yaml.