multiple servers
Paul Phillips
pphillips at ivue.com
Wed Jan 27 02:50:27 CET 1999
Michael,
Thanks again for responding.
I believe I have found a couple of bugs in Fiasco which were causing the
multiple server problem, and probably some other problems. In
/fiasco/src/time.h :
the code for set( microseconds):
inline void
timeout_t::set(unsigned long long abs_microsec)
{
// XXX uses cli/sti
_wakeup = abs_microsec;
_flags.set = 1;
unsigned flags = get_eflags();
cli();
if (!timer::first_timeout)
{
timer::first_timeout = this;
_prev = _next = 0;
}
else
{
timeout_t *ti = timer::first_timeout;
for (;;)
{
if (ti->_wakeup >= _wakeup)
{
// insert before ti
_next = ti;
_prev = ti->_prev;
ti->_prev = this;
if (_prev) _prev->_next = this;
/***** here you need to set timer::first_timeout since you just replaced it
*/
else timer::first_timeout = this;
/**********/
goto done;
}
if (ti->_next)
{
ti = ti->_next;
continue;
}
/**** here you need to put a break in case ti->wakeup < timeout,
and and ti->_next==0 .
Otherwise you loop here with interrupts disabled forever */
else break;
/********************/
}
// insert as last item after ti
ti->_next = this;
_prev = ti;
_next = 0;
}
done:
set_eflags(flags);
}
Thanks,
Paul Phillips
-----Original Message-----
From: Michael Hohmuth <hohmuth at innocent.com>
To: Paul Phillips <pphillips at ivue.com>
Cc: l4-hackers at os.inf.tu-dresden.de <l4-hackers at os.inf.tu-dresden.de>
Date: Tuesday, January 26, 1999 11:21 AM
Subject: Re: multiple servers
>Paul,
>
>thanks for trying Fiasco and L4Linux!
>
>"Paul Phillips" <pphillips at ivue.com> writes:
>
>> Right now I'm trying to run two servers concurrently. This is just a
>> "proof of concept" for now. I am trying to run the "hello" server
>> (relocated to 0x2400000) along with the L4-Linux server. I load the
>> "hello"server first and then L4-Linux. L4-linux gets to the
>> "Calibrating delay loop.." and hangs. I am obviously forgetting
>> something here. Is the printf used by the hello server causing a
>> problem?
>
>No, I don't think so.
>
>I take it that without `hello', L4Linux works correctly. My guess
>would be that hello has trouble running at the memory location you
>linked it at. Did you see `hello's output ("hello: My thread-id
>is...") at least once?
>
>Did you get `hello' to work without L4Linux?
>
>Why did you relocate it to 0x2400000? It should be able to run (even
>concurrently with L4Linux) at the memory location it is linked to
>using the distributed version of l4/server/hello/Makefile, 0x200000.
>
>> BTW - I ran across the problem of the "relocation truncated ...." The
>> problem is in the oskit/libsmp/x86/boot.S which contains the
>> trampoline code. When the jump is made to the 32 bit code some linkers
>> have a problem resolving the long jump.
>>
>> ljmp $KERNEL_CS,.........
>>
>> The fix is to put the ".code32" before the jump. This problem has
>> been fixed in the latest release of the OSkit.
>
>Thanks for the hint!
>
>Michael
>--
>hohmuth at innocent.com, hohmuth at sax.de
>http://www.sax.de/~hohmuth/
More information about the l4-hackers
mailing list