phosphor-state-manager: use CHASSIS_INSTANCE for chassis service
Some systems have more chassis than hosts. Use the
OBMC_CHASSIS_INSTANCES variable instead of OBMC_HOST_INSTANCES for
instantiating the service symlinks.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I42eb92a68023788fc8c06e63ed3eb6eb714bf55c
diff --git a/meta-phosphor/recipes-phosphor/state/phosphor-state-manager-systemd-links.inc b/meta-phosphor/recipes-phosphor/state/phosphor-state-manager-systemd-links.inc
index aa0dc0e..37932b4 100644
--- a/meta-phosphor/recipes-phosphor/state/phosphor-state-manager-systemd-links.inc
+++ b/meta-phosphor/recipes-phosphor/state/phosphor-state-manager-systemd-links.inc
@@ -103,13 +103,14 @@
}
pkg_postinst:${PN}-chassis:append() {
- for i in ${OBMC_HOST_INSTANCES};
+ for i in ${OBMC_CHASSIS_INSTANCES};
do
mkdir -p $D$systemd_system_unitdir/multi-user.target.requires
LINK="$D$systemd_system_unitdir/multi-user.target.requires/xyz.openbmc_project.State.Chassis@${i}.service"
TARGET="../xyz.openbmc_project.State.Chassis@.service"
ln -s $TARGET $LINK
+
done
}
@@ -193,7 +194,7 @@
}
pkg_prerm:${PN}-chassis:append() {
- for i in ${OBMC_HOST_INSTANCES};
+ for i in ${OBMC_CHASSIS_INSTANCES};
do
LINK="$D$systemd_system_unitdir/multi-user.target.requires/xyz.openbmc_project.State.Chassis@${i}.service"