meta-gsj: quanta-nvme-powerctrl: improve services sequence
For mateched new design, the package will be independent.
1. This package will not depends on nvme.manager.service
and the log messages directly store on syslog.
2. The nvme_powermanager.service must wait for nvme_gpio.service
initial complete all GPIO setting.
Change-Id: I4fc230691ae09c149cd6c6016cec34139d5f2a1b
Signed-off-by: Samuel Jiang <Samuel.Jiang@quantatw.com>
diff --git a/meta-gsj/recipes-gsj/quanta-nvme-powerctrl/files/nvme_gpio.service b/meta-gsj/recipes-gsj/quanta-nvme-powerctrl/files/nvme_gpio.service
index f7b0e54..f104cfa 100644
--- a/meta-gsj/recipes-gsj/quanta-nvme-powerctrl/files/nvme_gpio.service
+++ b/meta-gsj/recipes-gsj/quanta-nvme-powerctrl/files/nvme_gpio.service
@@ -1,10 +1,13 @@
[Unit]
Description = configure GPIO for SSD Power Control
-Wants=org.openbmc.records.events.service
-After=org.openbmc.records.events.service xyz.openbmc_project.nvme.manager.service
+Before=nvme_powermanager.service
[Service]
+Restart=no
+RemainAfterExit=true
+Type=oneshot
ExecStart=/usr/bin/init_once.sh
+StandardOutput=syslog
[Install]
-WantedBy=multi-user.target
\ No newline at end of file
+WantedBy=multi-user.target
diff --git a/meta-gsj/recipes-gsj/quanta-nvme-powerctrl/files/nvme_powermanager.service b/meta-gsj/recipes-gsj/quanta-nvme-powerctrl/files/nvme_powermanager.service
index 8d32222..1f8c056 100644
--- a/meta-gsj/recipes-gsj/quanta-nvme-powerctrl/files/nvme_powermanager.service
+++ b/meta-gsj/recipes-gsj/quanta-nvme-powerctrl/files/nvme_powermanager.service
@@ -1,12 +1,12 @@
[Unit]
Description=SSD NVME Power Manager
-Wants=org.openbmc.records.events.service
-After=org.openbmc.records.events.service nvme_gpio.service xyz.openbmc_project.nvme.manager.service
+Requires=nvme_gpio.service
+After=nvme_gpio.service
[Service]
ExecStart=/usr/bin/nvme_powermanager.sh
Restart=always
-
+StandardOutput=syslog
[Install]
-WantedBy=multi-user.target
\ No newline at end of file
+WantedBy=multi-user.target