Language Selection

English French German Italian Portuguese Spanish

How System Calls Work in Linux?

Filed under
HowTos

Every GNU/Linux programmer here reading this article must have used system calls to code their programs. GNU/Linux programming is incomplete without system calls. System calls are initiated by software interrupts. Before we delve into that, however, let’s define system calls.

A system call is the mechanism used by an application program to request service from the operating system, or more specifically, the operating system kernel.

Modern processors execute instructions in different privilege states. In system, where just two levels are defined (as in i386), these states are known as user mode and supervisor mode. These privilege levels are defined so that an operating system restrict can control the operations performed by the program. Controlling is done for reasons of security and stability. The kernel of the operating system should always run in privilege mode since it needs to do some operations. Such operations include accessing hardware devices, enabling and disabling interrupts, changing privileged processor state, and accessing memory management units.

Now with this setup of an operating system (with two modes of execution (considering only i386 architecture only)), we need a mechanism to transfer control safety from lesser privileged modes to higher privileged modes.

Full Story.

More in Tux Machines

10 Reasons Why I Switched To Telegram Messenger

Whatsapp may be the best player in the game when it comes to instant messaging apps, but Telegram Messenger is the entire game itself. Read
more

How To Install Wine And Run Windows Apps In Linux

​All kinds of software are currently available on Linux but every now and then, there is that Windows software or Game which is not available or has no equivalent on Linux Wine makes it possible to run those Windows programs and Games on your Linux desktop. So let’s look at how to install Wine on Linux and run Windows apps on Linux desktop. Read
more

OSS Leftovers

Today in Techrights