The mxman_failure_work must wait for wlbtd to collect and archive moredump
before allowing recovery to proceed. The scsc_log_collector_schedule_collection()
must block until it is done.
Change-Id: Ic89b1a0df532782f99ed261306b6a82e1f77db44
SCSC-Bug-Id: SSB-49743
Signed-off-by: Ivan Priest <i.priest@samsung.com>
}
atomic_set(&in_collection, 1);
pr_info("Log collection Scheduled");
+
+ /* If dumping a FW panic (i.e. collecting a moredump), we need
+ * to wait for the collection to finish before returning.
+ */
+ if (reason == SCSC_LOG_FW_PANIC)
+ flush_work(&log_status.collect_work);
+
mutex_unlock(&log_status.collection_serial);
} else {