Page 1 of 1

Is there anything special in 0~0x100000?

Posted: Mon Aug 09, 2021 8:03 am
by couriernew
I tried to change it but it won't change. Here is my code.

Code: Select all

    char *str = (char*)(0x100000 - 1600);

    //memset(str, 0, 1600);

    for(int j = 0; j < 40; j++)
    {
        for(int i = 0; i < 40; i++)
        {
            kprintf("%d ", str[j * 40 + i]);
        }
        kprintf("\n");
    }
Whether I removed '//' before memset(str, 0, 1600) or not, the output I saw is always the same.
(Sorry for my suck English.)
My kernel runs on Bochs 2.7

Re: Is there anything special in 0~0x100000?

Posted: Tue Aug 10, 2021 9:38 pm
by Octocontrabass
There is RAM from 0 to 0x9FFFF, then MMIO from 0xA0000-0xDFFFF, then ROM from 0xE0000-0xFFFFF.

You're trying to modify ROM.