in Operating System edited by
9,504 views
19 votes
19 votes

A computer handles several interrupt sources of which of the following are relevant for this question.

  • Interrupt from CPU temperature sensor (raises interrupt if CPU temperature is too high)
  • Interrupt from Mouse (raises Interrupt if the mouse is moved or a button is pressed)
  • Interrupt from Keyboard (raises Interrupt if a key is pressed or released)
  • Interrupt from Hard Disk (raises Interrupt when a disk read is completed)
Which one of these will be handled at the HIGHEST priority?
  1. Interrupt from Hard Disk
  2. Interrupt from Mouse
  3. Interrupt from Keyboard
  4. Interrupt from CPU temperature sensor
in Operating System edited by
9.5k views

3 Comments

Is D the right answer? How to check priority among different interrupts?
0
0
more like a common sense question.
0
0
0
0

1 Answer

65 votes
65 votes
Best answer

Answer should be (D) Higher priority interrupt levels are assigned to requests which, if delayed or interrupted,could have serious consequences. Devices with high speed transfer such as magnetic disks are given high priority, and slow devices such as keyboard receive low priority. We know that mouse pointer movements are more frequent than keyboard ticks. So its obvious that its data transfer rate is higher than keyboard. Delaying a CPU temperature sensor could have serious consequences, overheat can damage CPU circuitry. From the above information we can conclude that priorities are-

CPU temperature sensor > Hard Disk > Mouse > Keyboard

edited by

7 Comments

When mouse stops working(may be PC hanged because of load), you might open taskmanager by (Ctrl+Shift+Esc) or (Alt+Ctrl+Del). This clearly shows that keyboard has higher priority than mouse.

Am I right?

8
8

Dhaval Radadiya

and what if keyboard stop working.. ? then u can open task manager by mouse....in this case mouse has highest priority then...

8
8
This is some kind of stupid gate question :p
9
9
edited by

Interrupts from I/O are handled by APIC. The priorities are programmable and we can't say one I/O(such as keyboard or mouse) gets priority over the other. I have also read that linux kernel does not prioritize APIC interrupts in soft real-time systems. Here is a geeky discussion on APIC. https://arstechnica.com/civis/viewtopic.php?f=8&t=375414

4
4
Who wins Mouse vs Keyboard?
3
3
a simple drag of mouse from one point to other can generate huge number of pixels data to process, whereas a keyboard can generate only sequential data with very slow speed. so mouse wins here.
6
6
It seems to be Dead Lock then OS should handle this first.
0
0
Answer:

Related questions