Menu
support@authoritypapers.com
+1(805) 568 7317

1 in this assignment you will implement a simulation of theinteraction of user progr 5123728

1.- In this assignment you will implement a simulation of theinteraction of user programs with the OS to execute an I/Ooperation. User programs: User programs will communicate with DOIO (OS) to request an I/Ooperation. (this will simulate a system call) User programs will give to DOIO two parameters: User id and anaddress (addr is a random number in the range 1 and 20.) (addr isan integer that represents a track number in the hard drive). User programs will pass the parameters to DOIO through twobuffers of size one each (bufid and bufaddr). Once the parameters are stored in the buffers, user programsexecutes a P(request served) operation to wait for the completionof the I/O operation. There will be one user running concurrently and it will execute5 I/O operations. DOIO: DOIO will collect an id and address(addr) from bufid and bufaddrto assemble the IORB. DOIO will store the IORB (id and addr) into two buffers thatrepresent the IORQ (iorqid and iorqaddr). Device driver: Device driver will collect an IORB (pair id and addr) fromiorqid and iorqaddr and then initiates the physical I/O operationon the hard drive and wait for the I/O operation to be completed:P(operation complete). The device driver initiate the physical I/O operation by storingaddr into a buffer of length one. The buffer name is “pio”(physical I/O). When the I/O operation completes a signal is received, thedriver will identify the user that issued the I/O request using theid, and will signal the semaphore “request served” associated tothe user. Disk: The disk process simulates the access to a track in the harddrive. The Disk process gets the addr from pio   and storesit in a variable called “seek” and iterates in a dummy loop from 1to “seek”. Once out of the loop, disk will execute a V on the semaphore“operation complete”   Define all semaphores that you need according to the number ofbuffers used. The user will make 5 system calls to initiate I/O operations DOIO will create 5 IORB     example of console print is User 1 executes system call SIO or DOIO DOIO assembles IORB and inserts it in IORQ Driver initiates I/O operation for user 1 Disk Completes I/O operation (disk does not know what processinitiated the I/O operation) Driver signal user 1 (operation complete) User 1 executes system call SIO or DOIO DOIO assembles IORB and inserts it in IORQ . . .

"Order a similar paper and get 15% discount on your first order with us
Use the following coupon
"GET15"

Order Now