08a77ed8c4
xenpaging.tools_xenpaging_cleanup.patch - fate#310510 - fix xenpaging xenpaging.mem_event_check_ring-free_requests.patch - install /etc/xen/examples/xentrace_formats.txt to get human readable tracedata if xenalyze is not used - fate#310510 - fix xenpaging xenpaging.autostart_delay.patch xenpaging.blacklist.patch xenpaging.MRU_SIZE.patch remove xenpaging.hacks.patch, realmode works - Upstream patches from Jan including fixes for the following bugs bnc#583568 - Xen kernel is not booting bnc#615206 - Xen kernel fails to boot with IO-APIC problem bnc#640773 - Xen kernel crashing right after grub bnc#643477 - issues with PCI hotplug/hotunplug to Xen driver domain 22223-vtd-igd-workaround.patch 22222-x86-timer-extint.patch 22214-x86-msr-misc-enable.patch 22213-x86-xsave-cpuid-check.patch 22194-tmem-check-pv-mfn.patch 22177-i386-irq-safe-map_domain_page.patch 22175-x86-irq-enter-exit.patch 22174-x86-pmtimer-accuracy.patch 22160-Intel-C6-EOI.patch OBS-URL: https://build.opensuse.org/package/show/Virtualization/xen?expand=0&rev=76
49 lines
1.4 KiB
Diff
49 lines
1.4 KiB
Diff
Subject: xenpaging: Open paging file only if xenpaging_init() succeeds
|
|
|
|
Open paging file only if xenpaging_init() succeeds. It can fail if the host
|
|
does not support the required virtualization features such as EPT or if
|
|
xenpaging was already started for this domain_id.
|
|
|
|
Signed-off-by: Olaf Hering <olaf@aepfle.de>
|
|
Already-Acked-by: Patrick Colp <pjcolp@cs.ubc.ca>
|
|
Already-Acked-by: Keir Fraser <keir.fraser@citrix.com>
|
|
|
|
---
|
|
tools/xenpaging/xenpaging.c | 18 +++++++++---------
|
|
1 file changed, 9 insertions(+), 9 deletions(-)
|
|
|
|
--- xen-4.0.1-testing.orig/tools/xenpaging/xenpaging.c
|
|
+++ xen-4.0.1-testing/tools/xenpaging/xenpaging.c
|
|
@@ -495,15 +495,6 @@ int main(int argc, char *argv[])
|
|
|
|
victims = calloc(num_pages, sizeof(xenpaging_victim_t));
|
|
|
|
- /* Open file */
|
|
- sprintf(filename, "page_cache_%d", domain_id);
|
|
- fd = open(filename, open_flags, open_mode);
|
|
- if ( fd < 0 )
|
|
- {
|
|
- perror("failed to open file");
|
|
- return -1;
|
|
- }
|
|
-
|
|
/* Seed random-number generator */
|
|
srand(time(NULL));
|
|
|
|
@@ -515,6 +506,15 @@ int main(int argc, char *argv[])
|
|
goto out;
|
|
}
|
|
|
|
+ /* Open file */
|
|
+ sprintf(filename, "page_cache_%d", domain_id);
|
|
+ fd = open(filename, open_flags, open_mode);
|
|
+ if ( fd < 0 )
|
|
+ {
|
|
+ perror("failed to open file");
|
|
+ return -1;
|
|
+ }
|
|
+
|
|
/* Evict pages */
|
|
memset(victims, 0, sizeof(xenpaging_victim_t) * num_pages);
|
|
for ( i = 0; i < num_pages; i++ )
|