migration/dirtyrate: move init step of calculation to main thread
commit9865d0f68fbb4785fcc80d5a28fece8913f4098a
authorHyman Huang(黄勇) <huangy81@chinatelecom.cn>
Tue, 29 Jun 2021 16:01:22 +0000 (29 16:01 +0000)
committerJuan Quintela <quintela@redhat.com>
Mon, 1 Nov 2021 21:56:43 +0000 (1 22:56 +0100)
tree26d4f4290b7550da1337d5d9c92c0ec25bcaeda0
parent15eb2d644cbda3dd2ad5989e273b211e83c16623
migration/dirtyrate: move init step of calculation to main thread

since main thread may "query dirty rate" at any time, it's better
to move init step into main thead so that synchronization overhead
between "main" and "get_dirtyrate" can be reduced.

Signed-off-by: Hyman Huang(黄勇) <huangy81@chinatelecom.cn>
Message-Id: <109f8077518ed2f13068e3bfb10e625e964780f1.1624040308.git.huangy81@chinatelecom.cn>
Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
migration/dirtyrate.c