Renaming ubifs-workaround flag to jffs-workaround
Changes:
Renaming the ubifs-workaround flag to jffs-workaround.
Default behaviour is IN_CREATE, if jffs-workaround is enabled
will monitor for IN_CLOSE_WRITE.
Test:
Tested the fix on romulus i.e. jffs2, ext4 and ubifs. The core file
is getting transferred to dump folder.
Also did full build for jffs and ext4 fs.
Change-Id: I964f5923ad73926db214526aa6c62fca9ac90ba8
Signed-off-by: Chirag Sharma <chirshar@in.ibm.com>
diff --git a/core_manager.hpp b/core_manager.hpp
index 18b7125..b184dae 100644
--- a/core_manager.hpp
+++ b/core_manager.hpp
@@ -16,14 +16,17 @@
using Watch = phosphor::dump::inotify::Watch;
using UserMap = phosphor::dump::inotify::UserMap;
-/** workaround: Watches for IN_CREATE event for the
- * ubi filesystem based systemd-coredump core path
+/** workaround: Watches for IN_CLOSE_WRITE event for the
+ * jffs filesystem based systemd-coredump core path
* Refer openbmc/issues/#2287 for more details.
+ *
+ * JFFS_CORE_FILE_WORKAROUND will be enabled for jffs and
+ * for other file system it will be disabled.
*/
-#ifdef UBI_CORE_FILE_WORKAROUND
-static constexpr auto coreFileEvent = IN_CREATE;
-#else
+#ifdef JFFS_CORE_FILE_WORKAROUND
static constexpr auto coreFileEvent = IN_CLOSE_WRITE;
+#else
+static constexpr auto coreFileEvent = IN_CREATE;
#endif
/** @class Manager