The device can control the duration of
an operation and the timing of channel
end. On certain operations for which
blocks are defined (such as reading from
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 device has been
previously signaled to conclude data transfer.
If the data address in the CCW is inval­ id, and the operation is a write or
control operation, no data is trans­
ferred during the operation, and the
device is signaled to conclude the oper­
ation 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 data
address is invalid, the operation is
concluded before the recording medium
has been advanced. However, since the
operation has been initiated at the I/O device, the I/O device generates a
channel-end interruption condition.
Whether a block at the I/O device is
advanced when no data is transferred
depends on the type of I/O device and is
specified in the SL publication for the I/O device.
When command chaining takes place, the
subchannel is in the working state from
the time condition code 0 is set for
START I/O or START I/O FAST RELEASE
until the device signals channel end for
the last operation of the chain. On a
selector channel or a block-multiplexer
channel operating with multiplexing
inhibited, the device executing the I/O operation stays connected to the channel
and the channel is in the working state
during the entire execution of the chain
of I/O operations. When multiplexing
occurs, an I/O operation in the burst
mode causes the channel to be in the
working state only while transferring a
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
channel can in the meantime communicate
with other devices.
Any unusual situations cause command
chaining to be suppressed and an inter­
ruption condition to be generated. The
unusual situations 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 situation by the time the
channel-end signal for the operation is
received, the chain is ended as if the
operation during which the situation
occurred were the last operation of the
chain. The device-end signal subse­
quently is processed as an interruption
condition. When the device signals unit check or unit exception with control­
unit end or device end, the subchannel
terminates the working state upon receipt of the signal from the device.
The channel-end indication in this case
is not made available to the program.
Termination HAll !LQ HALT DEVICE The instructions HALT I/O and HALT DEVICE cause the current operation at
the addressed channel or subchannel to
be immediatelY terminated. The method
of termination differs from that used
upon exhaustion of count or upon
detection of programming errors to the
extent that termination by HALT I/O or
HALT DEVICE is not necessarily contin­
gent on the receipt of a service request
from the device.
When HALT I/O is issued to a channel
operating in burst mode, the channel
issues the halt signal to the device
currently operating with the channel,
regardless of the device address speci­
fied by the HALT I/O instruction. If
the channel is involved in the data­
transfer portion of an operation, data
transfer is immediately terminated, and
the device is disconnected from the
channel. If the channel is executing a
chain of operations and the device has
already provided channel end for the
current operation, the instruction caus­
es the device to be disconnected and
command chaining to be immediately
suppressed.
When HALT DEVICE is issued to a channel
operating in burst mode, the halt signal
is issued to the device involved in the
burst-mode operation only if that device
is the one to which the HALT DEVICE is
addressed. If the operation thus termi­
nated is in the data-transfer portion of
the operation, data transfer is imme­
diately terminated, and the device is
disconnected from the channel. If the
channel is executing a chain of oper­
ations and the device has already
provided channel end for the current
operation, HALT DEVICE causes the device
to be disconnected and command chaining
to be immediately suppressed. If, on a
selector channel, the device involved in
the burst is not the one to which the
HALT DEVICE is addressed, no action is
taken. If, on a multiplexer channel,
the device involved in the burst is not
the one to which the HALT DEVICE is
addressed, HALT DEVICE causes any opera­
tion for the addressed device to be
terminated at the addressed subchannel
and suppresses any further data transfer
or command chaining for that device.
When HALT
for which
suspended
code 2 is
ating in
device. DEVICE is issued to a device
an I/O operation is pending or
at the subchannel, condition
set as if the channel is oper­
burst mode with a different
Subsequently, when conditions Chapter 13. Input/Output Operations 13-57
allow, the device is selected, and the
halt signal is issued as the device
responds. The pending or suspended
operation is terminated at the subchan­
nel and an interruption condition is
recognized which is not contingent on
the receipt of status from the device.
When HALT I/O or HALT DEVICE is issued
to a channel not operating in burst
mode, then, if the subchannel is not
interruption-pending (or, for HALT DEVICE, working with another device),
the channel attempts to select the
device and issue the halt signal as the
device responds. If the device presents
status and command chaining is indicated in the subchannel, chaining is
suppressed.
The termination of an operation by HALT I/O or HALT DEVICE on the selector chan­
nel results in up to four distinct
interruption conditions. The first one
is generated by the channel upon
execution of the instruction and is not
contingent on the receipt of status from
the device. The channel-status bits
reflect the unusual situations, if any,
detected during the operation. The
execution of HALT I/O or HALT DEVICE itself is not reflected in CSW status,
and all status bits in a CSW due to this
interruption 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 signals channel end. The selector
channel handles this condition as any
other interruption condition from the
device after the device has been discon­
nected from the channel, and provides
zeros in the subchannel-key, CCW­ address, count, and channel-status
fields of the associated CSW. Channel end is not made available to the program
when HALT I/O or HALT DEVICE is issued
to a channel executing a chain of oper­
ations and the device has already
provided channel end for the current
operation.
Finally, the third and fourth inter­
ruption conditions occur when control­
unit end, if any, and device end are
signaled. These signals are handled as
for any other I/O operation.
The termination of an operation by HALT I/O or HALT DEVICE on a multiplexer
channel causes the normal interruption
conditions to be generated. If the instruction is issued when the subchan­
nel 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
interruption-pending state. If HALT I/O or HALT DEVICE is issued after the
13-58 System/370 Principles of Operation device has signaled channel end and the
subchannel is executing a chain of oper­
ations, channel end is not made
available to the program, and the
subchannel remains in the working state
until the next status byte from the
device is received. Receipt of a status
byte subsequently places the subchannel
in the interruption-pending state. The CSW associated with the interruption
condition in the subchannel contains the
status bytes provided by the device and
the channel, if any. The interruption
condition is processed as for any other
type of termination.
The termination of a burst operation by
HALT I/O or HALT DEVICE on a block­
multiplexer channel may, depending on
the model and the design of the subchan­
nel, take place as for a selector chan­
nel or may allow the subchannel to
remain in the working state until the
device provides ending status.
When HALT I/O is issued and the subchan­
nel is in the working state with either a pending or a suspended channel-program
execution and the channel is either
available or interruption-pending, the
addressed device is selected and issued
the halt signal. Condition code 1 is
set, and the status portion, bits 32-47
of the CSW, are stored to indicate the
results of HIO execution. If the
addressed device is issued the halt
signal, the CSW contains zeros in the
status field unless an equipment error
is detected. If the channel attempted
to select the device but the control
unit could not accept the halt signal
because of a busy condition, the CSW unit-status field indicates the busy
condition.
The termination of a pending or
suspended channel-program execution by
HALT I/O causes an interruption condi­
tion to be recognized. The CSW stored
when the interruption occurs contains
either zeros or the last status received
from the device in the unit-status field
and zeros in the channel-status field.
The command-address field contains the
address of the first CCW, plus 8, or the CCW having the S flag, plus 8, and the
deferred condition code is 1.
When a pending or suspended I/O opera­
tion is terminated by HALT I/O or HALT DEVICE on any channel, the CSW stored
when the interruption condition is
cleared contains either the last status
received from the device since the I/O operation was made pending or zeros.
The command-address field contains the
address of the first or suspended CCW plus 8, and the deferred condition code
is 1 or 3, depending on whether the
device is detected to be operational or
not operational, respectively. If the
unit status is not zeros, the busy bit
is included.
Previous Page Next Page