Add output argument to hpa_purge_begin to count dirty ranges

This commit is contained in:
Slobodan Predolac
2025-04-08 10:49:05 -07:00
committed by Qi Wang
parent cfa90dfd80
commit 0dfb4a5a1a
5 changed files with 27 additions and 9 deletions

View File

@@ -19,7 +19,9 @@ static void
test_psset_fake_purge(hpdata_t *ps) {
hpdata_purge_state_t purge_state;
hpdata_alloc_allowed_set(ps, false);
hpdata_purge_begin(ps, &purge_state);
size_t nranges;
hpdata_purge_begin(ps, &purge_state, &nranges);
(void) nranges;
void *addr;
size_t size;
while (hpdata_purge_next(ps, &purge_state, &addr, &size)) {