io device drivers Flashcards

1
Q

what are device drivers

A

code to manage a device

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

single-instance devices

A

devices that can only be used by one process at a time e.g. printer

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

multi-instance devices

A

devices that can handle requests from multiple processes by creating another instance of the internal data structures
e.g. disk

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

what are the 4 tasks that device drivers carry out

A

io scheduling
caching
error handling
io protection management

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

how can device drivers provide protection for io devices

A

only allowed operations can be completed

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

raw devices

A

the operation and data are returned to the application

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

cooked devices

A

the operation is handled and the data is returned

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

how do device drivers schedule the operations that theyre carrying out

A

when it receives a set of request sit may reorder them to make the most efficient use of the underlying hardware
e.g. reorder reads and writes so they go with the natural flow of the head of the disk instead of going back and forth

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

character based devices

A

processes an arbitrary number of characters
no structure
e.g. terminal

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

block based devices

A

will carry out operations on a block of bytes at a time or a multiple of them
e.g. disks

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

what is unix’s interface orientation

A

file

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

in unix what does the device driver interface look like

A

file operation e.g. open()

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

in unix the os creates a table for each device driver operation
how is this used

A

the starting address of the routine to carry out the specific operation for that device driver is stored

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

how are device drivers an extensible model

A

they interact with the os via well defined knows published programming interfaces
developers write code that uses the os driver api to interact with the hardware

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

what is the benefit of modular os when adding device drivers

A

dont have to restart the system to do it
can dynamically add device drivers at runtime

How well did you know this?
1
Not at all
2
3
4
5
Perfectly