system/core
Révision | 699e342b3d77c4e2b7e856621e1ce1150859582f (tree) |
---|---|
l'heure | 2019-05-23 01:46:02 |
Auteur | Wei Wang <wvw@goog...> |
Commiter | Wei Wang |
Report non-empty system boot reason when bootloader reason is empty
Bug: 133321647
Test: build
Change-Id: Icd3ea4b69ef2ad040926e2b0e121a8f5f1c1b658
@@ -1086,17 +1086,8 @@ void RecordAbsoluteBootTime(BootEventRecordStore* boot_event_store, | ||
1086 | 1086 | void LogBootInfoToStatsd(std::chrono::milliseconds end_time, |
1087 | 1087 | std::chrono::milliseconds total_duration, int32_t bootloader_duration_ms, |
1088 | 1088 | double time_since_last_boot_sec) { |
1089 | - const auto reason = android::base::GetProperty(bootloader_reboot_reason_property, ""); | |
1090 | - | |
1091 | - if (reason.empty()) { | |
1092 | - android::util::stats_write(android::util::BOOT_SEQUENCE_REPORTED, "<EMPTY>", "<EMPTY>", | |
1093 | - end_time.count(), total_duration.count(), | |
1094 | - (int64_t)bootloader_duration_ms, | |
1095 | - (int64_t)time_since_last_boot_sec * 1000); | |
1096 | - return; | |
1097 | - } | |
1098 | - | |
1099 | - const auto system_reason = android::base::GetProperty(system_reboot_reason_property, ""); | |
1089 | + auto reason = android::base::GetProperty(bootloader_reboot_reason_property, "<EMPTY>"); | |
1090 | + auto system_reason = android::base::GetProperty(system_reboot_reason_property, "<EMPTY>"); | |
1100 | 1091 | android::util::stats_write(android::util::BOOT_SEQUENCE_REPORTED, reason.c_str(), |
1101 | 1092 | system_reason.c_str(), end_time.count(), total_duration.count(), |
1102 | 1093 | (int64_t)bootloader_duration_ms, |