Home » Computer Organization and Architecture » Computer organization and architecture miscellaneous » Question

Computer organization and architecture miscellaneous

Computer Organization and Architecture

  1. Normally user programs are prevented from handling I/O directly by I/O instructions in them. For CPUs having explicit I/O instructions, such I/O protection is ensured by having the I/O instructions privileged. In a CPU with memory mapped I/O, there is no explicit I/O instruction. Which one of the following is true for a CPU with memory mapped I/O?
    1. I/O protection is ensured by operating system routine(s)
    2. I/O protection is ensured by a hardware trap
    3. I/O protection is ensured during system configuration
    4. I/O protection is not possible
Correct Option: A

Memory mapped I/O means, accessing I/O via general memory access as opposed to specialized IO instructions. An example,
unsigned int volatile const *pMappedAddress const = (unsigned int *) 0 × 100;
So, the programmer can directly access any memory location directly. To prevent such an access, the OS (kernel) will divide the address space into kernel space and user space. An user application can easily access user application. To access kernel space, we need system calls (traps). So, IO protection is ensured by OS abstraction.



Your comments will be displayed only after manual approval.