CS401/CS746
(Linux) Kernel Programming
Spring 2016
Exercise #4 The aim of this exercise is to get familiar with implementing system calls.
Some references
- Adding system calls for Linux kernel 3.5.x
- Yet another, adding a new system call (kernel 3.8.7)
- How system calls work in Linux (tldp)
- Implementing a system call (Linux 2.6) (tldp)
- Linux system call table
- System calls quick reference
- system call interception 1
- system call interception 2
- Write a simple system call and a process that invokes it.
Test its correctness.
On issuing a system call, the call should print the pid and parent pid and also return the current process's ppid. - Write a linux kernel module to intercept this new new system call
and alter it's functionality in some other manner.
When the module is removed, original system call functionality should be restored.
Submit a step-by-step ordered process in which the above is achieved.
A in-class demo is required.