Thread (35 messages) 35 messages, 3 authors, 2014-07-28

Re: [PATCH v3 02/18] KVM: PPC: Use RCU when adding to arch.spapr_tce_tables

From: Benjamin Herrenschmidt <hidden>
Date: 2014-07-28 00:40:57

On Thu, 2014-07-24 at 18:47 +1000, Alexey Kardashevskiy wrote:
Signed-off-by: Alexey Kardashevskiy <redacted>
Reviewed-by: Gavin Shan <redacted>
You need a much better changeset here, explaining what you are
protecting against and why just changing that one list_add is
sufficient.

Cheers,
Ben.
quoted hunk ↗ jump to hunk
---
 arch/powerpc/kvm/book3s_64_vio.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/powerpc/kvm/book3s_64_vio.c b/arch/powerpc/kvm/book3s_64_vio.c
index 54cf9bc..516f2ee 100644
--- a/arch/powerpc/kvm/book3s_64_vio.c
+++ b/arch/powerpc/kvm/book3s_64_vio.c
@@ -131,7 +131,7 @@ long kvm_vm_ioctl_create_spapr_tce(struct kvm *kvm,
 	kvm_get_kvm(kvm);
 
 	mutex_lock(&kvm->lock);
-	list_add(&stt->list, &kvm->arch.spapr_tce_tables);
+	list_add_rcu(&stt->list, &kvm->arch.spapr_tce_tables);
 
 	mutex_unlock(&kvm->lock);
 
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help