define system calls, Operating System

 

When a computer is started on, the program that executed first is named the ''operating system.'' It controls pretty much all applications in the computer. This adds who logs in, how disks are consumed, how memory is accessed, how the CPU is used.

The way that applications talk to the operating system is via ''system calls.'' A system call seems like a procedure call, but it's not same -- it is a request to the operating system to operate some application.

There are 5 basic system calls that Unix gives for file I/O.

        1.  int open(char *path, int flags [ , int mode ] );

        2.  int close(int fd);

        3.  int read(int fd, char *buf, int size);

        4.  int write(int fd, char *buf, int size);

        5.  off_t lseek(int fd, off_t offset, int whence);

The reason the operating system operates I/O is for safety -- the computer has to ensure that if my program has a exception in it, then it doesn't affect the system, and it doesn't collide other people's applications that can be running at later or the same time. Whenever you do screen or disk or network I/O, you have to go through the operating system and use system calls.

 

 

 

1541_System calls.png

Posted Date: 7/28/2012 8:12:03 AM | Location : United States







Related Discussions:- define system calls, Assignment Help, Ask Question on define system calls, Get Answer, Expert's Help, define system calls Discussions

Write discussion on define system calls
Your posts are moderated
Related Questions
Using pages makes it easier to manage the whole memory, avoiding excessive fragmentation and waste. As an analogy, think of Tetris, but with only square blocks: it is relatively ea

The principle is that of ordinary addition; however remember the highest number is 1.   Calculate the following:                             11001 +                           11

WHAT IS OPERATING SYSTEM ?ENLIST AND EXPLAIN BASIC SERVICES PROVIDE BY OS

Difference between cache and associate memory

Q. Explain about Deadlocks? Deadlocks for (int i = 0; i // first find a thread that can finish for (int j = 0; j if (!finish[j]) { boolean temp = true; for

KERNEL ACTIVITY FOR ULTS: The kernel isn't aware of thread activity but it is still managing process activity. When a thread compose a system call the whole process will be bl

Compare contiguous-memory allocation with pure paging in the following aspects: 1. In support of dynamic memory allocation: most systems allow programs to allocate more memory t

Q. When a process creates a fresh process using the fork() operation which of the following state is shared among the parent process and the child process? 1 Stack 2 Heap


Describe when you run an unlink() operation to remove a file on the ext3 file system. Be specific about what disk blocks have to be written where in what order. State your assumpti