bmc: move verify systemd mode to parameter
Move the mode for the trigger service to a parameter instead of
hard-coding it. This isn't yet a json configuration option, that'll be
next.
Signed-off-by: Patrick Venture <venture@google.com>
Change-Id: I59564320015c22be1ec3a4701479d0ee93b9f1f7
diff --git a/bmc/verify_systemd.hpp b/bmc/verify_systemd.hpp
index 894b534..9d56722 100644
--- a/bmc/verify_systemd.hpp
+++ b/bmc/verify_systemd.hpp
@@ -24,17 +24,18 @@
*
* @param[in] bus - an sdbusplus handler for a bus to use.
* @param[in] path - the path to check for verification status.
- * @param[in[ service - the systemd service to start to trigger
+ * @param[in] service - the systemd service to start to trigger
* verification.
+ * @param[in] mode - the job-mode when starting the systemd Unit.
*/
static std::unique_ptr<TriggerableActionInterface>
CreateVerification(sdbusplus::bus::bus&& bus, const std::string& path,
- const std::string& service);
+ const std::string& service, const std::string& mode);
SystemdVerification(sdbusplus::bus::bus&& bus, const std::string& path,
- const std::string& service) :
+ const std::string& service, const std::string& mode) :
bus(std::move(bus)),
- checkPath(path), triggerService(service)
+ checkPath(path), triggerService(service), mode(mode)
{
}
@@ -48,9 +49,12 @@
void abort() override;
ActionStatus status() override;
+ const std::string getMode() const;
+
private:
sdbusplus::bus::bus bus;
const std::string checkPath;
const std::string triggerService;
+ const std::string mode;
};
} // namespace ipmi_flash