提交 5a42caea 编写于 作者: X xionglei6

fix:支持misc分区清除

Signed-off-by: Nxionglei6 <xionglei6@huawei.com>
上级 779e1987
...@@ -88,6 +88,7 @@ HashMapHandle GetGroupHashMap(int type); ...@@ -88,6 +88,7 @@ HashMapHandle GetGroupHashMap(int type);
InitWorkspace *GetInitWorkspace(void); InitWorkspace *GetInitWorkspace(void);
#endif #endif
int GetBootModeFromMisc(void); int GetBootModeFromMisc(void);
void clearMisc(void);
#ifdef __cplusplus #ifdef __cplusplus
#if __cplusplus #if __cplusplus
} }
......
...@@ -256,6 +256,7 @@ static void BootStateChange(const char *content) ...@@ -256,6 +256,7 @@ static void BootStateChange(const char *content)
} }
if (strcmp("post-init", content) == 0) { if (strcmp("post-init", content) == 0) {
StartAllServices(START_MODE_NARMAL); StartAllServices(START_MODE_NARMAL);
clearMisc();
return; return;
} }
} }
......
...@@ -268,3 +268,8 @@ void ExecReboot(const char *value) ...@@ -268,3 +268,8 @@ void ExecReboot(const char *value)
INIT_LOGE("Invalid reboot cmd %s.", value); INIT_LOGE("Invalid reboot cmd %s.", value);
return; return;
} }
void clearMisc(void)
{
(void)CheckAndRebootToUpdater(NULL, "reboot", NULL, NULL);
}
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册