meta-intel: Use phosphor-pid-control
Add bbappend to use dbus configuration and add custom
service file that restarts always incase of a configuration
change.
Change-Id: I11522547635c5bf2ab3dbb8c6940dab1deb1690e
Signed-off-by: James Feist <james.feist@linux.intel.com>
diff --git a/meta-common/recipes-intel/packagegroups/packagegroup-intel-apps.bb b/meta-common/recipes-intel/packagegroups/packagegroup-intel-apps.bb
index 9eb5ffa..8c0076e 100644
--- a/meta-common/recipes-intel/packagegroups/packagegroup-intel-apps.bb
+++ b/meta-common/recipes-intel/packagegroups/packagegroup-intel-apps.bb
@@ -32,7 +32,7 @@
SUMMARY_${PN}-fans = "Intel Fans"
RDEPENDS_${PN}-fans = " \
- obmc-control-fan \
+ phosphor-pid-control \
"
SUMMARY_${PN}-flash = "Intel Flash"
diff --git a/meta-common/recipes-phosphor/fans/phosphor-pid-control/phosphor-pid-control.service b/meta-common/recipes-phosphor/fans/phosphor-pid-control/phosphor-pid-control.service
new file mode 100644
index 0000000..f4ffa17
--- /dev/null
+++ b/meta-common/recipes-phosphor/fans/phosphor-pid-control/phosphor-pid-control.service
@@ -0,0 +1,12 @@
+[Unit]
+Description=Phosphor-Pid-Control Margin-based Fan Control Daemon
+
+[Service]
+Restart=always
+ExecStart={sbindir}/swampd
+RestartSec=5
+StartLimitInterval=0
+Type=simple
+
+[Install]
+WantedBy=basic.target
diff --git a/meta-common/recipes-phosphor/fans/phosphor-pid-control_%.bbappend b/meta-common/recipes-phosphor/fans/phosphor-pid-control_%.bbappend
new file mode 100644
index 0000000..3e89746
--- /dev/null
+++ b/meta-common/recipes-phosphor/fans/phosphor-pid-control_%.bbappend
@@ -0,0 +1,5 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
+
+inherit obmc-phosphor-systemd
+SYSTEMD_SERVICE_${PN} = "phosphor-pid-control.service"
+EXTRA_OECONF = "--enable-configure-dbus=yes"