[Trusty][Coverage] Update counter to let Trusty know coverage dump has been read

Bug: 339194547

Change-Id: I075742200998e837e59ba9c24e4dca8b5d4d1199
This commit is contained in:
Snehal 2024-05-07 15:06:44 +00:00 committed by Snehal Koukuntla
parent e451837298
commit b47c9b065f
2 changed files with 2 additions and 1 deletions

View file

@ -60,6 +60,7 @@ void Controller::run(std::string output_dir) {
filename.insert(0, output_dir);
android::base::Result<void> res = record_list_[index]->SaveFile(filename);
counters[index]++;
WRITE_ONCE(control->read_buffer_cnt, counters[index]);
}
if(complete_cnt == counters[index] &&
!(flags & FLAG_RUN)) {

View file

@ -35,9 +35,9 @@
struct control {
/* Written by controller, read by instrumented TA */
uint64_t cntrl_flags;
uint64_t read_buffer_cnt;
/* Written by instrumented TA, read by controller */
uint64_t oper_flags;
uint64_t write_buffer_start_count;
uint64_t write_buffer_complete_count;
};