.TITLE NETDSC Disconnect a logical link .IDENT "X1.1" .ENABL LC .NLIST BEX,CND,TOC ;+ ; Index Disconnect a logical link ; ; Usage ; ; #include /* NSP defs */ ; ; int lun; /* Logical link LUN */ ; int efn; /* Event flag # for wait */ ; int status[2]; /* Status block */ ; {typ} astsrv(); /* AST service routine */ ; char *out; /* Optional 1-16 byte msg. */ ; int outlen; /* Length of optional msg. */ ; int dir_stat; /* Directive status ($DSW) */ ; ; dir_stat = netdsc(lun, efn, status, astsrv, out, ; outlen); ; ; Description ; ; netdsc() can be issued by either the client or server task to ; disconnect a logical link. Unlike netabt(), netdsc() causes all ; pending transmits to complete before disconnecting the link. ; Once the last pending transmit has completed, any pending ; receives are aborted, with IE.ABO as the receive status return. ; The task will continue to receive messages until all of its ; pending transmits complete. The LUN is then freed. For more ; info, see the RSX DECnet Programmer's Reference Manual ; (May, 1982), section 2.8.6. ; ; You may optionally send a 1- to 16-byte message to the task at ; the other end of the link. ; ; The function returns $DSW. ; ; Notes ; ; The "out" and "outlen" parameters must either be both zero, or ; they must both be 'live'. ; ; The first three parameters are required! ;- ; ; Edits: ; ; X1.0 27-Feb-83 RBD Initial edit ; X1.1 31-Jan-02 BQT Changed for I/D space. ; .psect c$code,i,ro .mcall dsc$s NETDSC:: mov sp,r0 ; r0 --> parameter list dsc$s 2(r0),4(r0),6(r0),10(r0),<12(r0),14(r0)> mov $dsw,r0 ; Return $DSW return .end