5. Link Layer - Part 1
5. Link Layer - Part 1
Link Layer
Computer
Networking: A
Top Down
Approach
6th edition
Jim Kurose, Keith
Ross
Addison-Wesley
March 2012
implements link,
physical layer host
bus
attaches into host’s link
controller (e.g., PCI)
hardware, software,
firmware network adapter
card
datagram datagram
controller controller
frame
otherwise
0 0
want:
D.2r XOR R = nG
equivalently:
D.2r = nG XOR R
equivalently:
if we divide D.2r
by G, want
remainder R to
satisfy:
D.2r
R = remainder[ ]
G
FDM cable
node 2 2 2 2
node 3 3 3 3
C E C S E C E S S
Pros: Cons:
single active node collisions, wasting
can continuously slots
transmit at full rate idle slots
of channel nodes may be able to
highly decentralized: detect collision in less
only slots in nodes than time to transmit
need to be in sync packet
simple clock synchronization
Link Layer 5-29
Slotted ALOHA: efficiency
!
efficiency: long-run at best:
fraction of successful channel
slots used for useful
(many nodes, all with transmissions
many frames to send) 37%
of time!
= p . (1-p)N-1 . (1-p)N-1
= p . (1-p)2(N-1)
= 1/(2e) = .18
even worse than slotted Aloha!
efficiency goes to 1
as tprop goes to 0
as ttrans goes to infinity
1
efficiency
better performance than ALOHA: and simple, cheap, decentralized!
1 5t prop /t trans
data
Link Layer 5-42
Summary of MAC
protocols
channel partitioning, by time, frequency or
code
Time Division, Frequency Division
random access (dynamic),
ALOHA, S-ALOHA, CSMA, CSMA/CD
carrier sensing: easy in some technologies
(wire), hard in others (wireless)
CSMA/CD used in Ethernet
CSMA/CA used in 802.11
taking turns
polling from central site, token passing
bluetooth, FDDI, token ring