13
Presentation On: SYSTEM CALLS Reference Book : Operating System Organisation With Special Reference To UNIX By Satyapriya Bhattacharjee Presented by; Bernard Senam Parkoo MSc. II, DOS In Computer Science

System calls

Embed Size (px)

DESCRIPTION

Presentation on System Calls

Citation preview

Page 1: System calls

Presentation On:

SYSTEM CALLS

Reference Book :

Operating System Organisation With Special Reference To UNIX By Satyapriya Bhattacharjee

Presented by;Bernard Senam Parkoo

MSc. II, DOS In Computer Science

 

Page 2: System calls

Presentation Outline• What are System Calls

• Scenario of System Calls

• How a System Call Occurs

• Methods of Passing Parameters to the OS

• Categories of System Calls

Page 3: System calls

What are System Calls• System Calls provide the Interface between a

process and the Operating System.

• These calls are generally available as Assembly language instruction.

• System Calls can also be made directly through HLL programs for certain systems.

• UNIX System calls can be invoked directly from a C or C++ program.

Page 4: System calls

Scenario of System Calls

An Example of how system calls are used.• Consider a simple program to copy data from

one file to another file .• The first input of the program will be the name

of both files.• These names can be specified depending on

the design of Operation System• Once the file names are obtained, the program

opens an input file and create an output file• Each of this operations require other System

calls and may encounter possible error conditions.

Page 5: System calls

How System Calls Occur.System Calls occur in different ways depending on the computer in use:

• More information is required than just the identify of the desired System call.

• The exact type and amount of information varies according to the operation system and call

• For instance to get an input we need to specify the file of device to use as source and the address and length of memory buffer into which the input should be read.

Page 6: System calls

Methods of Passing Parameters to Operating

SystemThree methods are used in passing parameters to the operation system.

• The simplest is approach is to pass parameter through registers.

• The second is by storing parameters in blocks and passing the address through registers.

• Finally parameter can be pushed into stack by the program and popped of by the Operating System.

Page 7: System calls

Categories of System CallsSystem calls can be grouped into five major categories as follows.

• Process control• File management. • Device management• Information Maintenance and • Communication.

Page 8: System calls

Process controlSome system calls under process control are:

• End, abort• Load, execute• Create process, terminate process• Get process, terminate process• Wait for time• Allocate and free memory

Page 9: System calls

File management. Some system calls under file management are:

• Create file, delete file• Open , close• Read, write, reposition.• Get file attributes, set fil attributes

Page 10: System calls

Device managementSome system calls under device management are:

• Request Device, release device• Read, write, reposition.• Get device attributes and set device

attributes• Logically attach or detach devices

Page 11: System calls

Information MaintenanceSome system calls under information maintenance are:

• Get time or date, Set time of date• Logically attach or detach devices• Information maintenance• Get system data, Set Systems data• Get process, file of device attributes• Set process, file or device attributes

Page 12: System calls

Communication• Create, delete communication connection.• Send, receive messages• Transfer status information• Attach or detach remote devices.

Page 13: System calls

The End