Operating System Chapterwise Notes of Galvin:System Structures

Pages>> 1 2 3 4 5 6 7 8
Here we are giving chapter wise notes of operating system based on operating system concepts by galvin

COMPUTER SYSTEM STRUCTURES

q) tell about generaL purpose computer system?
a) it consists of cpu and number of device cntollers connected through common bus, that provides access to memory.

q) what is job of memory contoller?
a) to ensure orderly access to shared memory,ie provides synchonization.

q) when computer is powered which is first program that runs?
a) bootstrap loader(present in ROM). it loads o.s into memory .

q) what operating system do then?
a) it then start executing the first process, such as "init" and waits for some event to take place.

note:- modern o.s are interuppt driven.interuppt by hardware is called interuppt only.software do this by executing a special operation called system call.

q) what is interrupt vector?
a) given only predefined number of interrupts, a table of pointers to interrupt routines can be used . it is placed in low memory. this table of pointers is called interrupt vector.it is indexed by unique device numbers.

q) name some o.s that use interrupt vector scheme to dispatch interrupts?
a) ms-dos and unix.

q) what do device contoller has generally?
a) buffer storage and set of special registers.

q) give an example of interrupt by i/o device?
a) suppose cpu asked device controller to perform read operation. after read operation is performed and data is in device controllers's buffer, it makes interrupt to the cpu.

q) what is device status table?
a) it is the way by which o.s keeps track of many i/o requests at same time. it keeps information like device type,address,state. if device is busy then a queue is formed for that device entry.

q) if a interrupt arrives and cpu is in middle of some instruction, then what happens?
a) interrupt is held pending till execution of instruction completes.after that address of instruction about to be executed is saved then interrupt is handled by transferring control to appropriate service routine.

q) when a terminal sends input to computer ,who sends interrupt to cpu?
a) the serial port to which terminal is connected.

q) what do interrupt service routine do , when a character input interrupt is there?
a) takes character from device to buffer. sets pointer and flag for other parts of operating system for processing the buffer.

note:- fast devices like disk,tape etc transmit information close to memory speed, then cpu does not get much time for execution.

q) what is solution to above problem?
a) dma(direct memory access) for high speed i/o devices.

q) tell something about dma?
a) here device controller sends dierctly the entire block of data to or from its own buffer storage to memory.

q) is in dma cpu is nowhere?
a) only 1 interrupt per block is generated . whereas low-speed devices generate 1 interrupt per byte.

q) what is role of device driver here?
a) it sets the dma contoller register to use appropriate source and destination addresses and transfer length.

q) what is cycle stealing?
a) since memory can transfer only 1 word at a time , dma steals memory cycles from cpu. this cycle stealing slows down the cpu execution.

q) how cpu access ram or main memory?
a) through load and store instructions.

q) what is memory -mapped i/o?
a) here ranges of memory addresses are set aside and are mapped to device registers.

q) what is programmed i/o?
a) when cpu constantly loops to see control bit, to see whether device is ready or not. this mode of operation is called programmed i/o.

q) to what is r/w head of disk attached?
a) to disk arm.

q) define transfer rate, positioning time?
a) 1) Tranfer rate:- rate at which data flows b/w drive and computer.

2) positioning time:- it consists of seek time ie time taken to move r/w head to desired cylinder and
rotaional latency ie time for derised sector to rotate to disk head.

q) what is head crash?
a) the head files over the disk surface, there is danger of its coming in contact with disk. sometimes head may damage the disk surface. this is called head crash.

q) give example of removable disk?
a) floppy disk. they have only 1 platter.

q) why floppy disks rotate slowly than the hard disks?
a) bcoz in them head sits directly on the surface.

q) how disk is attached to computer?
a) by i/o bus. different kinds of buses are "enhanced integrated drive electronics"(eide), advanced technology attachment
(ata).

q) tell little about data transfer b/w computer and disk?
a) transfer carried out by electronic processors called contollers. host controller(computer side of bus). disk controller on disk drive. disks have built in cache. transfer takes b/w cache and host controller.

q) tell hierarchy of storage meduim in decreasing order of speed and cost?
a) registers, cache, main memory (all these use semiconductor technology) ,electronic disk,magnetic disk,magnetic tape.

note:- left to electronic disk are volatile and to right are non volatile. it can be both.

note:- electronic disk have DRAM as well as hidden magnetin disk with battery backup.

note:- data transfer b/w cache and registers and cpu is a hardware function with no o.s intervention. o.s plays role in
disk to memory.

q) what is cache coherency?
a) multiprocessors with their own caches . so if same data in all caches. an update to data in 1 cache need to be updated in all. it is called cache coherency and is a hardware problem. it does not come into scene in case where only 1 process runs at a time.

note:-before o.s came complete control was in the hands of the programmer.

q) what was name given to early operating systems?
s) resident monitors.

q) what is mode bit?
a) it is a bit added to hardware of computer to tell whether it is user mode or monitor mode.

q) when system starts then it is in which mode?
a) monitor mode.

q) why we use dual mode?
a) it protects o.s from errant users and also users from one another. some machine instructions that may cause problem are called privileged instrucions can execute only in monitor mode.

q) what is system call?
a) when user request execution of priveleged instruction, such request is called system call. it is treated by hardware as software interrupt.

note:- ms-dos for intel8088 didn't had this facility.recent intel pentium provide dual mode.

q) what is given addittional with system call?
a) type of service needed as parameter.addittional info can be passed to registers,stack etc.

q) tell some previlege instructions?
a) all i/o instructions and instructions that modify operation of timer.

q) what main thing we need to protect in case of memory protection?
a) interrupt vector and interrupt service routines.

q) what in cpu protection?
a) user may get struck in loop, and not transferring control to operating system.

q) what is used to achieve this protection?
a) timer is used. counter decrements every 1 milliseconds(say) and when it reaches 0,interrupt occurs.

note:- timer also plays a important role in time sharing.

q) what is context switch?
a) after time slice of 1 process has finished, o.s add N to record that for how long process executed, saves its state and make changes for another process to get executed.
note:- some o.s use timer to compute current time. some have separate hardware for it, independent of o.s.


q) what for lan came?
a) to substitute mainframe computers.

q) main media in lan?
a) twisted pair cables and fibre optics.

q) media in wan?
a) telephone lines,microwave links,satellites.

note:- in wan special communication processors define interfaces through which sites communicate.

Pages>> 1 2 3 4 5 6 7 8

Reblog this post [with Zemanta]

0 comments:

Post a Comment