[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qe
From: |
Robert Millan |
Subject: |
[PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port) |
Date: |
Mon, 22 Jun 2009 00:53:32 +0200 |
User-agent: |
Mutt/1.5.18 (2008-05-17) |
In this line of code in real_to_prot():
DATA32 ADDR32 lgdt %cs:gdtdesc
GAS generates an absolute address for `gdtdesc' (not relative to segment),
and so for the code to work %cs must be zero. In current usage of
real_to_prot(), %cs is always zero because we jump to 0x0:0x82xx early on.
However, in other situations this is not possible. On i386-qemu, before
moving to i386 mode the code we're running is in the 0xf0000-0x100000
range, which is inaccessible from segment 0.
This patch changes this to access gdtdesc from segment 0 unconditionally.
--
Robert Millan
The DRM opt-in fallacy: "Your data belongs to us. We will decide when (and
how) you may access your data; but nobody's threatening your freedom: we
still allow you to remove your data and not access it at all."
cs_in_real_to_prot.diff
Description: Text Data
- Re: [PATCH] i386-qemu port, (continued)
- [PATCH] rename kernel.elf to kernel.img (Re: [PATCH] i386-qemu port), Robert Millan, 2009/06/21
- [PATCH] swap real_to_prot() and prot_to_real() (Re: [PATCH] i386-qemu port), Robert Millan, 2009/06/21
- Re: [PATCH] i386-qemu port, Robert Millan, 2009/06/21
- [PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port),
Robert Millan <=
- Re: [PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port), Pavel Roskin, 2009/06/21
- Re: [PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port), Robert Millan, 2009/06/22
- Re: [PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port), Pavel Roskin, 2009/06/22
- Re: [PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port), Robert Millan, 2009/06/22
- Re: [PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port), Robert Millan, 2009/06/22
- Re: [PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port), Pavel Roskin, 2009/06/22
- Re: [PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port), Robert Millan, 2009/06/22
- Re: [PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port), Pavel Roskin, 2009/06/22
- Re: [PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port), Robert Millan, 2009/06/23
- Re: [PATCH] access gdtdesc on segment 0 unconditionally (Re: [PATCH] i386-qemu port), Pavel Roskin, 2009/06/22