* [PATCH] Export three symbols for kvm use.
@ 2007-12-20 5:57 Zhang, Xiantao
2007-12-20 17:03 ` Christoph Hellwig
0 siblings, 1 reply; 4+ messages in thread
From: Zhang, Xiantao @ 2007-12-20 5:57 UTC (permalink / raw)
To: Luck, Tony, Avi Kivity; +Cc: kvm-devel, linux-ia64
[-- Attachment #1: Type: text/plain, Size: 3045 bytes --]
Hi Tony,
In order to build kvm source successfully, we need to export
three symbols for kvm use. Please review. Maybe Avi can check-in to
kvm.git upstream first.
Thanks
Xiantao
From: Zhang Xiantao <xiantao.zhang@intel.com>
Date: Thu, 20 Dec 2007 09:37:41 +0800
Subject: [PATCH] ia64: Export three symbols for module use
Since kvm/module needs to use some unexported functions in kernel,
so export them with this patch.
Signed-off-by: Zhang Xiantao <xiantao.zhang@intel.com>
---
diff --git a/arch/ia64/kernel/ia64_ksyms.c
b/arch/ia64/kernel/ia64_ksyms.c
index c3b4412..43d227f 100644
--- a/arch/ia64/kernel/ia64_ksyms.c
+++ b/arch/ia64/kernel/ia64_ksyms.c
@@ -12,6 +12,9 @@ EXPORT_SYMBOL(memset);
EXPORT_SYMBOL(memcpy);
EXPORT_SYMBOL(strlen);
+#include<asm/pgtable.h>
+EXPORT_SYMBOL(empty_zero_page);
+
#include <asm/checksum.h>
EXPORT_SYMBOL(ip_fast_csum); /* hand-coded assembly */
EXPORT_SYMBOL(csum_ipv6_magic);
diff --git a/arch/ia64/kernel/sal.c b/arch/ia64/kernel/sal.c
index 27c2ef4..67c1d34 100644
--- a/arch/ia64/kernel/sal.c
+++ b/arch/ia64/kernel/sal.c
@@ -284,6 +284,7 @@ ia64_sal_cache_flush (u64 cache_type)
SAL_CALL(isrv, SAL_CACHE_FLUSH, cache_type, 0, 0, 0, 0, 0, 0);
return isrv.status;
}
+EXPORT_SYMBOL(ia64_sal_cache_flush);
void __init
ia64_sal_init (struct ia64_sal_systab *systab)
@@ -372,3 +373,16 @@ ia64_sal_oemcall_reentrant(struct ia64_sal_retval
*isrvp, u64 oemfunc,
return 0;
}
EXPORT_SYMBOL(ia64_sal_oemcall_reentrant);
+
+long
+ia64_sal_freq_base (unsigned long which, unsigned long
*ticks_per_second,
+ unsigned long *drift_info)
+{
+ struct ia64_sal_retval isrv;
+
+ SAL_CALL(isrv, SAL_FREQ_BASE, which, 0, 0, 0, 0, 0, 0);
+ *ticks_per_second = isrv.v0;
+ *drift_info = isrv.v1;
+ return isrv.status;
+}
+EXPORT_SYMBOL(ia64_sal_freq_base);
diff --git a/include/asm-ia64/sal.h b/include/asm-ia64/sal.h
index 1f5412d..2251118 100644
--- a/include/asm-ia64/sal.h
+++ b/include/asm-ia64/sal.h
@@ -649,17 +649,6 @@ typedef struct err_rec {
* Now define a couple of inline functions for improved type checking
* and convenience.
*/
-static inline long
-ia64_sal_freq_base (unsigned long which, unsigned long
*ticks_per_second,
- unsigned long *drift_info)
-{
- struct ia64_sal_retval isrv;
-
- SAL_CALL(isrv, SAL_FREQ_BASE, which, 0, 0, 0, 0, 0, 0);
- *ticks_per_second = isrv.v0;
- *drift_info = isrv.v1;
- return isrv.status;
-}
extern s64 ia64_sal_cache_flush (u64 cache_type);
extern void __init check_sal_cache_flush (void);
@@ -841,6 +830,9 @@ extern int ia64_sal_oemcall_nolock(struct
ia64_sal_retval *, u64, u64, u64,
u64, u64, u64, u64, u64);
extern int ia64_sal_oemcall_reentrant(struct ia64_sal_retval *, u64,
u64, u64,
u64, u64, u64, u64, u64);
+extern long
+ia64_sal_freq_base (unsigned long which, unsigned long
*ticks_per_second,
+ unsigned long *drift_info);
#ifdef CONFIG_HOTPLUG_CPU
/*
* System Abstraction Layer Specification
[-- Attachment #2: kernel.patch --]
[-- Type: application/octet-stream, Size: 2850 bytes --]
From: Zhang Xiantao <xiantao.zhang@intel.com>
Date: Thu, 20 Dec 2007 09:37:41 +0800
Subject: [PATCH] ia64: Export three symbols for module use
Since kvm/module needs to use some unexported functions in kernel,
so export them with this patch.
Signed-off-by: Zhang Xiantao <xiantao.zhang@intel.com>
---
diff --git a/arch/ia64/kernel/ia64_ksyms.c b/arch/ia64/kernel/ia64_ksyms.c
index c3b4412..43d227f 100644
--- a/arch/ia64/kernel/ia64_ksyms.c
+++ b/arch/ia64/kernel/ia64_ksyms.c
@@ -12,6 +12,9 @@ EXPORT_SYMBOL(memset);
EXPORT_SYMBOL(memcpy);
EXPORT_SYMBOL(strlen);
+#include<asm/pgtable.h>
+EXPORT_SYMBOL(empty_zero_page);
+
#include <asm/checksum.h>
EXPORT_SYMBOL(ip_fast_csum); /* hand-coded assembly */
EXPORT_SYMBOL(csum_ipv6_magic);
diff --git a/arch/ia64/kernel/sal.c b/arch/ia64/kernel/sal.c
index 27c2ef4..67c1d34 100644
--- a/arch/ia64/kernel/sal.c
+++ b/arch/ia64/kernel/sal.c
@@ -284,6 +284,7 @@ ia64_sal_cache_flush (u64 cache_type)
SAL_CALL(isrv, SAL_CACHE_FLUSH, cache_type, 0, 0, 0, 0, 0, 0);
return isrv.status;
}
+EXPORT_SYMBOL(ia64_sal_cache_flush);
void __init
ia64_sal_init (struct ia64_sal_systab *systab)
@@ -372,3 +373,16 @@ ia64_sal_oemcall_reentrant(struct ia64_sal_retval *isrvp, u64 oemfunc,
return 0;
}
EXPORT_SYMBOL(ia64_sal_oemcall_reentrant);
+
+long
+ia64_sal_freq_base (unsigned long which, unsigned long *ticks_per_second,
+ unsigned long *drift_info)
+{
+ struct ia64_sal_retval isrv;
+
+ SAL_CALL(isrv, SAL_FREQ_BASE, which, 0, 0, 0, 0, 0, 0);
+ *ticks_per_second = isrv.v0;
+ *drift_info = isrv.v1;
+ return isrv.status;
+}
+EXPORT_SYMBOL(ia64_sal_freq_base);
diff --git a/include/asm-ia64/sal.h b/include/asm-ia64/sal.h
index 1f5412d..2251118 100644
--- a/include/asm-ia64/sal.h
+++ b/include/asm-ia64/sal.h
@@ -649,17 +649,6 @@ typedef struct err_rec {
* Now define a couple of inline functions for improved type checking
* and convenience.
*/
-static inline long
-ia64_sal_freq_base (unsigned long which, unsigned long *ticks_per_second,
- unsigned long *drift_info)
-{
- struct ia64_sal_retval isrv;
-
- SAL_CALL(isrv, SAL_FREQ_BASE, which, 0, 0, 0, 0, 0, 0);
- *ticks_per_second = isrv.v0;
- *drift_info = isrv.v1;
- return isrv.status;
-}
extern s64 ia64_sal_cache_flush (u64 cache_type);
extern void __init check_sal_cache_flush (void);
@@ -841,6 +830,9 @@ extern int ia64_sal_oemcall_nolock(struct ia64_sal_retval *, u64, u64, u64,
u64, u64, u64, u64, u64);
extern int ia64_sal_oemcall_reentrant(struct ia64_sal_retval *, u64, u64, u64,
u64, u64, u64, u64, u64);
+extern long
+ia64_sal_freq_base (unsigned long which, unsigned long *ticks_per_second,
+ unsigned long *drift_info);
#ifdef CONFIG_HOTPLUG_CPU
/*
* System Abstraction Layer Specification
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] Export three symbols for kvm use.
2007-12-20 5:57 [PATCH] Export three symbols for kvm use Zhang, Xiantao
@ 2007-12-20 17:03 ` Christoph Hellwig
2007-12-21 2:11 ` Zhang, Xiantao
2007-12-21 6:31 ` Avi Kivity
0 siblings, 2 replies; 4+ messages in thread
From: Christoph Hellwig @ 2007-12-20 17:03 UTC (permalink / raw)
To: Zhang, Xiantao; +Cc: Luck, Tony, Avi Kivity, kvm-devel, linux-ia64
On Thu, Dec 20, 2007 at 01:57:01PM +0800, Zhang, Xiantao wrote:
> Hi Tony,
> In order to build kvm source successfully, we need to export
> three symbols for kvm use. Please review. Maybe Avi can check-in to
> kvm.git upstream first.
>
> Thanks
> Xiantao
> From: Zhang Xiantao <xiantao.zhang@intel.com>
> Date: Thu, 20 Dec 2007 09:37:41 +0800
> Subject: [PATCH] ia64: Export three symbols for module use
>
> Since kvm/module needs to use some unexported functions in kernel,
> so export them with this patch.
Please submit this together with the actual kvm code as we don't export
symbols for out of tree usage, thanks.
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: [PATCH] Export three symbols for kvm use.
2007-12-20 17:03 ` Christoph Hellwig
@ 2007-12-21 2:11 ` Zhang, Xiantao
2007-12-21 6:31 ` Avi Kivity
1 sibling, 0 replies; 4+ messages in thread
From: Zhang, Xiantao @ 2007-12-21 2:11 UTC (permalink / raw)
To: Christoph Hellwig; +Cc: Luck, Tony, Avi Kivity, kvm-devel, linux-ia64
Christoph Hellwig wrote:
> On Thu, Dec 20, 2007 at 01:57:01PM +0800, Zhang, Xiantao wrote:
>> Hi Tony,
>> In order to build kvm source successfully, we need to export
>> three symbols for kvm use. Please review. Maybe Avi can check-in to
>> kvm.git upstream first.
>>
>> Thanks
>> Xiantao
>> From: Zhang Xiantao <xiantao.zhang@intel.com>
>> Date: Thu, 20 Dec 2007 09:37:41 +0800
>> Subject: [PATCH] ia64: Export three symbols for module use
>>
>> Since kvm/module needs to use some unexported functions in kernel,
>> so export them with this patch.
>
> Please submit this together with the actual kvm code as we don't
> export symbols for out of tree usage, thanks.
Sure, I have submitted them together with this patch to both mailing
lists. You know, this patch should go into kvm tree first, but need ia64
arch maintainer 's nod :)
Xiantao
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Export three symbols for kvm use.
2007-12-20 17:03 ` Christoph Hellwig
2007-12-21 2:11 ` Zhang, Xiantao
@ 2007-12-21 6:31 ` Avi Kivity
1 sibling, 0 replies; 4+ messages in thread
From: Avi Kivity @ 2007-12-21 6:31 UTC (permalink / raw)
To: Christoph Hellwig; +Cc: Zhang, Xiantao, Luck, Tony, kvm-devel, linux-ia64
Christoph Hellwig wrote:
> On Thu, Dec 20, 2007 at 01:57:01PM +0800, Zhang, Xiantao wrote:
>
>> Hi Tony,
>> In order to build kvm source successfully, we need to export
>> three symbols for kvm use. Please review. Maybe Avi can check-in to
>> kvm.git upstream first.
>>
>> Thanks
>> Xiantao
>> From: Zhang Xiantao <xiantao.zhang@intel.com>
>> Date: Thu, 20 Dec 2007 09:37:41 +0800
>> Subject: [PATCH] ia64: Export three symbols for module use
>>
>> Since kvm/module needs to use some unexported functions in kernel,
>> so export them with this patch.
>>
>
> Please submit this together with the actual kvm code as we don't export
> symbols for out of tree usage, thanks.
>
1. kvm is not out of tree
2. I can't submit unacked ia64 patches in kvm.git
3. Even when this is in kvm.git, it's good to have it in the ia64 tree
to avoid conflicts when it hits mainline
Thanks.
--
Do not meddle in the internals of kernels, for they are subtle and quick to panic.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2007-12-21 6:31 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-12-20 5:57 [PATCH] Export three symbols for kvm use Zhang, Xiantao
2007-12-20 17:03 ` Christoph Hellwig
2007-12-21 2:11 ` Zhang, Xiantao
2007-12-21 6:31 ` Avi Kivity
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox