[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <463B79E6.8000908@goop.org>
Date: Fri, 04 May 2007 11:22:30 -0700
From: Jeremy Fitzhardinge <jeremy@...p.org>
To: "Eric W. Biederman" <ebiederm@...ssion.com>
CC: "H. Peter Anvin" <hpa@...or.com>,
Rusty Russell <rusty@...tcorp.com.au>, Andi Kleen <ak@...e.de>,
Chris Wright <chrisw@...s-sol.org>,
Zachary Amsden <zach@...are.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Linus Torvalds <torvalds@...ux-foundation.org>,
lkml - Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [RFC PATCH 3/3] boot bzImages under paravirt
Eric W. Biederman wrote:
>> Gujin seems to have a near-zero user community, so if they have to rev
>> their code it wouldn't be a big deal (the author keeps trying to push
>> some crack-smoking "Gujin native" patches into the kernel, too),
>> breaking ELILO would hurt anyone using Intel Macs.
>>
>
> I'm thinking we just make the code start.
> startup_32:
> movl %cs, %eax
> testl $3, %eax
> jnz 1f
>
I'm not really happy about using this as a way to distinguish paravirt
from non-paravirt in general. At some point we're going to be running
paravirt kernels in ring0 within a VT/SVM container - but they'll still
be completely paravirtualized kernels.
I think a better approach is to just do it purely based on the boot
params platform field. Ie, something along the lines of:
if (boot_params.version < new_enough)
goto native_boot;
else {
for (int i = 0; i < nplatforms; i++)
if (boot_params.platform == platforms[i].id)
goto *platforms[i].startup
panic();
}
> But that won't work if we want to support relocatability.
> Because we can't load a gdt if we don't know where we are.
>
> To find out where we are we need %ss and %ds, at which point
> we might as well assume we have %es to.
>
Yes, we won't make it far without ss and ds, and while we could avoid
string instructions, you'd have to be a pretty short-sighted bootloader
author to set ss and ds without also setting es.
> So be it then. The next rev of the boot protocol gets to be partially
> incompatible, and we just assume that %cs, %ds, %es, %ss meet our
> basic requirements. I'm pretty certain from what I saw only Gujin
> is going to suffer :(
>
I missed what Gujin does wrong here?
J
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists