[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-4.0-testing] VT-d: fix off-by-one error in RMRR validation
# HG changeset patch # User Jan Beulich <jbeulich@xxxxxxxx> # Date 1317656133 -3600 # Node ID cda1ee31f07bc22b598452dfafd17c729505d4ec # Parent bd27836e5a111f2f6adab21b8cfc62ac18338fcf VT-d: fix off-by-one error in RMRR validation (base_addr,end_addr) is an inclusive range, and hence there shouldn't be a subtraction of 1 in the second invocation of page_is_ram_type(). For RMRRs covering a single page that actually resulted in the immediately preceding page to get checked (which could have resulted in a false warning). Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx> xen-unstable changeset: 23868:28147fd781af xen-unstable date: Thu Sep 22 18:32:34 2011 +0100 --- diff -r bd27836e5a11 -r cda1ee31f07b xen/drivers/passthrough/vtd/dmar.c --- a/xen/drivers/passthrough/vtd/dmar.c Mon Oct 03 16:35:03 2011 +0100 +++ b/xen/drivers/passthrough/vtd/dmar.c Mon Oct 03 16:35:33 2011 +0100 @@ -515,7 +515,7 @@ * inform the user */ if ( (!page_is_ram_type(paddr_to_pfn(base_addr), RAM_TYPE_RESERVED)) || - (!page_is_ram_type(paddr_to_pfn(end_addr) - 1, RAM_TYPE_RESERVED)) ) + (!page_is_ram_type(paddr_to_pfn(end_addr), RAM_TYPE_RESERVED)) ) { dprintk(XENLOG_WARNING VTDPREFIX, " RMRR address range not in reserved memory " _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |