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

Linux Mint Debian Might Not Adopt Systemd

The Linux Mint team has ended 2014 in force with a great Linux Mint 17.1 "Rebecca" release, for both the MATE and Cinnamon desktop, but it looks like the Debian edition is also going to be interesting. Read more

Latest SteamOS Update Brings New NVIDIA and AMD Drivers

SteamOS, a Linux distribution based on Debian and developed by Valve that aims to provide the best gaming experience, has been updated by its makers and a new Beta version has been released. Read more

Your Old Computer Can Live Again with Emmabuntüs 2

Emmabuntüs 2 1.09, a distribution created for reconditioning old computers and relying on the robustness of Xubuntu 12.04.5 LTS, has been released and is now ready for download. The Emmabuntüs developers only use LTS editions of Xubuntu, and that means they actually have two distros out right now that are maintained and improved. We had Emmabuntüs 3 1.0 released a few weeks ago, but that one was using Xubuntu 14.04 LTS as the base. Now, the old branch based on Xubuntu 12.04, Emmabuntüs 2, has been improved as well and the devs have made quite a few changes. Read more

11 years developing Krita

Back in 2003 Krita had never been released and the application was only able to do some very crude painting. I think the main reason that I started contributing to Krita back then was that I was much more comfortable with the single window UI and the fact that it used Qt/KDE and C++. In the early days I would never have imagined that I would be still with the project after 10+ years and how big the project is now. Even that the project exists today is a miracle and result of many developers putting in effort without ever knowing how it would develop. For the first few years we had almost no users and the users that we had were die-hard KDE users. At the time that wasn’t a bad thing as it allowed us to do some radical changes and experiments. Many features that were developed during this time still provide the base for the current Krita. Read more