xen/x86-cpufreq-report.patch
Charles Arnold 08a77ed8c4 - fate#310510 - fix xenpaging
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
2010-10-20 21:00:35 +00:00

70 lines
2.2 KiB
Diff

--- a/xen/arch/x86/platform_hypercall.c
+++ b/xen/arch/x86/platform_hypercall.c
@@ -21,7 +21,7 @@
#include <xen/acpi.h>
#include <asm/current.h>
#include <public/platform.h>
-#include <acpi/cpufreq/processor_perf.h>
+#include <acpi/cpufreq/cpufreq.h>
#include <asm/edd.h>
#include <asm/mtrr.h>
#include "cpu/mtrr/mtrr.h"
@@ -62,6 +62,7 @@ static long cpu_down_helper(void *hdl, v
ret_t do_platform_op(XEN_GUEST_HANDLE(xen_platform_op_t) u_xenpf_op)
{
ret_t ret = 0;
+ struct vcpu *v;
struct xen_platform_op curop, *op = &curop;
if ( !IS_PRIV(current->domain) )
@@ -486,6 +487,24 @@ ret_t do_platform_op(XEN_GUEST_HANDLE(xe
op->u.mem_add.epfn,
op->u.mem_add.pxm);
break;
+
+ case XENPF_get_cpu_freq:
+ if ( op->u.get_cpu_freq.vcpu >= current->domain->max_vcpus ||
+ !(v = current->domain->vcpu[op->u.get_cpu_freq.vcpu]) )
+ {
+ ret = -EINVAL;
+ break;
+ }
+
+ op->u.get_cpu_freq.freq = cpufreq_cpu_policy[v->processor]
+ ? cpufreq_driver->get
+ ? cpufreq_driver->get(v->processor)
+ : cpufreq_cpu_policy[v->processor]->cur
+ : 0;
+ if ( copy_field_to_guest(u_xenpf_op, op, u.get_cpu_freq.freq) )
+ ret = -EFAULT;
+ break;
+
default:
ret = -ENOSYS;
break;
--- a/xen/include/public/platform.h
+++ b/xen/include/public/platform.h
@@ -355,6 +355,14 @@ struct xenpf_mem_hotadd
uint32_t flags;
};
+#define XENPF_get_cpu_freq ('N' << 24)
+struct xenpf_get_cpu_freq {
+ /* IN variables */
+ uint32_t vcpu;
+ /* OUT variables */
+ uint32_t freq; /* in kHz */
+};
+
struct xen_platform_op {
uint32_t cmd;
uint32_t interface_version; /* XENPF_INTERFACE_VERSION */
@@ -374,6 +382,7 @@ struct xen_platform_op {
struct xenpf_cpu_ol cpu_ol;
struct xenpf_cpu_hotadd cpu_add;
struct xenpf_mem_hotadd mem_add;
+ struct xenpf_get_cpu_freq get_cpu_freq;
uint8_t pad[128];
} u;
};