From: Avi Kivity <avi-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
To: "Zhang, Xiantao" <xiantao.zhang-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
Cc: carsteno-tA70FqPdS9bQT0dZR+AlfA@public.gmane.org,
kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org,
borntrae-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org
Subject: Re: [PATCH] Add the arg "module" for kvm_arch_init
Date: Sun, 25 Nov 2007 14:31:42 +0200 [thread overview]
Message-ID: <47496B2E.2050101@qumranet.com> (raw)
In-Reply-To: <42DFA526FC41B1429CE7279EF83C6BDC9E77BF-wq7ZOvIWXbMAbVU2wMM1CrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
Zhang, Xiantao wrote:
>>>> That answer confuses me. kvm_arch_init() for ia64 will reside in
>>>> kvm.ko just like kvm_init(), right?
>>>> So THIS_MODULE will be the same in kvm_arch_init() and kvm_init().
>>>> So which module are you giving as argument?
>>>>
>>>>
>>> Sorry for confusing you. In KVM/IA64 architecture, we have a separate
>>> module called vmm module to handle mmu and cpu virtualization. It is
>>> not related to kvm_arch, and will be relocated by kvm.ko when it is
>>> initilized. So, we have to get some information through its
>>> registeration when it calls kvm_init. Certaninly, this information
>>> should be transftered to kvm_arch_init, and handled by ia64-specific
>>> code. Is it clear now?
>>>
>>>
>> Can it not just call an ia64 specific function?
>>
>>
>> Is it actually required to be a kernel module? (is it linked with the
>> rest of the kernel?) If not, maybe it can be a .o file instead of a
>> .ko, and loaded via the request_firmware() mechanism.
>>
>
> Hi Avi,
> Thanks, But seems it is very hard to implement it through a.o,
> because all functions in this part should be relocated to another
> separate address space in whole. If it is implemented as a module(ko),
> we can relocate it as a whole. Currenlty, we haven't found an easy
> method to handle it, due to IA64 virtualization architecture's
> intrinsic implementation. Anyway, adding one arg in this function
> shouldn't impact other architectures. What's your opinion? :)
> Xiantao
>
I can't say much about .o vs .ko without further information. Regarding
passing the module parameter, you might have your module call some
function that is only present in the ia64 implementation to register
itself, instead of calling common code (or, you can have the ia64 code
call some function in your vmm module to get information from it).
--
error compiling committee.c: too many arguments to function
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
next prev parent reply other threads:[~2007-11-25 12:31 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-22 23:32 [PATCH] Add the arg "module" for kvm_arch_init Zhang, Xiantao
[not found] ` <42DFA526FC41B1429CE7279EF83C6BDC9E752C-wq7ZOvIWXbMAbVU2wMM1CrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-11-23 8:19 ` Christian Borntraeger
[not found] ` <200711230919.38608.borntraeger-tA70FqPdS9bQT0dZR+AlfA@public.gmane.org>
2007-11-23 8:25 ` Zhang, Xiantao
[not found] ` <42DFA526FC41B1429CE7279EF83C6BDC9E773F-wq7ZOvIWXbMAbVU2wMM1CrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-11-23 9:34 ` Carsten Otte
[not found] ` <47469EAF.8010301-tA70FqPdS9bQT0dZR+AlfA@public.gmane.org>
2007-11-25 3:23 ` Zhang, Xiantao
[not found] ` <42DFA526FC41B1429CE7279EF83C6BDC9E77AA-wq7ZOvIWXbMAbVU2wMM1CrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-11-25 9:43 ` Avi Kivity
[not found] ` <474943A4.507-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-25 11:59 ` Zhang, Xiantao
[not found] ` <42DFA526FC41B1429CE7279EF83C6BDC9E77BF-wq7ZOvIWXbMAbVU2wMM1CrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-11-25 12:31 ` Avi Kivity [this message]
[not found] ` <47496B2E.2050101-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-26 4:24 ` Zhang, Xiantao
2007-11-26 9:23 ` Carsten Otte
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=47496B2E.2050101@qumranet.com \
--to=avi-atkuwr5tajbwk0htik3j/w@public.gmane.org \
--cc=borntrae-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org \
--cc=carsteno-tA70FqPdS9bQT0dZR+AlfA@public.gmane.org \
--cc=kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
--cc=xiantao.zhang-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox