ceipt of the signal from the device. The channel-end
indication in this case is not made available to the
Termination by HALT I/O The instruction HALT r/ a causes the current operation
at the addressed channel or subchannel to be termi­
nated immediately. The method of termination differs
from that used upon exhaustion of count or upon de­
tection of programming errors to the extent that ter­
mination by HALT r/o is not contingent on the receipt
of a service request from the device.
When HALT r/o is issued to a channel operating in
the burst mode, the channel issues the haIt-r/o signal
to the device regardless of the current activity in the
channel and on the interface. If the channel is involved
in the data-transfer portion of an operation, data trans­
fer is immediately terminated, and the device is dis­
connected from the channel. If HALT I/O is addressed
to a selector channel executing a chain of operations
and the device has already provided channel end for
the current operation, the instruction causes the de­
vice to be disconnected and the chain-command Hag
to be removed.
When HALT I/O is issued to the multiplexor channel
and the channel is not operating in the burst mode,
the haIt-I/o signal is sent to the device whenever the
addressed subchannel is in the working state. The sub­
channel may be transferring data, or it may have al­
ready received channel end for the current operation
and may be waiting for device end to initiate a new
operation by command chaining. In either case, HALT
r/o causes the device to be selected, and the halt-I/o
signal is issued as the device responds. When com­
mand chaining is indicated in the subchannel, HALT I/O causes the chain-command Hag to be turned off.
Termination of an operation by HALT I/O on the se­
lector channel results in up to four distinct interrupt­
ion conditions. The first one is generated by the chan­
nel upon execution of the instruction and is not con­
tingent on the receipt of status from the device. The
command address and count in the associated csw
indicate how much data have been transferred, and
the channel-status bits reHect the unusual conditions
if any, detected during the operation. If HALT r/o issued before all data specified for the operation have
been transferred, incorrect length is indicated, subject
to the control of the SLI Hag in the current ccw. The
execution of HALT I/O itself is not reHected in csw
status, and all status bits in a csw due to this inter­
ruption condition can be zero. The channel is available
for the initiation of a new I/O operation as soon as the
interruption condition is cleared.
The second interruption condition on the selector
channel occurs when the control unit generates the
channel-end condition. The selector channel handles
this condition as any other interruption condition from
the device with the sub channel available and provides
zeros in the protection key, command address, count,
and channel status fields of the associated csw. The
channel-end condition is not made· available to the
program when HALT I/O is issued to a channel execu­
ting a chain of operations and the device has already
provided channel end for the current operation.
Finally, the third and fourth interruption conditions
occur when control unit end, if any, and device end
are generated. These conditions are handled as for any
other I/O operation.
Termination of an operation by HALT I/O on the
multiplexor channel causes the normal interruption
conditions to be generated. If the instruction is issued
when the subchannel is in the data-transfer portion of
an operation, the subchannel remains in the working
state until channel end is signaled by the device, at
which time the subchannel is placed in the interrupt­
ion-pending state. If HALT r/o is issued after the de­
vice has signaled channel end and the sub channel is
executing a chain of operations, the channel-end con­
dition is not made available to the program, and the sub channel remains in the working state until the next
status byte from the device is received. Receipt of a
status byte subsequently places the sub channel in the
interruption-pending state.
The csw associated with the interruption condition
in the sub channel contains the status bytes provided
by the device and the channel, and indicates at what
point data transfer was terminated. If HALT r/o is is­
sued before all data areas associated with the current
opcration have been exhausted or filled, incorrect
length is indicated, subject to the control of the SLI Hag in the current ccw. The interruption condition is
processed as for any other type of termination.
Termination Due to Equipment Malfunction
When channel equipment malfunctioning is detected
or invalid signals are received over the I/O interface,
the recovery procedure and the subsequent states of
the subchannels and devices on the channel depend
on the type of error and on the model. Normally, the
program is alerted of the termination by an I/O inter­
ruption, and the associated csw indicates the channel­
control-check or interface-control-check condition. In
channels sharing common equipment with the CPU, malfunctioning detected by the channel may be indi­
cated by a machine-check interruption, in which case
no csw is stored. Equipment malfunctioning may cause
the channel to perform the malfunction-reset function.
Programming Note
Control operations for which the entire operation is specified in the command code may be executed as
immediate operations. Whether the control function is
executed as an immediate operation depends on the
operation and type of device and is specified in the SRL publication for the device.
Termination of Data Transfer
When the device accepts a command, the subchannel
is set up for data transfer. The subchannel is said to
be working during this period. Unless the channel de­
tects equipment malfunctioning or, on the selector
channel, the operation is terminated by HALT I/O, the
working state lasts until the channel receives the chan­
nel-end signal from the device. When no command
chaining is specified or when chaining is suppressed
because of unusual conditions, the channel-end con­
dition causes the operation at the subchannel to be ter­
minated and an interruption condition to be generated.
The status bits in the associated csw indicate channel
end and the unusual conditions, if any. The device can
signal channel end at any time after initiation of the
operation, and the signal may occur before any data
have been transferred.
For operations not involving data transfer, the de­
vice normally controls the timing of the channel-end
condition. The duration of data transfer operations
may be variable and may be controlled by the device
or the channel.
Excluding equipment errors and HALT I/O, the chan­
nel signals the device to terminate data transfer when­
ever any of the following conditions occurs:
The storage areas specified for the operation are
exhausted or filled. Program-check condition is detected.
Protection-check condition is detected.
Chaining-check condition is detected.
The first of these conditions occurs when the channel
has stepped the count in the last ccw associated with
the operation to zero. A count of zero indicates that
the channel has transferred all information specified by the program. The other three conditions are due to
errors and cause premature termination of data trans­
fer. In either case, the termination is signaled in re­
sponse to a service request from the device and causes
data transfer to cease. If the device has no blocks de­ fined for the operation (such as writing on magnetic
tape), it terminates the operation and generates the
channel-end condition.
The device can control the duration of an operation
and the timing of channel end by blocking of data. On certain operations for which blocks are defined (such
as reading on magnetic tape), the device does not
provide the channel-end signal until the end of the
block is reached, regardless of whether or not the de­
vice has been previously signaled to terminate data
The channel suppresses initiation of an I/O operation
when the data address in the first ccw associated with
the operation exceeds the addressing capacity of the
model. Complete check for the validity of the data ad­
dress is performed only as data are transferred to or
from main storage. When the initial data address in
the ccw is invalid, no data are transferred during the
operation, and the device is signaled to terminate the
operation in response to the first service request. On writing, devices such as magnetic tape units request
the first byte of data before any mechanical motion is
started and, if the initial data address is invalid, the
operation is terminated before the recording medium
has been advanced. However, since the operation has
been initiated, the device provides channel end, and
an interruption condition is generated. Whether a
block at the device is advanced when no data are
transferred depends on the type of device and is speci­ fied in the SRL publication for the device.
When command chaining takes place, the subchan­
nel appears in the working state from the time the first operation is initiated until the device signals the
channel-end condition of the last operation of the
chain. On the selector channel, the device executing
the operation stays connected to the channel and the
whole channel appears to be in the working state for
the duration of the execution of the chain of oper­
ations. On the multiplexor channel an operation in the
burst mode causes the channel to appear to be in the
working state only for the duration of the transfer of
the burst of data. If channel end and device end do
not occur concurrently, the device disconnects from
the channel after providing channel end, and the chan­
nel can in the meantime communicate with other de­
vices on the interface.
Any unusual conditions cause command chaining to
be suppressed and an interruption condition to be gen­
erated. The unusual conditions can be detected by
either the channel or the device, and the device can
provide the indications with channel end, control unit
end, or device end. When the channel is aware of the
unusual condition by the time the channel-end signal
for the operation is received, the chain is terminated
as if the operation during which the condition oc­
curred were the last operation of the chain. The de­
vice-end signal subsequently is processed as an inter­
ruption condition. When the device signals unit check
or unit exception with control unit end or device end,
the sub channel terminates the working state upon re-
Input/Output Operations 107
Previous Page Next Page