[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] Make sure the minimum shadow allocation is never zero.
# HG changeset patch # User Keir Fraser <keir.fraser@xxxxxxxxxx> # Date 1263478285 0 # Node ID db8a882f5515bbea739d7db3ddc79d5a754e8c3b # Parent 4b8843ecd553b983da3427687faa38ead7e330ae Make sure the minimum shadow allocation is never zero. Signed-off-by: Tim Deegan <Tim.Deegan@xxxxxxxxxx> --- xen/arch/x86/mm/shadow/common.c | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff -r 4b8843ecd553 -r db8a882f5515 xen/arch/x86/mm/shadow/common.c --- a/xen/arch/x86/mm/shadow/common.c Thu Jan 14 14:10:40 2010 +0000 +++ b/xen/arch/x86/mm/shadow/common.c Thu Jan 14 14:11:25 2010 +0000 @@ -1244,10 +1244,11 @@ int shadow_cmpxchg_guest_entry(struct vc * instruction, we must be able to map a large number (about thirty) VAs * at the same time, which means that to guarantee progress, we must * allow for more than ninety allocated pages per vcpu. We round that - * up to 128 pages, or half a megabyte per vcpu. */ + * up to 128 pages, or half a megabyte per vcpu, and add 1 more vcpu's + * worth to make sure we never return zero. */ static unsigned int shadow_min_acceptable_pages(struct domain *d) { - u32 vcpu_count = 0; + u32 vcpu_count = 1; struct vcpu *v; for_each_vcpu(d, v) _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |