Remove watchdog-timeout service on p10bmc systems

watchdog-timeout service is needed only if the PHAL machine features
is not present/enabled. In p10bmc is PHAL machine features based, so
removing the watchdog-timeout service.

This commit:
- Does not install openpower-debug-collector-watchdog-timeout@.service
  file in the /lib/systemd/system directory for PHAL machine features
  based systems
- Removes openpower-debug-collector-watchdog-timeout@0.service link to
  the service file, openpower-debug-collector-watchdog-timeout@.service,
  on PHAL machine features based systems

Testing:
Installed the image on p10bmc system and verified that the systemd
service file openpower-debug-collector-watchdog-timeout@.service was
not created, and the link file,
openpower-debug-collector-watchdog-timeout@0.service, also was not
created.

Signed-off-by: Shantappa Teekappanavar <sbteeks@yahoo.com>
Change-Id: I7bafd9b7e232043cddbcce76af51fd457169f759
diff --git a/meta-openpower/recipes-phosphor/debug/openpower-debug-collector-systemd-links.inc b/meta-openpower/recipes-phosphor/debug/openpower-debug-collector-systemd-links.inc
index 5109a2f..9c522c1 100644
--- a/meta-openpower/recipes-phosphor/debug/openpower-debug-collector-systemd-links.inc
+++ b/meta-openpower/recipes-phosphor/debug/openpower-debug-collector-systemd-links.inc
@@ -15,9 +15,11 @@
 	TARGET="../openpower-debug-collector-watchdog@.service"
 	ln -s $TARGET $LINK
 
-	LINK="$D$systemd_system_unitdir/obmc-host-timeout@0.target.wants/openpower-debug-collector-watchdog-timeout@0.service"
-	TARGET="../openpower-debug-collector-watchdog-timeout@.service"
-	ln -s $TARGET $LINK
+	if [ "${@bb.utils.filter('OBMC_MACHINE_FEATURES', 'phal', d)}" != 'phal' ]; then
+		LINK="$D$systemd_system_unitdir/obmc-host-timeout@0.target.wants/openpower-debug-collector-watchdog-timeout@0.service"
+		TARGET="../openpower-debug-collector-watchdog-timeout@.service"
+		ln -s $TARGET $LINK
+	fi
 }
 
 pkg_prerm:${PN}:append() {
@@ -27,6 +29,8 @@
 	fi
 	LINK="$D$systemd_system_unitdir/obmc-host-timeout@0.target.wants/openpower-debug-collector-watchdog@0.service"
 	rm $LINK
-	LINK="$D$systemd_system_unitdir/obmc-host-timeout@0.target.wants/openpower-debug-collector-watchdog-timeout@0.service"
-	rm $LINK
+	if [ "${@bb.utils.filter('OBMC_MACHINE_FEATURES', 'phal', d)}" != 'phal' ]; then
+		LINK="$D$systemd_system_unitdir/obmc-host-timeout@0.target.wants/openpower-debug-collector-watchdog-timeout@0.service"
+		rm $LINK
+	fi
 }
diff --git a/meta-openpower/recipes-phosphor/debug/openpower-debug-collector_git.bb b/meta-openpower/recipes-phosphor/debug/openpower-debug-collector_git.bb
index 4a5aa3f..68965af 100644
--- a/meta-openpower/recipes-phosphor/debug/openpower-debug-collector_git.bb
+++ b/meta-openpower/recipes-phosphor/debug/openpower-debug-collector_git.bb
@@ -21,7 +21,11 @@
 
 # This provides below applications that are called into in case
 # of host checkstop, host watchdog and host watchdog-timeout respectively.
-APPS = "checkstop watchdog watchdog-timeout"
+APPS =  " \
+        checkstop \
+        watchdog \
+        ${@bb.utils.contains('OBMC_MACHINE_FEATURES', 'phal', '', 'watchdog-timeout', d)} \
+        "
 
 DEBUG_TMPL = "openpower-debug-collector-{0}@.service"
 SYSTEMD_SERVICE:${PN} += "${@compose_list(d, 'DEBUG_TMPL', 'APPS')}"