All of lore.kernel.org
 help / color / mirror / Atom feed
From: Akio Takebe <takebe_akio@jp.fujitsu.com>
To: xen-devel@lists.xensource.com
Subject: [Patch] fix compilation on Fedora9
Date: Thu, 03 Jul 2008 18:32:28 +0900	[thread overview]
Message-ID: <486C9CAC.40408@jp.fujitsu.com> (raw)

[-- 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

                 reply	other threads:[~2008-07-03  9:32 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=486C9CAC.40408@jp.fujitsu.com \
    --to=takebe_akio@jp.fujitsu.com \
    --cc=xen-devel@lists.xensource.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.