<s>
In	O
computing	O
,	O
channel	B-Device
I/O	I-Device
is	O
a	O
high-performance	O
input/output	B-General_Concept
(	O
I/O	B-General_Concept
)	O
architecture	O
that	O
is	O
implemented	O
in	O
various	O
forms	O
on	O
a	O
number	O
of	O
computer	O
architectures	O
,	O
especially	O
on	O
mainframe	B-Architecture
computers	I-Architecture
.	O
</s>
<s>
In	O
the	O
past	O
,	O
channels	O
were	O
generally	O
implemented	O
with	O
custom	O
devices	O
,	O
variously	O
named	O
channel	O
,	O
I/O	B-Device
processor	I-Device
,	O
I/O	B-General_Concept
controller	O
,	O
I/O	B-General_Concept
synchronizer	O
,	O
or	O
DMA	B-General_Concept
controller	I-General_Concept
.	O
</s>
<s>
Many	O
I/O	B-General_Concept
tasks	O
can	O
be	O
complex	O
and	O
require	O
logic	O
to	O
be	O
applied	O
to	O
the	O
data	O
to	O
convert	O
formats	O
and	O
other	O
similar	O
duties	O
.	O
</s>
<s>
In	O
these	O
situations	O
,	O
the	O
simplest	O
solution	O
is	O
to	O
ask	O
the	O
CPU	B-Device
to	O
handle	O
the	O
logic	O
,	O
but	O
because	O
I/O	B-General_Concept
devices	I-General_Concept
are	O
relatively	O
slow	O
,	O
a	O
CPU	B-Device
could	O
waste	O
time	O
(	O
in	O
computer	O
perspective	O
)	O
waiting	O
for	O
the	O
data	O
from	O
the	O
device	O
.	O
</s>
<s>
This	O
situation	O
is	O
called	O
'	O
I/O	B-General_Concept
bound	O
 '	O
.	O
</s>
<s>
Channel	O
architecture	O
avoids	O
this	O
problem	O
by	O
processing	O
some	O
or	O
all	O
of	O
the	O
I/O	B-General_Concept
task	O
without	O
the	O
aid	O
of	O
the	O
CPU	B-Device
by	O
offloading	O
the	O
work	O
to	O
dedicated	O
logic	O
.	O
</s>
<s>
Channels	O
are	O
logically	O
self-contained	O
,	O
with	O
sufficient	O
logic	O
and	O
working	O
storage	O
to	O
handle	O
I/O	B-General_Concept
tasks	O
.	O
</s>
<s>
Some	O
are	O
powerful	O
or	O
flexible	O
enough	O
to	O
be	O
used	O
as	O
a	O
computer	O
on	O
their	O
own	O
and	O
can	O
be	O
construed	O
as	O
a	O
form	O
of	O
coprocessor	B-General_Concept
,	O
for	O
example	O
,	O
the	O
7909	O
Data	O
Channel	O
on	O
an	O
IBM	B-Device
7090	I-Device
or	O
IBM	B-Device
7094	I-Device
;	O
however	O
,	O
most	O
are	O
not	O
.	O
</s>
<s>
A	O
CPU	B-Device
typically	O
designates	O
a	O
block	B-General_Concept
of	O
storage	O
as	O
,	O
or	O
sends	O
,	O
a	O
relatively	O
small	O
channel	O
program	O
to	O
the	O
channel	O
in	O
order	O
to	O
handle	O
I/O	B-General_Concept
tasks	O
,	O
which	O
the	O
channel	O
and	O
controller	O
can	O
,	O
in	O
many	O
cases	O
,	O
complete	O
without	O
further	O
intervention	O
from	O
the	O
CPU	B-Device
(	O
exception	O
:	O
those	O
channel	O
programs	O
which	O
utilize	O
'	O
program	O
controlled	O
interrupts	B-Application
 '	O
,	O
PCIs	B-Protocol
,	O
to	O
facilitate	O
program	O
loading	O
,	O
demand	O
paging	O
and	O
other	O
essential	O
system	O
tasks	O
)	O
.	O
</s>
<s>
When	O
I/O	B-General_Concept
transfer	O
is	O
complete	O
or	O
an	O
error	O
is	O
detected	O
,	O
the	O
controller	O
typically	O
communicates	O
with	O
the	O
CPU	B-Device
through	O
the	O
channel	O
using	O
an	O
interrupt	B-Application
.	O
</s>
<s>
Since	O
the	O
channel	O
normally	O
has	O
direct	O
access	O
to	O
the	O
main	O
memory	O
,	O
it	O
is	O
also	O
often	O
referred	O
to	O
as	O
a	O
direct	B-General_Concept
memory	I-General_Concept
access	I-General_Concept
(	O
DMA	O
)	O
controller	O
.	O
</s>
<s>
In	O
the	O
most	O
recent	O
implementations	O
,	O
the	O
channel	O
program	O
is	O
initiated	O
and	O
the	O
channel	O
processor	O
performs	O
all	O
required	O
processing	O
until	O
either	O
an	O
ending	O
condition	O
or	O
a	O
program	O
controlled	O
interrupt	B-Application
(	O
PCI	B-Protocol
)	O
.	O
</s>
<s>
This	O
eliminates	O
much	O
of	O
the	O
CPU	B-Device
—	O
Channel	O
interaction	O
and	O
greatly	O
improves	O
overall	O
system	O
performance	O
.	O
</s>
<s>
In	O
some	O
systems	O
an	O
I/O	B-General_Concept
controller	O
can	O
request	O
an	O
automatic	O
retry	O
of	O
some	O
operations	O
without	O
CPU	B-Device
intervention	O
.	O
</s>
<s>
In	O
earlier	O
implementations	O
,	O
any	O
error	O
,	O
no	O
matter	O
how	O
small	O
,	O
required	O
CPU	B-Device
intervention	O
,	O
and	O
the	O
overhead	O
was	O
,	O
consequently	O
,	O
much	O
higher	O
.	O
</s>
<s>
A	O
program-controlled	O
interruption	O
(	O
PCI	B-Protocol
)	O
is	O
still	O
used	O
by	O
certain	O
legacy	O
operations	O
,	O
but	O
the	O
trend	O
is	O
to	O
move	O
away	O
from	O
such	O
PCIs	B-Protocol
,	O
except	O
where	O
unavoidable	O
.	O
</s>
<s>
The	O
first	O
use	O
of	O
channel	B-Device
I/O	I-Device
was	O
with	O
the	O
IBM	B-Device
709	I-Device
vacuum	O
tube	O
mainframe	B-Architecture
,	O
whose	O
Model	O
766	O
Data	O
Synchronizer	O
was	O
the	O
first	O
channel	B-Device
controller	I-Device
,	O
in	O
1957	O
.	O
</s>
<s>
Its	O
transistorized	O
successor	O
,	O
the	O
IBM	B-Device
7090	I-Device
,	O
had	O
two	O
to	O
eight	O
6-bit	O
channels	O
(	O
the	O
7607	O
)	O
and	O
a	O
channel	O
multiplexor	O
(	O
the	O
7606	O
)	O
which	O
could	O
control	O
up	O
to	O
eight	O
channels	O
.	O
</s>
<s>
However	O
,	O
some	O
systems	O
,	O
e.g.	O
,	O
GE-600	B-Device
series	I-Device
,	O
had	O
more	O
sophisticated	O
I/O	B-General_Concept
architectures	O
.	O
</s>
<s>
Later	O
,	O
for	O
larger	O
IBM	B-Application
System/360	I-Application
and	O
System/370	B-Device
computers	O
the	O
channels	O
were	O
still	O
bulky	O
and	O
expensive	O
separate	O
components	O
,	O
such	O
as	O
the	O
IBM	O
2860	O
Selector	O
channel	O
(	O
one	O
to	O
three	O
selector	O
channels	O
in	O
a	O
single	O
box	O
)	O
,	O
the	O
IBM	O
2870	O
Byte	O
multiplexor	O
channel	O
(	O
one	O
multiplexer	O
channel	O
,	O
and	O
,	O
optionally	O
,	O
one	O
selector	O
subchannel	O
in	O
a	O
single	O
box	O
)	O
,	O
and	O
the	O
IBM	O
2880	O
Block	B-General_Concept
multiplexor	O
channel	O
(	O
one	O
or	O
two	O
block	B-General_Concept
multiplexor	O
channels	O
in	O
a	O
single	O
box	O
)	O
.	O
</s>
<s>
On	O
the	O
303x	B-Device
processor	O
complexes	O
,	O
IBM	O
abandoned	O
that	O
implementation	O
and	O
used	O
the	O
same	O
cycle-stealing	O
implementation	O
as	O
on	O
the	O
370/158	O
.	O
</s>
<s>
No	O
subsequent	O
product	O
in	O
the	O
System/360	B-Application
line	O
had	O
hardwired	O
channels	O
.	O
</s>
<s>
Amdahl	O
Corporation	O
's	O
hardware	O
implementation	O
of	O
System/370	B-Device
compatible	O
channels	O
was	O
quite	O
different	O
.	O
</s>
<s>
Each	O
"	O
C-Unit	O
"	O
independently	O
performed	O
a	O
process	O
generally	O
called	O
a	O
"	O
shifting	O
channel	O
state	O
processor	O
"	O
(	O
a	O
type	O
of	O
barrel	B-Operating_System
processor	I-Operating_System
)	O
,	O
which	O
implemented	O
a	O
specialized	O
finite	B-Architecture
state	I-Architecture
machine	I-Architecture
(	O
FSM	O
)	O
.	O
</s>
<s>
Each	O
CPU	B-Device
cycle	O
,	O
every	O
32	O
nanoseconds	O
in	O
the	O
470V/6	O
and	O
/5	O
and	O
every	O
26	O
nanoseconds	O
in	O
the	O
470V/7	O
and	O
/8	O
,	O
the	O
"	O
C-unit	O
"	O
read	O
the	O
complete	O
status	O
of	O
next	O
channel	O
in	O
priority	O
sequence	O
and	O
its	O
I/O	B-Device
Channel	I-Device
in-tags	O
.	O
</s>
<s>
The	O
necessary	O
actions	O
defined	O
by	O
that	O
channel	O
's	O
last	O
state	O
and	O
its	O
in-tags	O
were	O
performed	O
:	O
data	O
was	O
read	O
from	O
or	O
written	O
to	O
main	O
storage	O
,	O
the	O
operating	O
system	O
program	O
was	O
interrupted	O
if	O
such	O
interruption	O
was	O
specified	O
by	O
the	O
channel	O
program	O
's	O
Program	O
Control	O
Interrupt	B-Application
flag	O
,	O
and	O
the	O
"	O
C-Unit	O
"	O
finally	O
stored	O
that	O
channel	O
's	O
next	O
state	O
and	O
set	O
its	O
I/O	B-Device
Channel	I-Device
out-tags	O
,	O
and	O
then	O
went	O
on	O
to	O
the	O
next	O
lower	O
priority	O
channel	O
.	O
</s>
<s>
Channels	O
could	O
be	O
easily	O
reconfigured	O
to	O
the	O
customer	O
's	O
choice	O
of	O
selector	O
,	O
byte	O
multiplexor	O
)	O
or	O
block	B-General_Concept
multiplexor	O
channel	O
,	O
without	O
any	O
significant	O
restrictions	O
by	O
using	O
maintenance	O
console	O
commands	O
.	O
</s>
<s>
A	O
real	O
game-changer	O
,	O
and	O
this	O
forced	O
IBM	O
to	O
redesign	O
its	O
mainframes	B-Architecture
to	O
provide	O
similar	O
channel	O
capability	O
and	O
flexibility	O
.	O
</s>
<s>
IBM	O
's	O
initial	O
response	O
was	O
to	O
include	O
stripped-down	O
Model	O
158s	O
,	O
operating	O
in	O
"	O
Channel	O
Mode	O
"	O
,	O
only	O
,	O
as	O
the	O
Model	O
303x	B-Device
channel	O
units	O
.	O
</s>
<s>
In	O
the	O
Amdahl	O
"	O
C-unit	O
"	O
any	O
channel	O
could	O
be	O
any	O
type	O
,	O
selector	O
,	O
byte	O
multiplexor	O
)	O
or	O
block	B-General_Concept
multiplexor	O
,	O
without	O
reserving	O
channels	O
0	O
and	O
4	O
for	O
the	O
byte	O
multiplexers	O
,	O
as	O
on	O
some	O
IBM	O
models	O
.	O
</s>
<s>
For	O
smaller	O
IBM	O
computers	O
,	O
System/360	B-Application
Models	O
50	O
and	O
below	O
,	O
and	O
System/370	B-Device
Models	O
158	O
and	O
below	O
,	O
channels	O
were	O
implemented	O
in	O
the	O
CPU	B-Device
's	O
microcode	B-Device
,	O
and	O
the	O
CPU	B-Device
itself	O
operated	O
in	O
one	O
of	O
two	O
modes	O
,	O
either	O
"	O
CPU	B-Device
Mode	O
"	O
or	O
"	O
Channel	O
Mode	O
"	O
,	O
with	O
the	O
channel	O
mode	O
'	O
stealing	O
 '	O
cycles	O
from	O
the	O
CPU	B-Device
mode	O
(	O
IBM	O
2860	O
,	O
2870	O
and	O
2880	O
,	O
and	O
Amdahl	O
channels	O
had	O
dedicated	O
hardware	O
)	O
.	O
</s>
<s>
Some	O
of	O
the	O
earliest	O
commercial	O
non-IBM	O
channel	O
systems	O
were	O
on	O
the	O
UNIVAC	B-Device
490	I-Device
,	O
CDC	B-Device
1604	I-Device
,	O
Burroughs	B-Device
B5000	I-Device
,	O
UNIVAC	O
1107	O
and	O
GE	B-Device
635	I-Device
.	O
</s>
<s>
Since	O
then	O
,	O
channel	B-Device
controllers	I-Device
have	O
been	O
a	O
standard	O
part	O
of	O
most	O
mainframe	B-Architecture
designs	O
and	O
primary	O
advantage	O
mainframes	B-Architecture
have	O
over	O
smaller	O
,	O
faster	O
,	O
personal	O
computers	O
and	O
network	O
computing	O
.	O
</s>
<s>
The	O
1965	O
CDC	B-Device
6600	I-Device
supercomputer	B-Architecture
utilized	O
10	O
logically	O
independent	O
computers	O
called	O
peripheral	O
processors	O
(	O
PPs	O
)	O
and	O
12	O
simple	O
I/O	B-Device
channels	I-Device
for	O
this	O
role	O
.	O
</s>
<s>
PPs	O
were	O
a	O
modified	O
version	O
of	O
CDC	O
's	O
first	O
personal	O
computers	O
,	O
the	O
12-bit	O
CDC	B-Device
160	I-Device
and	O
160A	O
.	O
</s>
<s>
The	O
channels	O
had	O
no	O
direct	O
access	O
to	O
memory	O
and	O
could	O
not	O
cause	O
interrupts	B-Application
;	O
software	O
on	O
a	O
PP	O
used	O
synchronous	O
instructions	O
to	O
transfer	O
data	O
between	O
the	O
channel	O
and	O
either	O
the	O
A	O
register	O
or	O
PP	O
memory	O
.	O
</s>
<s>
Much	O
later	O
,	O
the	O
channels	O
were	O
implemented	O
as	O
an	O
on-board	O
processor	O
residing	O
in	O
the	O
same	O
box	O
as	O
the	O
CPU	B-Device
,	O
generally	O
referred	O
to	O
as	O
a	O
"	O
channel	O
processor	O
"	O
,	O
and	O
which	O
was	O
usually	O
a	O
RISC	B-Architecture
processor	I-Architecture
,	O
but	O
which	O
could	O
be	O
a	O
System/390	O
microprocessor	O
with	O
special	O
microcode	B-Device
as	O
in	O
IBM	O
's	O
CMOS	B-Device
mainframes	B-Architecture
.	O
</s>
<s>
SCSI	B-Architecture
introduced	O
in	O
1981	O
as	O
a	O
low	O
cost	O
channel	O
equivalent	O
to	O
the	O
IBM	O
Block	B-General_Concept
Multiplexer	O
Channel	O
is	O
now	O
ubiquitous	O
in	O
the	O
form	O
of	O
Fibre	B-Architecture
Channel	I-Architecture
and	O
Serial	O
Attached	O
SCSI	B-Architecture
.	O
</s>
<s>
Modern	O
computers	O
may	O
have	O
channels	O
in	O
the	O
form	O
of	O
bus	B-Architecture
mastering	I-Architecture
peripheral	O
devices	O
,	O
such	O
as	O
PCI	B-Protocol
direct	B-General_Concept
memory	I-General_Concept
access	I-General_Concept
(	O
DMA	O
)	O
devices	O
.	O
</s>
<s>
The	O
rationale	O
for	O
these	O
devices	O
is	O
the	O
same	O
as	O
for	O
the	O
original	O
channel	B-Device
controllers	I-Device
,	O
namely	O
off-loading	O
transfer	O
,	O
interrupts	B-Application
,	O
and	O
context	B-Operating_System
switching	I-Operating_System
from	O
the	O
main	O
CPU	B-Device
.	O
</s>
<s>
Channel	B-Device
controllers	I-Device
have	O
been	O
made	O
as	O
small	O
as	O
single-chip	O
designs	O
with	O
multiple	O
channels	O
on	O
them	O
,	O
used	O
in	O
the	O
NeXT	O
computers	O
for	O
instance	O
.	O
</s>
<s>
The	O
reference	O
implementation	O
of	O
channel	B-Device
I/O	I-Device
is	O
that	O
of	O
the	O
IBM	B-Application
System/360	I-Application
family	O
of	O
mainframes	B-Architecture
and	O
its	O
successors	O
,	O
but	O
similar	O
implementations	O
have	O
been	O
adopted	O
by	O
IBM	O
on	O
other	O
lines	O
,	O
e.g.	O
,	O
1410	B-Device
and	I-Device
7010	I-Device
,	O
7030	B-Device
,	O
and	O
by	O
other	O
mainframe	B-Architecture
vendors	O
,	O
such	O
as	O
Control	O
Data	O
,	O
Bull	O
(	O
General	O
Electric/Honeywell	O
)	O
and	O
Unisys	O
.	O
</s>
<s>
Computer	O
systems	O
that	O
use	O
channel	B-Device
I/O	I-Device
have	O
special	O
hardware	O
components	O
that	O
handle	O
all	O
input/output	B-General_Concept
operations	O
in	O
their	O
entirety	O
independently	O
of	O
the	O
systems	O
 '	O
CPU(s )	O
.	O
</s>
<s>
The	O
CPU	B-Device
of	O
a	O
system	O
that	O
uses	O
channel	B-Device
I/O	I-Device
typically	O
has	O
only	O
one	O
machine	B-Language
instruction	I-Language
in	O
its	O
repertoire	O
for	O
input	B-General_Concept
and	I-General_Concept
output	I-General_Concept
;	O
this	O
instruction	O
is	O
used	O
to	O
pass	O
input/output	B-General_Concept
commands	O
to	O
the	O
specialized	O
I/O	B-General_Concept
hardware	I-General_Concept
in	O
the	O
form	O
of	O
channel	O
programs	O
.	O
</s>
<s>
I/O	B-General_Concept
thereafter	O
proceeds	O
without	O
intervention	O
from	O
the	O
CPU	B-Device
until	O
an	O
event	O
requiring	O
notification	O
of	O
the	O
operating	O
system	O
occurs	O
,	O
at	O
which	O
point	O
the	O
I/O	B-General_Concept
hardware	I-General_Concept
signals	O
an	O
interrupt	B-Application
to	O
the	O
CPU	B-Device
.	O
</s>
<s>
A	O
channel	O
is	O
an	O
independent	O
hardware	O
component	O
that	O
coordinates	O
all	O
I/O	B-General_Concept
to	O
a	O
set	O
of	O
controllers	O
or	O
devices	O
.	O
</s>
<s>
It	O
is	O
not	O
merely	O
a	O
medium	O
of	O
communication	O
,	O
despite	O
the	O
name	O
;	O
it	O
is	O
a	O
programmable	O
device	O
that	O
handles	O
all	O
details	O
of	O
I/O	B-General_Concept
after	O
being	O
given	O
a	O
list	O
of	O
I/O	B-General_Concept
operations	I-General_Concept
to	O
carry	O
out	O
(	O
the	O
channel	O
program	O
)	O
.	O
</s>
<s>
Once	O
the	O
operating	O
system	O
has	O
prepared	O
a	O
complete	O
list	O
of	O
channel	O
commands	O
,	O
it	O
executes	O
a	O
single	O
I/O	B-General_Concept
machine	B-Language
instruction	I-Language
to	O
initiate	O
the	O
channel	O
program	O
;	O
the	O
channel	O
thereafter	O
assumes	O
control	O
of	O
the	O
I/O	B-General_Concept
operations	I-General_Concept
until	O
they	O
are	O
completed	O
.	O
</s>
<s>
This	O
flexibility	O
frees	O
the	O
CPU	B-Device
from	O
the	O
overhead	O
of	O
starting	O
,	O
monitoring	O
,	O
and	O
managing	O
individual	O
I/O	B-General_Concept
operations	I-General_Concept
.	O
</s>
<s>
The	O
specialized	O
channel	O
hardware	O
,	O
in	O
turn	O
,	O
is	O
dedicated	O
to	O
I/O	B-General_Concept
and	O
can	O
carry	O
it	O
out	O
more	O
efficiently	O
than	O
the	O
CPU	B-Device
(	O
and	O
entirely	O
in	O
parallel	O
with	O
the	O
CPU	B-Device
)	O
.	O
</s>
<s>
Channel	B-Device
I/O	I-Device
is	O
not	O
unlike	O
the	O
Direct	B-General_Concept
Memory	I-General_Concept
Access	I-General_Concept
(	O
DMA	O
)	O
of	O
microcomputers	O
,	O
only	O
more	O
complex	O
and	O
advanced	O
.	O
</s>
<s>
On	O
large	O
mainframe	B-Architecture
computer	I-Architecture
systems	O
,	O
CPUs	B-Device
are	O
only	O
one	O
of	O
several	O
powerful	O
hardware	O
components	O
that	O
work	O
in	O
parallel	O
.	O
</s>
<s>
Special	O
input/output	B-General_Concept
controllers	O
(	O
the	O
exact	O
names	O
of	O
which	O
vary	O
from	O
one	O
manufacturer	O
to	O
another	O
)	O
handle	O
I/O	B-General_Concept
exclusively	O
,	O
and	O
these	O
,	O
in	O
turn	O
,	O
are	O
connected	O
to	O
hardware	O
channels	O
that	O
also	O
are	O
dedicated	O
to	O
input	B-General_Concept
and	I-General_Concept
output	I-General_Concept
.	O
</s>
<s>
There	O
may	O
be	O
several	O
CPUs	B-Device
and	O
several	O
I/O	B-Device
processors	I-Device
.	O
</s>
<s>
The	O
overall	O
architecture	O
optimizes	O
input/output	B-General_Concept
performance	O
without	O
degrading	O
pure	O
CPU	B-Device
performance	O
.	O
</s>
<s>
Since	O
most	O
real-world	O
applications	O
of	O
mainframe	B-Architecture
systems	O
are	O
heavily	O
I/O	B-General_Concept
-intensive	O
business	O
applications	O
,	O
this	O
architecture	O
helps	O
provide	O
the	O
very	O
high	O
levels	O
of	O
throughput	O
that	O
distinguish	O
mainframes	B-Architecture
from	O
other	O
types	O
of	O
computers	O
.	O
</s>
<s>
In	O
IBM	O
ESA/390	O
terminology	O
,	O
a	O
channel	O
is	O
a	O
parallel	O
data	O
connection	O
inside	O
the	O
tree-like	O
or	O
hierarchically	O
organized	O
I/O	B-General_Concept
subsystem	O
.	O
</s>
<s>
In	O
System/390	O
I/O	B-General_Concept
cages	O
,	O
channels	O
either	O
directly	O
connect	O
to	O
devices	O
which	O
are	O
installed	O
inside	O
the	O
cage	O
(	O
communication	O
adapter	O
such	O
as	O
ESCON	B-Device
,	O
FICON	B-Architecture
,	O
Open	B-Device
Systems	I-Device
Adapter	I-Device
)	O
or	O
they	O
run	O
outside	O
of	O
the	O
cage	O
,	O
below	O
the	O
raised	O
floor	O
as	O
cables	O
of	O
the	O
thickness	O
of	O
a	O
thumb	O
and	O
directly	O
connect	O
to	O
channel	O
interfaces	O
on	O
bigger	O
devices	O
like	O
tape	O
subsystems	O
,	O
direct	B-Application
access	I-Application
storage	I-Application
devices	I-Application
(	O
DASDs	B-Application
)	O
,	O
terminal	O
concentrators	O
and	O
other	O
ESA/390	O
systems	O
.	O
</s>
<s>
Channels	O
differ	O
in	O
the	O
number	O
and	O
type	O
of	O
concurrent	O
I/O	B-General_Concept
operations	I-General_Concept
they	O
support	O
.	O
</s>
<s>
A	O
selector	O
channel	O
supports	O
one	O
high-speed	O
operation	O
,	O
transferring	O
a	O
block	B-General_Concept
of	O
data	O
at	O
a	O
time	O
.	O
</s>
<s>
A	O
block	B-General_Concept
multiplexer	O
supports	O
a	O
number	O
of	O
logically	O
concurrent	O
channel	O
programs	O
,	O
but	O
only	O
one	O
high-speed	O
data	O
transfer	O
at	O
a	O
time	O
.	O
</s>
<s>
A	O
channel	O
program	O
is	O
a	O
sequence	O
of	O
channel	O
command	O
words	O
(	O
CCWs	O
)	O
that	O
are	O
executed	O
by	O
the	O
I/O	B-Device
channel	I-Device
subsystem	O
in	O
the	O
IBM	B-Application
System/360	I-Application
and	O
subsequent	O
architectures	O
.	O
</s>
<s>
The	O
operating	O
system	O
signals	O
the	O
I/O	B-Device
channel	I-Device
subsystem	O
to	O
begin	O
executing	O
the	O
channel	O
program	O
with	O
an	O
SSCH	O
(	O
start	O
sub-channel	O
)	O
instruction	O
.	O
</s>
<s>
The	O
central	O
processor	O
is	O
then	O
free	O
to	O
proceed	O
with	O
non-I/O	O
instructions	O
until	O
interrupted	O
.	O
</s>
<s>
When	O
the	O
channel	O
operations	O
are	O
complete	O
,	O
the	O
channel	O
interrupts	B-Application
the	O
central	O
processor	O
with	O
an	O
I/O	B-General_Concept
interruption	O
.	O
</s>
<s>
In	O
earlier	O
models	O
of	O
the	O
IBM	O
mainframe	B-Architecture
line	O
,	O
the	O
channel	O
unit	O
was	O
an	O
identifiable	O
component	O
,	O
one	O
for	O
each	O
channel	O
.	O
</s>
<s>
In	O
modern	O
mainframes	B-Architecture
,	O
the	O
channels	O
are	O
implemented	O
using	O
an	O
independent	O
RISC	B-Architecture
processor	I-Architecture
,	O
the	O
channel	O
processor	O
,	O
one	O
for	O
all	O
channels	O
.	O
</s>
<s>
IBM	B-Device
System/370	I-Device
Extended	O
Architecture	O
and	O
its	O
successors	O
replaced	O
the	O
earlier	O
SIO	O
(	O
start	O
I/O	B-General_Concept
)	O
and	O
SIOF	O
(	O
start	O
I/O	B-General_Concept
fast	O
release	O
)	O
machine	B-Language
instructions	I-Language
(	O
System/360	B-Application
and	O
early	O
System/370	B-Device
)	O
with	O
the	O
SSCH	O
(	O
start	O
sub-channel	O
)	O
instruction	O
(	O
ESA/370	O
and	O
successors	O
)	O
.	O
</s>
<s>
Channel	B-Device
I/O	I-Device
provides	O
considerable	O
economies	O
in	O
input/output	B-General_Concept
.	O
</s>
<s>
For	O
example	O
,	O
on	O
IBM	O
's	O
Linux	B-Application
on	I-Application
IBM	I-Application
Z	I-Application
,	O
the	O
formatting	O
of	O
an	O
entire	O
track	O
of	O
a	O
DASD	B-Application
requires	O
only	O
one	O
channel	O
program	O
(	O
and	O
thus	O
only	O
one	O
I/O	B-General_Concept
instruction	O
)	O
,	O
but	O
multiple	O
channel	O
command	O
words	O
(	O
one	O
per	O
block	B-General_Concept
)	O
.	O
</s>
<s>
The	O
program	O
is	O
executed	O
by	O
the	O
dedicated	O
I/O	B-Device
processor	I-Device
,	O
while	O
the	O
application	O
processor	O
(	O
the	O
CPU	B-Device
)	O
is	O
free	O
for	O
other	O
work	O
.	O
</s>
<s>
A	O
channel	O
command	O
word	O
(	O
CCW	O
)	O
is	O
an	O
instruction	O
to	O
a	O
specialized	O
I/O	B-Device
channel	I-Device
processor	O
which	O
is	O
,	O
in	O
fact	O
,	O
a	O
finite	B-Architecture
state	I-Architecture
machine	I-Architecture
.	O
</s>
<s>
It	O
is	O
used	O
to	O
initiate	O
an	O
I/O	B-General_Concept
operation	I-General_Concept
,	O
such	O
as	O
"	O
read	O
"	O
,	O
"	O
write	O
"	O
or	O
"	O
sense	O
"	O
,	O
on	O
a	O
channel-attached	O
device	O
.	O
</s>
<s>
On	O
system	O
architectures	O
that	O
implement	O
channel	B-Device
I/O	I-Device
,	O
typically	O
all	O
devices	O
are	O
connected	O
by	O
channels	O
,	O
and	O
so	O
all	O
I/O	B-General_Concept
requires	O
the	O
use	O
of	O
CCWs	O
.	O
</s>
<s>
CCWs	O
are	O
organized	O
into	O
channel	O
programs	O
by	O
the	O
operating	O
system	O
,	O
and	O
I/O	B-General_Concept
subroutine	O
,	O
a	O
utility	O
program	O
,	O
or	O
by	O
standalone	O
software	O
(	O
such	O
as	O
test	O
and	O
diagnostic	O
programs	O
)	O
.	O
</s>
<s>
For	O
example	O
,	O
self	O
modification	O
is	O
used	O
extensively	O
in	O
OS/360	O
ISAM	B-Application
.	O
</s>
<s>
The	O
following	O
example	O
reads	O
a	O
disk	O
record	O
identified	O
by	O
a	O
recorded	B-Application
key	I-Application
.	O
</s>
<s>
When	O
a	O
record	O
with	O
a	O
matching	O
key	O
is	O
found	O
the	O
DASD	B-Application
controller	O
will	O
include	O
Status	O
Modifier	O
in	O
the	O
channel	O
status	O
,	O
causing	O
the	O
channel	O
to	O
skip	O
the	O
TIC	O
CCW	O
;	O
thus	O
the	O
channel	O
program	O
will	O
not	O
branch	O
and	O
the	O
channel	O
will	O
execute	O
the	O
READ	O
command	O
.	O
</s>
<s>
The	O
above	O
example	O
is	O
correct	O
for	O
unblocked	O
records	O
(	O
one	O
record	O
per	O
block	B-General_Concept
)	O
.	O
</s>
<s>
For	O
blocked	O
records	O
(	O
more	O
than	O
one	O
record	O
per	O
block	B-General_Concept
)	O
,	O
the	O
recorded	B-Application
key	I-Application
must	O
be	O
the	O
same	O
as	O
the	O
highest	O
key	O
within	O
that	O
block	B-General_Concept
(	O
and	O
the	O
records	O
must	O
be	O
in	O
key	O
sequence	O
)	O
,	O
and	O
the	O
following	O
channel	O
program	O
would	O
be	O
utilized	O
:	O
</s>
<s>
In	O
some	O
cases	O
,	O
the	O
system	O
software	O
has	O
the	O
option	O
of	O
updating	O
the	O
track	O
or	O
cylinder	O
number	O
and	O
redriving	O
the	O
I/O	B-General_Concept
operation	I-General_Concept
without	O
interrupting	B-Application
the	O
application	O
program	O
.	O
</s>
<s>
The	O
operating	O
system	O
is	O
responsible	O
for	O
translating	O
these	O
channel	O
programs	O
before	O
executing	O
them	O
,	O
and	O
for	O
this	O
particular	O
purpose	O
the	O
Input/Output	B-Application
Supervisor	I-Application
(	O
IOS	O
)	O
has	O
a	O
special	O
fast	O
fix	O
function	O
which	O
was	O
designed	O
into	O
the	O
OS	O
Supervisor	O
just	O
for	O
those	O
"	O
fixes	O
"	O
which	O
are	O
of	O
relatively	O
short	O
duration	O
(	O
i.e.	O
,	O
significantly	O
shorter	O
than	O
"	O
wall-clock	O
time	O
"	O
)	O
.	O
</s>
<s>
Pages	O
containing	O
data	O
to	O
be	O
used	O
by	O
the	O
I/O	B-General_Concept
operation	I-General_Concept
are	O
locked	O
into	O
real	O
memory	O
,	O
or	O
page	O
fixed	O
.	O
</s>
<s>
The	O
channel	O
program	O
is	O
copied	O
and	O
all	O
virtual	O
addresses	O
are	O
replaced	O
by	O
real	O
addresses	O
before	O
the	O
I/O	B-General_Concept
operation	I-General_Concept
is	O
started	O
.	O
</s>
<s>
As	O
page	O
fixing	O
and	O
unfixing	O
is	O
a	O
CPU-expensive	O
process	O
long-term	O
page	O
fixing	O
is	O
sometimes	O
used	O
to	O
reduce	O
the	O
CPU	B-Device
cost	O
.	O
</s>
<s>
Here	O
the	O
virtual	O
memory	O
is	O
page-fixed	O
for	O
the	O
life	O
of	O
the	O
application	O
,	O
rather	O
than	O
fixing	O
and	O
freeing	O
around	O
each	O
I/O	B-General_Concept
operation	I-General_Concept
.	O
</s>
<s>
An	O
example	O
of	O
a	O
program	O
that	O
can	O
use	O
long-term	O
page	O
fixing	O
is	O
Db2	B-Application
.	O
</s>
<s>
Even	O
bootstrapping	B-Application
of	O
the	O
system	O
,	O
or	O
Initial	O
Program	O
Load	O
(	O
IPL	O
)	O
in	O
IBM	O
nomenclature	O
,	O
is	O
carried	O
out	O
by	O
channels	O
,	O
although	O
the	O
process	O
is	O
partially	O
simulated	O
by	O
the	O
CPU	B-Device
through	O
an	O
implied	O
Start	O
I/O	B-General_Concept
(	O
SIO	O
)	O
instruction	O
,	O
an	O
implied	O
Channel	O
Address	O
Word	O
(	O
CAW	O
)	O
at	O
location	O
0	O
and	O
an	O
implied	O
channel	O
command	O
word	O
(	O
CCW	O
)	O
with	O
an	O
opcode	O
of	O
Read	O
IPL	O
,	O
also	O
at	O
location	O
0	O
.	O
</s>
<s>
To	O
load	O
a	O
system	O
,	O
the	O
implied	O
Read	O
IPL	O
CCW	O
reads	O
the	O
first	O
block	B-General_Concept
of	O
the	O
selected	O
IPL	O
device	O
into	O
the	O
24-byte	O
data	O
area	O
at	O
location	O
0	O
,	O
the	O
channel	O
continues	O
with	O
the	O
second	O
and	O
third	O
double	O
words	O
,	O
which	O
are	O
CCWs	O
,	O
and	O
this	O
channel	O
program	O
loads	O
the	O
first	O
portion	O
of	O
the	O
system	O
loading	O
software	O
elsewhere	O
in	O
main	O
storage	O
.	O
</s>
<s>
The	O
first	O
double	O
word	O
contains	O
a	O
PSW	O
which	O
,	O
when	O
fetched	O
at	O
the	O
conclusion	O
of	O
the	O
IPL	O
,	O
causes	O
the	O
CPU	B-Device
to	O
execute	O
the	O
IPL	O
Text	O
(	O
bootstrap	B-Operating_System
loader	I-Operating_System
)	O
read	O
in	O
by	O
the	O
CCW	O
at	O
location	O
8	O
.	O
</s>
<s>
It	O
is	O
capable	O
of	O
IPL-ing	O
from	O
a	O
card	O
deck	O
,	O
from	O
a	O
magnetic	O
tape	O
,	O
or	O
from	O
a	O
direct	B-Application
access	I-Application
storage	I-Application
device	I-Application
,	O
(	O
DASD	B-Application
)	O
,	O
e.g.	O
,	O
disk	O
,	O
drum	O
.	O
</s>
<s>
The	O
Read	O
IPL	O
(	O
X'02'	O
)	O
command	O
,	O
which	O
is	O
simulated	O
by	O
the	O
CPU	B-Device
,	O
is	O
a	O
Read	O
EBCDIC	O
Select	O
Stacker	O
1	O
read	O
command	O
on	O
the	O
card	O
reader	O
and	O
a	O
Read	O
command	O
on	O
tape	O
media	O
(	O
which	O
are	O
inherently	O
sequential	O
access	O
in	O
nature	O
)	O
,	O
but	O
a	O
special	O
Read-IPL	O
command	O
on	O
DASD	B-Application
.	O
</s>
<s>
DASD	B-Application
controllers	O
accept	O
the	O
X'02'	O
command	O
,	O
seek	O
to	O
cylinder	O
X'0000'	O
head	O
X'0000'	O
,	O
skip	O
to	O
the	O
index	O
point	O
(	O
i.e.	O
,	O
just	O
past	O
the	O
track	O
descriptor	O
record	O
(	O
R0	O
)	O
)	O
and	O
then	O
treat	O
the	O
Read	O
IPL	O
command	O
as	O
if	O
it	O
were	O
a	O
Read	O
Data	O
(	O
X'06'	O
)	O
command	O
.	O
</s>
<s>
Without	O
this	O
special	O
DASD	B-Application
controller	O
behavior	O
,	O
device-independent	O
IPL	O
would	O
not	O
be	O
possible	O
.	O
</s>
<s>
On	O
a	O
DASD	B-Application
,	O
the	O
IPL	O
Text	O
is	O
contained	O
on	O
cylinder	O
X'0000'	O
,	O
track	O
X'0000'	O
,	O
and	O
record	O
X'01'	O
(	O
24	O
bytes	O
)	O
,	O
and	O
cylinder	O
X'0000'	O
,	O
track	O
X'0000'	O
,	O
and	O
record	O
X'02'	O
(	O
fairly	O
large	O
,	O
certainly	O
somewhat	O
more	O
than	O
3,000	O
bytes	O
)	O
.	O
</s>
<s>
The	O
volume	O
label	O
is	O
always	O
contained	O
on	O
cylinder	O
X'0000'	O
,	O
track	O
X'0000'	O
,	O
and	O
block	B-General_Concept
X'03'	O
(	O
80	O
bytes	O
)	O
.	O
</s>
<s>
The	O
volume	O
label	O
always	O
points	O
to	O
the	O
VTOC	B-Application
,	O
with	O
a	O
pointer	O
of	O
the	O
form	O
HHHH	O
(	O
that	O
is	O
,	O
the	O
VTOC	B-Application
must	O
reside	O
within	O
the	O
first	O
65,536	O
tracks	O
)	O
.	O
</s>
<s>
The	O
VTOC	B-Application
's	O
Format	B-Application
4	I-Application
DSCB	I-Application
defines	O
the	O
extent	O
(	O
size	O
)	O
of	O
the	O
VTOC	B-Application
,	O
so	O
the	O
volume	O
label	O
only	O
needs	O
a	O
pointer	O
to	O
the	O
first	O
track	O
in	O
the	O
VTOC	B-Application
's	O
extent	O
,	O
and	O
as	O
the	O
Format	B-Application
4	I-Application
DSCB	I-Application
,	O
which	O
describes	O
the	O
VTOC	B-Application
,	O
is	O
always	O
the	O
very	O
first	O
DSCB	O
in	O
the	O
VTOC	B-Application
,	O
HHHH	O
also	O
points	O
to	O
the	O
Format	B-Application
4	I-Application
DSCB	I-Application
.	O
</s>
<s>
The	O
DASD	B-Application
(	O
direct	B-Application
access	I-Application
storage	I-Application
device	I-Application
)	O
initialization	O
program	O
,	O
IBCDASDI	O
,	O
or	O
the	O
DASD	B-Application
initialization	O
application	O
,	O
ICKDSF	O
,	O
places	O
a	O
wait	O
state	O
PSW	O
and	O
a	O
dummy	O
CCW	O
string	O
in	O
the	O
24	O
bytes	O
,	O
should	O
the	O
device	O
be	O
designated	O
for	O
data	O
only	O
,	O
not	O
for	O
IPL	O
,	O
after	O
which	O
these	O
programs	O
format	O
the	O
VTOC	B-Application
and	O
perform	O
other	O
hard	O
drive	O
initialization	O
functions	O
.	O
</s>
