Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 312930 Details for
Bug 457137
[IA64] Fix SMP-unsafe with XENMEM_add_to_physmap on HVM
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
Proposed patch. Same as upstream, but renumbered to match xen-3.0.3-68.el5.
xen-make-XENMEM_add_to_physmap-SMP-safe.patch (text/plain), 3.33 KB, created by
Bryan Mason
on 2008-07-29 20:06:16 UTC
(
hide
)
Description:
Proposed patch. Same as upstream, but renumbered to match xen-3.0.3-68.el5.
Filename:
MIME Type:
Creator:
Bryan Mason
Created:
2008-07-29 20:06:16 UTC
Size:
3.33 KB
patch
obsolete
>diff -Naurp xen-3.1.0-src.orig/xen/arch/ia64/vmx/vtlb.c xen-3.1.0-src.new/xen/arch/ia64/vmx/vtlb.c >--- xen-3.1.0-src.orig/xen/arch/ia64/vmx/vtlb.c 2007-05-18 07:45:21.000000000 -0700 >+++ xen-3.1.0-src.new/xen/arch/ia64/vmx/vtlb.c 2008-07-29 11:24:41.433368000 -0700 >@@ -611,6 +611,30 @@ void thash_purge_all(VCPU *v) > local_flush_tlb_all(); > } > >+static void __thash_purge_all(void *arg) >+{ >+ struct vcpu *v = arg; >+ >+ BUG_ON(vcpu_runnable(v) || v->is_running); >+ thash_purge_all(v); >+} >+ >+void vmx_vcpu_flush_vtlb_all(VCPU *v) >+{ >+ if (v == current) { >+ thash_purge_all(v); >+ return; >+ } >+ >+ /* SMP safe */ >+ vcpu_pause(v); >+ if (v->processor == smp_processor_id()) >+ __thash_purge_all(v); >+ else >+ smp_call_function_single(v->processor, __thash_purge_all, v, 1, 1); >+ vcpu_unpause(v); >+} >+ > > /* > * Lookup the hash table and its collision chain to find an entry >diff -Naurp xen-3.1.0-src.orig/xen/arch/ia64/xen/vhpt.c xen-3.1.0-src.new/xen/arch/ia64/xen/vhpt.c >--- xen-3.1.0-src.orig/xen/arch/ia64/xen/vhpt.c 2007-05-18 07:45:21.000000000 -0700 >+++ xen-3.1.0-src.new/xen/arch/ia64/xen/vhpt.c 2008-07-29 11:24:41.475364000 -0700 >@@ -218,31 +218,20 @@ domain_purge_swtc_entries_vcpu_dirty_mas > // (e.g. vcpu == current), smp_mb() is unnecessary. > void vcpu_flush_vtlb_all(struct vcpu *v) > { >- if (VMX_DOMAIN(v)) { >- /* This code may be call for remapping shared_info and >- grant_table share page from guest_physmap_remove_page() >- in arch_memory_op() XENMEM_add_to_physmap to realize >- PV-on-HVM feature. */ >- /* FIXME: This is not SMP-safe yet about p2m table */ >- /* Purge vTLB for VT-i domain */ >- thash_purge_all(v); >- } >- else { >- /* First VCPU tlb. */ >- vcpu_purge_tr_entry(&PSCBX(v,dtlb)); >- vcpu_purge_tr_entry(&PSCBX(v,itlb)); >- smp_mb(); >- >- /* Then VHPT. */ >- if (HAS_PERVCPU_VHPT(v->domain)) >- vcpu_vhpt_flush(v); >- else >- local_vhpt_flush(); >- smp_mb(); >+ /* First VCPU tlb. */ >+ vcpu_purge_tr_entry(&PSCBX(v,dtlb)); >+ vcpu_purge_tr_entry(&PSCBX(v,itlb)); >+ smp_mb(); > >- /* Then mTLB. */ >- local_flush_tlb_all(); >- } >+ /* Then VHPT. */ >+ if (HAS_PERVCPU_VHPT(v->domain)) >+ vcpu_vhpt_flush(v); >+ else >+ local_vhpt_flush(); >+ smp_mb(); >+ >+ /* Then mTLB. */ >+ local_flush_tlb_all(); > > /* We could clear bit in d->domain_dirty_cpumask only if domain d in > not running on this processor. There is currently no easy way to >@@ -266,6 +255,15 @@ void domain_flush_vtlb_all(struct domain > if (!v->is_initialised) > continue; > >+ if (VMX_DOMAIN(v)) { >+ // This code may be called for remapping shared_info >+ // and grant_table from guest_physmap_remove_page() >+ // in arch_memory_op() XENMEM_add_to_physmap to realize >+ // PV-on-HVM feature. >+ vmx_vcpu_flush_vtlb_all(v); >+ continue; >+ } >+ > if (v->processor == cpu) > vcpu_flush_vtlb_all(v); > else >diff -Naurp xen-3.1.0-src.orig/xen/include/asm-ia64/vmmu.h xen-3.1.0-src.new/xen/include/asm-ia64/vmmu.h >--- xen-3.1.0-src.orig/xen/include/asm-ia64/vmmu.h 2007-05-18 07:45:21.000000000 -0700 >+++ xen-3.1.0-src.new/xen/include/asm-ia64/vmmu.h 2008-07-29 11:24:41.488364000 -0700 >@@ -279,6 +279,7 @@ extern void thash_purge_and_insert(struc > * > */ > extern void thash_purge_all(struct vcpu *v); >+extern void vmx_vcpu_flush_vtlb_all(struct vcpu *v); > > /* > * Lookup the hash table and its collision chain to find an entry
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 457137
: 312930 |
314114