condition-code, CCW-address, and count
fields may contain information pertain­
ing to the last operation or may be set
to zero, or the original contents of
these fields at real locations 64-67 and 70-71 may be left unchanged.
Information Provided Channel-Status Word Interruption conditions resulting from
the execution or conclusion of an opera­
tion at the subchannel cause the whole CSW to be replaced. Such a CSW can be
stored only by an I/O interruption or by
TEST I/O or CLEAR I/O. Except for situ­
ations associated with command chaining
and equipment malfunctioning, the stor­
ing can be caused by PCI or channel end
and by the execution of HALT I/O or HALT DEVICE on the selector channel. The
contents of the CSW are related to the
current values of the corresponding
quantities, although the count is unpre­
dictable after program check, protection
check, and chaining check, and after an
interruption due to HALT I/O, HALT DEVICE, the CLRIO function, or the PCI flag.
A CSW stored upon the execution of a chain of operations pertains to the last
operation which the channel executed or
attempted to initiate. Information
concerning the preceding operations is
not preserved and is not made available
to the program. When an unusual situation causes command
chaining to be suppressed, the premature
conclusion of the chain is not explicit­
ly indicated in the CSW. A CSW associ­
ated with a conclusion due to a situation occurring at channel-end time
contains channel end and identifies the
unusual situation. When the device
signals the unusual situation with
control-unit end or device end, the
channel-end indication is not made
available to the program, and the chan­
nel provides the current subchannel key, CCW address, and count, as well as the
unusual indication, with control-unit
end or device end in the CSW. The CCW­ address and count fields pertain to the
operation that was executed.
When the execution of a chain of
commands is concluded by an unusual
situation detected during initiation of a new operation, the CCW-address and
count fields pertain to the rejected
command. Except for situations result­
ing from equipment malfunctioning,
conclusion at initiation time can occur
because of attention, unit check, unit
exception, busy, protection check, or
program check, and causes both the
channel-end and device-end bits in the CSW to be set to zeros.
A CSW associated with status signaled
after the operation at the subchannel
has been concluded contains zeros in the
subchannel-key, CCW-address, and count
fields, provided the status is not
cleared during START I/O or START I/O FAST RELEASE. This status includes
attention, control-unit end, and device
end (and channel end when it occurs
after the conclusion of an operation on
the selector channel by HALT I/O or HALT DEVICE). When the above status indications are
cleared during START I/O or START I/O FAST RELEASE, only the status portion of
the CSW is stored, and the original
contents of the subchannel-key, CCW­ address, deferred-condition-code,
logout-pending, and count fields at
locations 64-67 and 70-71 are preserved.
Similarly, only the status bits of the CSW are changed when the command is
rejected or the operation at the
subchannel is concluded during the
execution of START I/O or START I/O FAST
RELEASE or whenever HALT I/O or HALT DEVICE causes CSW status to be stored.
The CSW stored when a channel-available
interruption occurs contains zeros in
all fields.
Errors detected during execution of the I/O operation do not affect the validity
of the CSW unless channel-control check
or interface-control check are
indicated. Channel-control check indi­
cates that equipment errors have been
detected which can cause any part of the CSW, as well as the I/O address, to be
invalid. Interface-control check indi­
cates that the address identifying the
device or the status bits received from
the device may be invalid. The channel
forces correct parity on invalid CSW fields. The validity of these fields
can be ascertained by inspecting the
limited channel logout.
When any I/O instruction cannot be
executed because of a pending logout
which affects the operational capability
of the channel or subchannel, a full CSW is stored. The fields in the CSW are
all set to zeros, with the exception of
the logout-pending bit and the channel­
control-check bit, which are set to
ones.
Subchannel Key
A CSW stored to reflect the progress of
an operation at the subchannel contains the subchannel key used in that opera­
tion. The contents of this field are
not affected by programming errors
detected by the channel or by the situ­
ations causing termination of the opera­
tion. Chapter 13. Input/Output Operations 13-73
Suspended Indication
When the CSW is stored during an inter­
ruption because of the program­
controlled-interruption (PCI) condition,
bit 4 of the CSW indicates whether the
channel-program execution is currently
suspended. Suspension of channel­
program execution is a function of the
suspend-and-resume facility that may be
provided for one or more subchannels of
multiplexer channels, depending on the
system model.
A channel-program execution is consid­
ered to be suspended from the time the
channel performs the suspend function
because of the presence of a valid S flag in a CCW until that channel-program
execution is terminated at the subchan­
nel or until the resume function is
performed because of a successful (con­
dition code 0) RIO issued to the
subchannel. During the period of
suspension, the storing of a CSW can
only occur as a result of the PCI condi­
tion. The PCI condition may be
generated because of a PCI flag in the CCW containing the S flag or because of
a PCI flag in a CCW fetched earlier in
the chain of commands being executed at
the subchannel. When the PCI flag and a
valid S flag are in the same CCW, the
resulting CSW contains the suspended
indication unless the CSW indicates that
channel-program execution is terminated
at the subchannel.
Logout Pending
The logout-pending bit can be stored as
one only in a CSW stored during the
execution of an I/O instruction. The I/O instructions that can result in
storing the CSW with the indication are CLEAR I/O, HALT DEVICE, HALT I/O, START I/O, START I/O FAST
RELEASE, STORE CHANNEL ID, and TEST I/O.
When the CSW is stored and indicates
logout pending, channel-control check is
also indicated in the channel-status
field.
Deferred Condition Code In the case of START I/O FAST RELEASE
executed independent of the device or
RESUME I/O issued to a suspended
subchannel, initiation or resumption of
the I/O operation is not completed
during the execution of the instruction.
If no conditions are encountered during
13-74 System/370 Principles of Operation
the execution of the instruction that
preclude the acceptance of the function
of the instruction by the channel,
condition code 0 is set, and conditions
encountered subsequent to executing the
instruction which preclude the
completion of the specified function
cause the deferred condition code to be
set. The deferred condition code is set
when a CSW is stored because of an
interruption condition signaling the
conclusion of the I/O operation at the
subchannel.
Deferred condition code 1 is set either
when the channel has detected a condi­
tion that would have caused condition
code 1 to be set in response to the
START I/O FAST RELEASE instruction if
the SIO function had been performed, or
when HALT I/O, HALT DEVICE, CLEAR I/O or
equipment malfunction causes the channel
to terminate the I/O operation while it
is pending at the subchannel. When HALT
I/O, HALT DEVICE, or equipment malfunc­
tion terminates a pending I/O operation,
deferred condition code 1 is set in the CSW that is stored during the I/O inter­
ruption signaling the termination.
Deferred condition code 1 ;s also set
when the channel detects a condition
while attempting to resume a suspended
channel-program execution that would
have caused deferred condition code 1,
had the SIOF function been executed
independent of the device with the
subchannel available, instead of RESUME I/O with the subchannel suspended.
Deferred condition code 1 is also
when, after HALT DEVICE is issued
suspended subchannel, the device
been selected and an attempt made
issue the halt signal.
set
to a
has
to
Deferred condition code 3 is set when
the channel has detected that the
addressed device is not operational even
though condition code 0 was set in
response to the START I/O FAST RELEASE
or RESUME I/O instruction, or when,
after HDV is issued to a suspended
subchannel, the device is found to be
not operational when the attempt is made
to issue the halt signal. When the CSW contains deferred condition code 3, the
unit-status field contains zeros and has
no meaning with respect to the progress
of the I/O operation.
The figure "Contents of the Deferred­ Condition-Code Field" summarizes the
handling of deferred condition codes.
The figure lists the states and activ­
ities that can cause deferred­
condition-code indications to be created
and the methods by which these indi­
cations can be placed in the CSW.
Previous Page Next Page