Whenever a channel is opened, a channel definition block is allocated in the common heap. This block contains a certain amount of information regarding said channel. Different channel types have different channel definition blocks, but all channels have the first $18 bytes defined as the block header.
Offset | Size | QDOS Mnemonic | SMS Mnemonic | Description |
---|---|---|---|---|
$00 | Long | CH_LEN | CHN_LEN | Size of this channel definition block |
$04 | Long | CH_DRIVR | CHN_DRVR | Address of the driver linkage block |
$08 | Long | CH_OWNER | CHN_OWNR | Job id of the owner of this channel |
$0C | Long | CH_RFLAG | CHN_RFLG | See note below. |
$10 | Word | CH_TAG | CHN_TAG | Channel tag |
$12 | Byte | CH_STAT | CHN_STAT | See note below |
$13 | Byte | CH_ACTN | CHN_ACTN | Action code. (Value in D0 for last TRAP on this channel) |
$14 | Long | CH_JOBWT | CHN_JBWT | Job id of the job waiting for I/O on this channel |
Notes | |
---|---|
CH_RFLG | QDOS Companion says this about CH_RFLG : Location to be set when space released (channel closed ?) SMS states : Location to be cleared when channel closed. |
CH_STAT | QDOS Companion says this about CH_STAT : 0 = OK -1 = A1 has been absolute -128 = A1 passed relative to A6 Any other negatives = waiting SMS states : 0 = ok 1 = waiting -1 = waiting AND A1 is relative A6 |
As stated above, different channel types have different definition blocks. The following tables give details of the different definitions.
Offset | Size | QDOS Mnemonic | SMS Mnemonic | Description |
---|---|---|---|---|
This is the incomplete bit |