Skip to contentSkip to conversation

kvm: eventfd comment fixup

PATCH New Michael S. Tsirkin 1 participant 1 message Mar 2, 2011 KVM

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 kvm: eventfd comment fixup

Clarify a comment in kvm/eventfd.c: we do rcu_assign_pointer without explicit synchronize_rcu afterwards, and the reason this works is because we use a spinlock to synch against another place which does call synchronize_rcu.

---

virt/kvm/eventfd.c +3 -2
index 2ca4535..e347b53 100644
@@ -313,8 +313,9 @@ kvm_irqfd_deassign(struct kvm *kvm, int fd, int gsi)
 		if (irqfd->eventfd == eventfd && irqfd->gsi == gsi) {
 			/*
 			 * This rcu_assign_pointer is needed for when
-			 * another thread calls kvm_irqfd_update before
-			 * we flush workqueue below.
+			 * another thread calls kvm_irq_routing_update before
+			 * we flush workqueue below (we synchronize with
+			 * kvm_irq_routing_update using irqfds.lock).
 			 * It is paired with synchronize_rcu done by caller
 			 * of that function.
 			 */
Signature · 1 line
MST