Skip to content

Commit b74ca3b

Browse files
Takuya Yoshikawatorvalds
Takuya Yoshikawa
authored andcommitted
kvm: replace test_and_set_bit_le() in mark_page_dirty_in_slot() with set_bit_le()
Now that we have defined generic set_bit_le() we do not need to use test_and_set_bit_le() for atomically setting a bit. Signed-off-by: Takuya Yoshikawa <[email protected]> Cc: Avi Kivity <[email protected]> Cc: Marcelo Tosatti <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
1 parent 0ef8fa6 commit b74ca3b

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

virt/kvm/kvm_main.c

+1-2
Original file line numberDiff line numberDiff line change
@@ -1568,8 +1568,7 @@ void mark_page_dirty_in_slot(struct kvm *kvm, struct kvm_memory_slot *memslot,
15681568
if (memslot && memslot->dirty_bitmap) {
15691569
unsigned long rel_gfn = gfn - memslot->base_gfn;
15701570

1571-
/* TODO: introduce set_bit_le() and use it */
1572-
test_and_set_bit_le(rel_gfn, memslot->dirty_bitmap);
1571+
set_bit_le(rel_gfn, memslot->dirty_bitmap);
15731572
}
15741573
}
15751574

0 commit comments

Comments
 (0)