Oh, my God! Stupid me, my test function actually reported the A20 line to be disabled if the words at addresses 0x7DFE and 0xFFFF:0x7E0E (which translates to 0x107DFE) are DIFFERENT, which means exactly the opposite.
THANK YOU SO MUCH! It works now.. the only thing I had to change were the two jumps: "jne .not_enabled" into "je .not_enabled".
Octocontrabass wrote:
Out of curiosity, what does your test code report if you run it before you try to disable A20? (If you're not using a bootloader like GRUB, A20 will already be disabled.)
It reported it's NOT enabled, when in fact it was. This is without me touching A20 before running the test. Howerver, I was actually trying to disable A20 before running the test, which (because the test function was doing exactly the opposite) lead it to report that A20 was enabled and so the attempts of enabling it were skipped.
Strangely enough, Bochs has the A20 line enabled by default, although I am using my own bootloader, not GRUB. Do you know why this happens? I actually remember encountering the same issue during my first attempt of writing an "OS".
Also, I really laughed when I read the reason why you said my ror was wrong, haha! That should have been word.. lol, I was rotating an 8-bit value 8 times..