[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] How works Xen mmu ?


  • To: xen-devel@xxxxxxxxxxxxxxxxxxx
  • From: Sylvestre Gallon <syl@xxxxxxxxx>
  • Date: Tue, 25 May 2010 15:07:38 +0200
  • Delivery-date: Tue, 25 May 2010 06:08:53 -0700
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:from:date:x-google-sender-auth:message-id :subject:to:content-type; b=HhJzXsp3BiYUASqpG+IRyR/FDBXKURjoPtusjcb8TtwRuBi/MZGDq8tZjLFvxUkk7F Buo4LIkXvVqFHERTc9Gq7Yxav680bDmJvmztTfTFk92ieWbH5Iis2eXv/eIObyOhSqpL R/I/a5d6lpxU7+d9CX2qvVbZQ3It/RgrOeA8s=
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>

Hi,

I am trying to port an homemade operating system in Dom0 but I have a
problem with mmu operation. I have read Xen docs and mailling lists
archives and I  still do not understand well how mmu works on Xen.

My need is to simply perform an identity mapping at 0xb8000 to allow
my operating system to access the vga frammebuffer. So my first idea
was to use HYPERVISOR_mmu_update like this :

mmu_update_t mmu;
uint8_t *buf = (uint8_t *) 0xb8000;

mmu.ptr = 0xb8000 | MMU_MACHPHYS_UPDATE
mmu.val = 0xb8000
HYPERVISOR_mmu_update(&mmu, 1, NULL, DOMID_SELF);

buf[0] = 'a';
buf[1] = 0x7;

But it does not work :/

After that I was think that I need to put in mmu.val the exact entry
for the PTE (add R/W flags, present flags etc...) So I have replaced
mmu.val = 0xb8000 by mmu.val = 0xb8003 but it still not work....

Can you help me please, I am stuck :/

-- 
Sylvestre Gallon

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.