We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
You don't _need_ an OS to configure the MMU, but the processors that have an MMU are generally applications processors and will usually run an OS of some kind.
Think about the implications of giving user-mode applications the ability to enter supervisor mode!
You _can_ execute a SWI instruction to enter supervisor mode, but the call will be handled by the processor's SWI handler. In an environment with an OS, this is typically used for system calls.If you are running on an OS, it should configure the MMU and caches for you. If you have specific requirements (such as the ability to execute the contents of some memory or flush the caches), the OS may provide you with a library function to do that, but there is no generic way to do that from user space and the OS may not allow you to do it.If you are not running on an OS, you will want to turn on the MMU anyway, even if it has a flat memory map, as the I cache cannot be enabled without it. However, if you are not running on an OS you can have privileged access to whatever part of the processor you want.
Yes, but the operations will need to be performed by some privileged code. You will need OS support, usually in the form of a driver. If there is no driver available for your system, you will need to write one.