Added support for flags in mmap

This commit is contained in:
2020-07-18 13:16:10 -05:00
parent 74fb6834f6
commit 048211a876
3 changed files with 13 additions and 6 deletions

View File

@@ -19,7 +19,7 @@ extern MemoryMap::Region memory_map;
void main(char* cmdline)
{
TTY tty((char*) 0xC00B8000);
tty << PACKAGE_STRING << '\n';
tty << PACKAGE_STRING << "\n\n";
tty << "Low memory: \t" << (int) system_info.getLowMemory() << " KiB\n";
tty << "High memory:\t" << (int) system_info.getHighMemory() << " KiB\n";
tty << "Type\t\tLocation\t\tSize\n";
@@ -32,7 +32,7 @@ void main(char* cmdline)
}
BuddyAllocator alloc(memmap, (char*) 0xC0000000, system_info.getHighMemory() / 4 + 256, 6);
AddressSpace vmem(alloc);
vmem.mmap((void*) 0x80000000, 0x10000);
vmem.mmap((void*) 0x80000000, 0x10000, MMAP_RW);
outb(0xa1, 0xff);
outb(0x21, 0xff);
tty << "Nothing left to do. Hanging.\n";