All of lore.kernel.org
 help / color / mirror / Atom feed
From: Min Lee <min.lee@gatech.edu>
To: Mike Sun <msun@bluespot.org>
Cc: Xen-devel@lists.xensource.com
Subject: Re: Any available page table entry bits in Xen??
Date: Sun, 19 Oct 2008 05:07:07 -0400	[thread overview]
Message-ID: <48FAF8BB.7040804@gatech.edu> (raw)
In-Reply-To: <e4e579070810181904l17c656acwf3821800f15cdcac@mail.gmail.com>

Mike Sun wrote:
> Hi Min,
> 
>> I'd like to know if there's any available bit in page table entries, on
>> x86_32 (no pae),
>> especially on L1 page table entry. It seems to me that all bits are used by
>> Xen.
> 
> Could you clarify?  Are you referring to PTEs for para-virtualized
> guests (without translation) or fully translated domains like HVM
> guest with shadow paging?
> 
> I think for PV guests you're right, the PV guest OS cannot use of the
> bits in the PTE.  Some of those bits are used by Xen (though somehow I
> vaguely remember that though Xen reserves the use of those bits, they
> may not actually be used).
> 
> For HVM guests, the guest PTEs will carry whatever the guest OS uses,
> and in the shadow PTEs, I believe there are some bits not used by Xen
> (not totally sure).
> 
> Mike
> 

Hi, right, I'm talking about PV guest.
I'm working on 3.2.1 and xen disallow some bits as following..


/*
  * Disallow unused flag bits plus PAT/PSE, PCD, PWT and GLOBAL.
  * Permit the NX bit if the hardware supports it.
  */
#define BASE_DISALLOW_MASK (0xFFFFF198U & ~_PAGE_NX)


(snipped from include/asm/x86_32/page.h..
What this comment means? It only disallows GLOBAL/PAT/PCD/PWT bits,
so what is unused flag bits? It does't disallows AVAIL012 bits..
This is quite confusing comments.)

So first, I've disallowed all three AVAIL bits, and Linux doesn't boot 
well, it seems to use one of these AVAIL bits, so I could disallow two 
AVAIL bits with my Linux still booting up. So I thought I would be able 
to use these two AVAIL bits, which I'll work with.
But, I found that these two AVAIL bits change during Linux's boot time!
It's disallowed, so it must be Xen who have used these two bits, I guess.
But I don't really see any piece of code in Xen modifying AVAIL bits!
Xen doesn't seem to be using AVAIL bits except AVAIL2 for debugging 
purpose, which is disabled. So, then, who is touching my AVAIL bits???
Moreover, after Linux's boot time, nobody seems to use these two AVAIL 
bits..

Another question, I'd also like to use other bits -> GLOBAL/PAT/PCD/PWT 
bits, so how could I use them in xen?
For GLOBAL bit, I would be able to use it freely as long as PGE flag in 
CR4 is disabled, right?
Also for PAT/PCD/PWT bits, I guess I would be able to use them under 
some specific conditions..
thanks!

Min

  parent reply	other threads:[~2008-10-19  9:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-18 16:44 Any available page table entry bits in Xen?? Min Lee
2008-10-19  2:14 ` Mike Sun
     [not found] ` <e4e579070810181904l17c656acwf3821800f15cdcac@mail.gmail.com>
2008-10-19  9:07   ` Min Lee [this message]
     [not found]     ` <e4e579070810201951o479fd5c3j176a067918722e49@mail.gmail.com>
2008-10-21  4:37       ` Min Lee

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=48FAF8BB.7040804@gatech.edu \
    --to=min.lee@gatech.edu \
    --cc=Xen-devel@lists.xensource.com \
    --cc=msun@bluespot.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.