Changes between Initial Version and Version 1 of SuggerimentiPageInit


Ignore:
Timestamp:
May 10, 2017, 7:18:52 AM (7 years ago)
Author:
Mattia Monga
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • SuggerimentiPageInit

    v1 v1  
     1Nella scrittura della `page_init` può essere utile riflettere sulle seguenti istruzioni (che potete provare all'interno di `page_init`)
     2
     3```c
     4        assert(IOPHYSMEM == npages_basemem * PGSIZE);
     5        assert(IOPHYSMEM/PGSIZE == npages_basemem);
     6        cprintf("EXTPHYSMEM:\t%08x (pa)\t%08x (kva)\n", EXTPHYSMEM, KADDR(EXTPHYSMEM));
     7        cprintf("nextfree:\t%08x (pa)\t%08x (kva)\n", boot_alloc(0), PADDR(boot_alloc(0)));
     8        assert(boot_alloc(0) == page2kva(&pages[PADDR(boot_alloc(0))/PGSIZE]));
     9
     10```