News for hackers. Stuff that matters.
Re:Booting to Rust by tinco on Monday November 18, 2013 @10:47PM (#6759150)
So I'm a bit confused, the article says the code is ran in 64bit mode, but before virtual memory is turned on. How is that possible?

I remember from the OSDev wiki that the only way to get a processor in 64 bit mode was by first turning on virtual memory. I remember because I was disappointed by that, it seems unnecessary.

Doesn't UEFI play by these rules, or am I misunderstanding?

Re:Booting to Rust by haberman on Monday November 18, 2013 @11:28PM (#6759266)
I think "turning on the MMU" is something a bit different than "turning on virtual memory." The former just means that all addresses are translated from virtual->physical, while the latter implies more abstraction: virtual memory can be overcommitted, pages might not be resident.

This is just a guess, but I'd wager that UEFI has the MMU enabled, but with an identity mapping that maps all virtual addresses to the same physical address.

Re:Booting to Rust by ivanca on Monday November 18, 2013 @10:50PM (#6759160)
"64-bit UEFI understands long mode, which allows applications in the pre-boot execution environment to have direct access to all of the memory using 64-bit addressing."

Source: http://en.wikipedia.org/wiki/Unified_Extensible_Firmware_Int...

Re:Booting to Rust by haberman on Monday November 18, 2013 @11:36PM (#6759296)
I believe that "long mode" is just the name for the native 64-bit mode of these processors; ie. what you'd normally run 64-bit Linux under, with the MMU enabled.