Error detection . Error detection occurs at both the hardware and software levels. At the hardware level, all data transfers must be inspected to ensure that data have not been corrupted in transit. All data on media must be checked to be sure they have not changed since they were written to the media. Also, by having errors processed by the operating system, processes need not contain code to catch and correct all the errors possible on a system.
System calls provide the interface between a process and the operating system.
These calls generally can be made in assembly programs, some system may allow the calls to be made directly from a higher-level language program. System programs provide a more convenient environment for program develop and execution. Some of them are simply user interfaces to system calls, whereas others are considerably more complex. The main advantage of the layered approach is modularity. The layers are selected such that each uses functions and services of only lower layers.