[asterisk-dev] ztxen a zaptel timer for XEN virtual domains
Tzafrir Cohen
tzafrir.cohen at xorcom.com
Fri May 4 00:50:14 MST 2007
Hi
On Thu, May 03, 2007 at 05:42:40PM -0400, Michael Cargile wrote:
> In order to get Asterisk to work in our XEN virtual domains we created
> ztxen. This is currently just ztdummy with the RTC stuff removed. We
> created versions for both 1.2.17.1 and 1.4.2.1 (though they would
> probably work with some earlier versions). You however do need to have
> your kernel compiled with the timer interrupt set to 1000Hz for these to
> work.
Why a different module? Why not just build ztdummy with the USE_RTC
define unset?
Now, let's take a close look at the code (from ztdummy,c, aligned for
readability):
#if defined(__i386__) || defined(__x86_64__)
# if LINUX_VERSION_CODE >= VERSION_CODE(2,6,13)
# define USE_RTC
# else
# if 0
# define USE_RTC
# endif
# endif
#endif
I guess we need one of the following three:
1. Disable USE_RTC for the case of a Xen kernel as well (how exactly?)
2. Move the decision to the build system and outside of the code
3. Build both inside and allow selecting one at module load time.
For instance, what if the host has an actual zaptel hardware? Now you
could have a ztdummy span that registers on every tick of the zaptel
master and passes it to the guest (or better: through a PLL, and I
believe one is already implemented in ztdummy).
It would still require an extra dummy span (unless you patch that
directly into zaptel.ko)
>
> We have not done very extensive testing with them at present, just
> placed a few phone calls while the system was under load and listened to
> a few recordings. The domU domains we used this with were both using the
> 2.6.18 kernel as well as the dom0 domain. One had the 1.2.17.1 asterisk
> version and the other had 1.4.2.1. We plan on doing more extensive
> testing with them in the near future as we are going to be creating a
> VICIDIAL domU which uses a number of MeetMes as well as IAX trunks
> (though this will probably only use the 1.2.17.1 version of asterisk).
>
> The main reason to create a new modules for it was that we plan in the
> future to actually rework the whole module so that if you load it in
> your dom0 domain as well as your domU domains it would take any zaptel
> timing source on the dom0 domain and pass it to the domU domains.
What if the host already has zaptel hardware?
For instance, what if the host has an actual zaptel hardware? Now you
could have a ztdummy span that registers on every tick of the zaptel
master and passes it to the guest (or better: through a PLL, and I
believe one is already implemented in ztdummy).
It would still require an extra dummy span (unless you patch that
directly into zaptel.ko)
--
Tzafrir Cohen
icq#16849755 jabber:tzafrir at jabber.org
+972-50-7952406 mailto:tzafrir.cohen at xorcom.com
http://www.xorcom.com iax:guest at local.xorcom.com/tzafrir
More information about the asterisk-dev
mailing list