All of lore.kernel.org
 help / color / mirror / Atom feed
* [Patch] fix compilation on Fedora9
@ 2008-07-03  9:32 Akio Takebe
  0 siblings, 0 replies; only message in thread
From: Akio Takebe @ 2008-07-03  9:32 UTC (permalink / raw)
  To: xen-devel

[-- Attachment #1: Type: text/plain, Size: 1333 bytes --]

Hi,

I met a compilation error, and the attache patch fixes it.

gcc -O2 -fomit-frame-pointer -m32 -march=i686 -fno-strict-aliasing
-std=gnu99 -Wall -Wstrict-prototypes -Wno-unused-value
-Wdeclaration-after-statement -DNDEBUG -nostdinc -fno-builtin
-fno-common -iwithprefix include -Werror -Wno-pointer-arith -pipe
-I/root/tmp/xen-unstable.hg.17860/xen/include
-I/root/tmp/xen-unstable.hg.17860/xen/include/asm-x86/mach-generic
-I/root/tmp/xen-unstable.hg.17860/xen/include/asm-x86/mach-default
-msoft-float -fno-stack-protector -g -D__XEN__ -c platform_hypercall.c
-o platform_hypercall.o
cc1: warnings being treated as errors
/root/tmp/xen-unstable.hg/xen/include/acpi/cpufreq/processor_perf.h:23:
error: inline function 'get_cpu_idle_time' declared but never defined
make[4]: *** [platform_hypercall.o] Error 1
make[4]: Leaving directory `/root/tmp/xen-unstable.hg.17860/xen/arch/x86'
make[3]: *** [/root/tmp/xen-unstable.hg.17860/xen/arch/x86/built_in.o]
Error 2
make[3]: Leaving directory `/root/tmp/xen-unstable.hg.17860/xen/arch/x86'
make[2]: *** [/root/tmp/xen-unstable.hg.17860/xen/xen] Error 2
make[2]: Leaving directory `/root/tmp/xen-unstable.hg.17860/xen'
make[1]: *** [install] Error 2
make[1]: Leaving directory `/root/tmp/xen-unstable.hg.17860/xen'
make: *** [install-xen] Error 2

Best Regards,

Akio Takebe


[-- Attachment #2: fix_compilation.patch --]
[-- Type: text/plain, Size: 1576 bytes --]

diff -r 08f77df14cba xen/arch/x86/acpi/cpufreq/cpufreq_ondemand.c
--- a/xen/arch/x86/acpi/cpufreq/cpufreq_ondemand.c	Wed Jul 02 11:30:37 2008 +0900
+++ b/xen/arch/x86/acpi/cpufreq/cpufreq_ondemand.c	Thu Jul 03 18:00:41 2008 +0900
@@ -51,21 +51,6 @@
 };
 
 static struct timer dbs_timer[NR_CPUS];
-
-inline uint64_t get_cpu_idle_time(unsigned int cpu)
-{
-    uint64_t idle_ns;
-    struct vcpu *v;
-
-    if ((v = idle_vcpu[cpu]) == NULL)
-        return 0;
-
-    idle_ns = v->runstate.time[RUNSTATE_running];
-    if (v->is_running)
-        idle_ns += NOW() - v->runstate.state_entry_time;
-
-    return idle_ns;
-}
 
 static void dbs_check_cpu(struct cpu_dbs_info_s *this_dbs_info)
 {
diff -r 08f77df14cba xen/include/acpi/cpufreq/processor_perf.h
--- a/xen/include/acpi/cpufreq/processor_perf.h	Wed Jul 02 11:30:37 2008 +0900
+++ b/xen/include/acpi/cpufreq/processor_perf.h	Thu Jul 03 18:00:41 2008 +0900
@@ -3,6 +3,7 @@
 
 #include <public/platform.h>
 #include <public/sysctl.h>
+#include <xen/sched.h>
 
 int get_cpu_id(u8);
 int acpi_cpufreq_init(void);
@@ -20,7 +21,21 @@
 void cpufreq_suspend(void);
 int  cpufreq_resume(void);
 
-inline uint64_t get_cpu_idle_time(unsigned int);
+always_inline uint64_t get_cpu_idle_time(unsigned int cpu)
+{
+    uint64_t idle_ns;
+    struct vcpu *v;
+
+    if ((v = idle_vcpu[cpu]) == NULL)
+        return 0;
+
+    idle_ns = v->runstate.time[RUNSTATE_running];
+    if (v->is_running)
+        idle_ns += NOW() - v->runstate.state_entry_time;
+
+    return idle_ns;
+}
+
 
 struct processor_performance {
     uint32_t state;

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-07-03  9:32 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-03  9:32 [Patch] fix compilation on Fedora9 Akio Takebe

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.