[PEN_CHECKING_STYLE(NONE)] MODULE PASCAL$SMB_ROUTINES; { © Copyright 2005 Hewlett-Packard Development Company, L.P. } { } { Confidential computer software. Valid license from HP and/or } { its subsidiaries required for possession, use, or copying. } { } { Consistent with FAR 12.211 and 12.212, Commercial Computer Software, } { Computer Software Documentation, and Technical Data for Commercial } { Items are licensed to the U.S. Government under vendor's standard } { commercial license. } { } { Neither HP nor any of its subsidiaries shall be liable for technical } { or editorial errors or omissions contained herein. The information } { in this document is provided "as is" without warranty of any kind and } { is subject to change without notice. The warranties for HP products } { are set forth in the express limited warranty statements accompanying } { such products. Nothing herein should be construed as constituting an } { additional warranty. } { } [HIDDEN] TYPE (**** Pre-declared data types ****) $BYTE = [BYTE] -128..127; $WORD = [WORD] -32768..32767; $QUAD = [QUAD,UNSAFE] RECORD L0:UNSIGNED; L1:INTEGER; END; $OCTA = [OCTA,UNSAFE] RECORD L0,L1,L2:UNSIGNED; L3:INTEGER; END; $UBYTE = [BYTE] 0..255; $UWORD = [WORD] 0..65535; $UQUAD = [QUAD,UNSAFE] RECORD L0,L1:UNSIGNED; END; $UOCTA = [OCTA,UNSAFE] RECORD L0,L1,L2,L3:UNSIGNED; END; $PACKED_DEC = [BIT(4),UNSAFE] 0..15; $DEFTYP = [UNSAFE] INTEGER; $DEFPTR = [UNSAFE] ^$DEFTYP; $BOOL = [BIT(1),UNSAFE] BOOLEAN; $BIT = [BIT(1),UNSAFE] BOOLEAN; $BIT2 = [BIT(2),UNSAFE] 0..3; $BIT3 = [BIT(3),UNSAFE] 0..7; $BIT4 = [BIT(4),UNSAFE] 0..15; $BIT5 = [BIT(5),UNSAFE] 0..31; $BIT6 = [BIT(6),UNSAFE] 0..63; $BIT7 = [BIT(7),UNSAFE] 0..127; $BIT8 = [BIT(8),UNSAFE] 0..255; $BIT9 = [BIT(9),UNSAFE] 0..511; $BIT10 = [BIT(10),UNSAFE] 0..1023; $BIT11 = [BIT(11),UNSAFE] 0..2047; $BIT12 = [BIT(12),UNSAFE] 0..4095; $BIT13 = [BIT(13),UNSAFE] 0..8191; $BIT14 = [BIT(14),UNSAFE] 0..16383; $BIT15 = [BIT(15),UNSAFE] 0..32767; $BIT16 = [BIT(16),UNSAFE] 0..65535; $BIT17 = [BIT(17),UNSAFE] 0..131071; $BIT18 = [BIT(18),UNSAFE] 0..262143; $BIT19 = [BIT(19),UNSAFE] 0..524287; $BIT20 = [BIT(20),UNSAFE] 0..1048575; $BIT21 = [BIT(21),UNSAFE] 0..2097151; $BIT22 = [BIT(22),UNSAFE] 0..4194303; $BIT23 = [BIT(23),UNSAFE] 0..8388607; $BIT24 = [BIT(24),UNSAFE] 0..16777215; $BIT25 = [BIT(25),UNSAFE] 0..33554431; $BIT26 = [BIT(26),UNSAFE] 0..67108863; $BIT27 = [BIT(27),UNSAFE] 0..134217727; $BIT28 = [BIT(28),UNSAFE] 0..268435455; $BIT29 = [BIT(29),UNSAFE] 0..536870911; $BIT30 = [BIT(30),UNSAFE] 0..1073741823; $BIT31 = [BIT(31),UNSAFE] 0..2147483647; $BIT32 = [BIT(32),UNSAFE] UNSIGNED; (* MODULE SMB$ROUTINES ; *) (* [HIDDEN] TYPE (**** Pre-declared data types ***?? *) (* $BYTE = [BYTE] -128..127; *) (* $WORD = [WORD] -32768..32767; *) (* $QUAD = [QUAD,UNSAFE] RECORD *) (* L0:UNSIGNED; L1:INTEGER; END; *) (* $OCTA = [OCTA,UNSAFE] RECORD *) (* L0,L1,L2:UNSIGNED; L3:INTEGER; END; *) (* $UBYTE = [BYTE] 0..255; *) (* $UWORD = [WORD] 0..65535; *) (* $UQUAD = [QUAD,UNSAFE] RECORD *) (* L0,L1:UNSIGNED; END; *) (* $UOCTA = [OCTA,UNSAFE] RECORD *) (* L0,L1,L2,L3:UNSIGNED; END; *) (* $UOCTAQUAD = [OCTA(2),UNSAFE] RECORD *) (* L0,L1,L2,L3,L4,L5,L6,L7:UNSIGNED; END; *) (* $PACKED_DEC = [BIT(4),UNSAFE] 0..15; *) (* $DEFTYP = [UNSAFE] INTEGER; *) (* $DEFPTR = [UNSAFE] ^$DEFTYP; *) (* $BOOL = [BIT(1),UNSAFE] BOOLEAN; *) (* $BIT2 = [BIT(2),UNSAFE] 0..3; *) (* $BIT3 = [BIT(3),UNSAFE] 0..7; *) (* $BIT4 = [BIT(4),UNSAFE] 0..15; *) (* $BIT5 = [BIT(5),UNSAFE] 0..31; *) (* $BIT6 = [BIT(6),UNSAFE] 0..63; *) (* $BIT7 = [BIT(7),UNSAFE] 0..127; *) (* $BIT8 = [BIT(8),UNSAFE] 0..255; *) (* $BIT9 = [BIT(9),UNSAFE] 0..511; *) (* $BIT10 = [BIT(10),UNSAFE] 0..1023; *) (* $BIT11 = [BIT(11),UNSAFE] 0..2047; *) (* $BIT12 = [BIT(12),UNSAFE] 0..4095; *) (* $BIT13 = [BIT(13),UNSAFE] 0..8191; *) (* $BIT14 = [BIT(14),UNSAFE] 0..16383; *) (* $BIT15 = [BIT(15),UNSAFE] 0..32767; *) (* $BIT16 = [BIT(16),UNSAFE] 0..65535; *) (* $BIT17 = [BIT(17),UNSAFE] 0..131071; *) (* $BIT18 = [BIT(18),UNSAFE] 0..262143; *) (* $BIT19 = [BIT(19),UNSAFE] 0..524287; *) (* $BIT20 = [BIT(20),UNSAFE] 0..1048575; *) (* $BIT21 = [BIT(21),UNSAFE] 0..2097151; *) (* $BIT22 = [BIT(22),UNSAFE] 0..4194303; *) (* $BIT23 = [BIT(23),UNSAFE] 0..8388607; *) (* $BIT24 = [BIT(24),UNSAFE] 0..16777215; *) (* $BIT25 = [BIT(25),UNSAFE] 0..33554431; *) (* $BIT26 = [BIT(26),UNSAFE] 0..67108863; *) (* $BIT27 = [BIT(27),UNSAFE] 0..134217727; *) (* $BIT28 = [BIT(28),UNSAFE] 0..268435455; *) (* $BIT29 = [BIT(29),UNSAFE] 0..536870911; *) (* $BIT30 = [BIT(30),UNSAFE] 0..1073741823; *) (* $BIT31 = [BIT(31),UNSAFE] 0..2147483647; *) (* $BIT32 = [BIT(32),UNSAFE] UNSIGNED; *) (*** MODULE SMB$ROUTINES IDENT X-1 ***) (* *) (* Symbiont/Job Controller Interface (SMB) Routines *) (* *) (* *) (* SMB$CHECK_FOR_MESSAGE - Check for Message from Job Controller *) (* *) (* status = SMB$CHECK_FOR_MESSAGE () *) (* *) [ASYNCHRONOUS] FUNCTION SMB$CHECK_FOR_MESSAGE : INTEGER; EXTERNAL; (* *) (* SMB$INITIALIZE - Initialize User-Written Symbiont *) (* *) (* status = SMB$INITIALIZE (structure_level [,ast_routine] [,streams]) *) (* *) (* structure_level - Version of the job-controller/symbiont interface *) (* ast_routine - Message-handling AST routine *) (* streams - Maximum number of streams to support *) (* *) [ASYNCHRONOUS] FUNCTION SMB$INITIALIZE ( STRUCTURE_LEVEL : UNSIGNED; %IMMED [UNBOUND, ASYNCHRONOUS] PROCEDURE AST_ROUTINE := %IMMED 0; STREAMS : UNSIGNED := %IMMED 0) : INTEGER; EXTERNAL; (* *) (* SMB$READ_MESSAGE - Obtain Message Sent by Job Controller *) (* *) (* status = SMB$READ_MESSAGE (stream, buffer, request) *) (* *) (* stream - Stream number for message *) (* buffer - Buffer into which message is written *) (* request - Code that identifies the request *) (* *) [ASYNCHRONOUS] FUNCTION SMB$READ_MESSAGE ( VAR STREAM : [VOLATILE] UNSIGNED; VAR BUFFER : [CLASS_S,VOLATILE] PACKED ARRAY [$l2..$u2:INTEGER] OF CHAR; VAR REQUEST : [VOLATILE] UNSIGNED) : INTEGER; EXTERNAL; (* *) (* SMB$READ_MESSAGE_ITEM - Parse Next Item from Message Buffer *) (* *) (* status = SMB$READ_MESSAGE_ITEM (message, context, item_code, buffer *) (* [, size]) *) (* *) (* message - Message items to read *) (* context - Context value *) (* item_code - Item code of message read *) (* buffer - Message item *) (* size - Size of message item *) (* *) [ASYNCHRONOUS] FUNCTION SMB$READ_MESSAGE_ITEM ( MESSAGE : [CLASS_S] PACKED ARRAY [$l1..$u1:INTEGER] OF CHAR; VAR CONTEXT : [VOLATILE] UNSIGNED; VAR ITEM_CODE : [VOLATILE] UNSIGNED; VAR BUFFER : [CLASS_S,VOLATILE] PACKED ARRAY [$l4..$u4:INTEGER] OF CHAR; VAR SIZE : [VOLATILE] $UWORD := %IMMED 0) : INTEGER; EXTERNAL; (* *) (* SMB$SEND_TO_JOBCTL - Send Message to Job Controller *) (* *) (* status = SMB$SEND_TO_JOBCTL (stream [,request] [,accounting] *) (* [,checkpoint] [,device_status] [,error]) *) (* *) (* stream - Number of stream to which message refers *) (* request - Code identifying request being completed *) (* accounting - Accounting information about a task *) (* checkpoint - Checkpoint data about current task *) (* device_status - Status of device served by the symbiont *) (* error - Condition code returned by the requested task *) (* *) [ASYNCHRONOUS] FUNCTION SMB$SEND_TO_JOBCTL ( STREAM : UNSIGNED; REQUEST : UNSIGNED := %IMMED 0; ACCOUNTING : [CLASS_S] PACKED ARRAY [$l3..$u3:INTEGER] OF CHAR := %IMMED 0; CHECKPOINT : [CLASS_S] PACKED ARRAY [$l4..$u4:INTEGER] OF CHAR := %IMMED 0; DEVICE_STATUS : UNSIGNED := %IMMED 0; %REF ERROR : ARRAY [$l6..$u6:INTEGER] OF UNSIGNED := %IMMED 0) : INTEGER; EXTERNAL; (* END. *) END.