Class Notes (1,000,000)
US (430,000)
UI (5,000)
ECE (100)
ECE 391 (10)
Lecture 9

ECE 391 Lecture 9: Programmable Interrupt Control

Electrical and Computer Engineering
Course Code
ECE 391
Kalbarczyk Zbigniew

This preview shows page 1. to view the full 4 pages of the document.
Programmable interrupt controller (PIC)
motivation & design
hardware for x86
Linux abstraction of PIC
Checkpoint 1 due by 6pm on 2/27
Review for exam Tuesday 21 in class
Reader/Writer Problem: The philosophers and Their Newspaper
each philosopher reads frequently, taking short breaks between
or just over another's shoulder
multiple philosophers may read at same time
Philosophers like to read newspaper
The writer can't update the data
What if newspaper is always being read? Starvation!
extension of spinlocks
user for short critical sections
ok to use in interrupt handlers
admit writer starvation (you must ensure that this not happen)
reader/writer spin locks (rwlock_t)
extension of semaphores
use only in system calls
do not admit writer starvation (new readers wait if writer is waiting)
reader/writer semaphores (struct rw_semaphore)
The writer should have priority?
Linux provides two types of reader/writer synchronization
Selecting a Synchronization Mechanism
General questions for synchronization of shared resouces
what are the operations?
what are their frequencies?
walk list and find min. age?
update min. age every time list changes?
what are the shared data
from master perspective, it knows which slave raised an interrupt but
doesn't know which slave's interrupt brought it up. It uses the cascade
to tell which slave to write its vector bit
From slaves perspective, it knows whether or not it has an interrupt
but doesn't know if it has priority that's why it needs cascade to tell it
has priority.
Lecture 9 - Programmable Interrupt Control
Tuesday, February 14, 2017
2:01 PM
ECE 391 - Lect Page 1
You're Reading a Preview

Unlock to view full version