--******************************************************************************************************************** -- Created: 9-Mar-2021 22:28:22 by OpenVMS SDL EV3-3 -- Source: 29-JUL-2004 17:27:37 $1$DGA8085:[LIB_ADA.LIS]EMBHDDEF.SDL;1 --******************************************************************************************************************** with SYSTEM; use SYSTEM; with STARLET; use STARLET; with CONDITION_HANDLING; use CONDITION_HANDLING; package EMBHDDEF is -- module $EMBHDDEF -- -- ERROR MESSAGE BUFFER HEADER -- -- Header revisions EMB_K_HD_REV_V50 : constant := 2; EMB_K_HD_REV_V51 : constant := 3; EMB_K_HD_REV_HICKORY : constant := 4; EMB_K_HD_REV_V10 : constant := 5; EMB_K_HD_REV_V20 : constant := 6; EMB_K_HD_REV_V30 : constant := 7; -- Header revisions EMB_C_HD_REV_V50 : constant := 2; EMB_C_HD_REV_V51 : constant := 3; EMB_C_HD_REV_HICKORY : constant := 4; EMB_C_HD_REV_V10 : constant := 5; EMB_C_HD_REV_V20 : constant := 6; EMB_C_HD_REV_V30 : constant := 7; -- OS ID's EMB_C_OS_RESERVED : constant := 0; EMB_C_OS_VAXVMS : constant := 1; EMB_C_OS_VAXELN : constant := 2; EMB_C_OS_ALPHAVMS : constant := 3; -- OS ID's EMB_K_OS_RESERVED : constant := 0; EMB_K_OS_VAXVMS : constant := 1; EMB_K_OS_VAXELN : constant := 2; EMB_K_OS_ALPHAVMS : constant := 3; -- This determines the SCS node name buffer size subtype SCS_NAME_LEN_TYPE is STRING(1 .. 16); -- Define type so other EMBxxxDEF files can use it. EMB_C_SCS_NAME_LENGTH : constant := 16; -- Buffer size for SCS name EMB_K_SCS_NAME_LENGTH : constant := 16; -- Buffer size for SCS name type EMB_HD_SYSTYPE_TYPE is -- System type register record HD_XSID_RSV : UNSIGNED_WORD; -- Reserved for type-dependent info HD_XSID_REV : UNSIGNED_BYTE; -- Revision level of CPU HD_XSID_TYP : UNSIGNED_BYTE; -- Sys type, CPU type end record; for EMB_HD_SYSTYPE_TYPE use record HD_XSID_RSV at 0 range 0 .. 15; HD_XSID_REV at 2 range 0 .. 7; HD_XSID_TYP at 3 range 0 .. 7; end record; for EMB_HD_SYSTYPE_TYPE'SIZE use 32; EMB_HD_SYSTYPE_TYPE_INIT : constant EMB_HD_SYSTYPE_TYPE := (HD_XSID_RSV => 0, HD_XSID_REV => 0, HD_XSID_TYP => 0); type EMB_HD_ENTRY_TYPE is -- Entry type record DEVTYP : UNSIGNED_BYTE; -- Device type DEVCLS : UNSIGNED_BYTE; -- Device class end record; for EMB_HD_ENTRY_TYPE use record DEVTYP at 0 range 0 .. 7; DEVCLS at 1 range 0 .. 7; end record; for EMB_HD_ENTRY_TYPE'SIZE use 16; EMB_HD_ENTRY_TYPE_INIT : constant EMB_HD_ENTRY_TYPE := (DEVTYP => 0, DEVCLS => 0); type EMBHD_NONFIXED_TYPE is record -- -- Starting with HD_SID, this aggregate is common to all EMBxxxDEF modules, -- so a change here requires a corresponding change to those modules, as well -- as an increase to the header revision. -- HD_SID : UNSIGNED_LONGWORD; -- System ID HD_HDR_REV : UNSIGNED_WORD; -- Header revision (in 1's complement) HD_SYSTYPE : EMB_HD_SYSTYPE_TYPE; -- System type register CPUID : UNSIGNED_LONGWORD; -- Unique CPU ID DEV_CLASS : UNSIGNED_BYTE; -- Device class DEV_TYPE : UNSIGNED_BYTE; -- Device type SCS_NAME : SCS_NAME_LEN_TYPE; -- SCS node name ASCIC FLAGS : UNSIGNED_WORD; -- Misc. flags OS_ID : UNSIGNED_BYTE; -- Logging OS ID HDRSZ : UNSIGNED_BYTE; -- Size of this header HD_ENTRY : EMB_HD_ENTRY_TYPE; -- Entry type HD_TIME : UNSIGNED_QUADWORD; -- Time of entry HD_ERRSEQ : UNSIGNED_WORD; -- Error sequence number HD_SWVERS : UNSIGNED_QUADWORD; -- Software version HD_ERRMSK : UNSIGNED_LONGWORD; -- Error mask HD_ABSTIM : UNSIGNED_LONGWORD; -- Contents of exe$gl_abstim HD_HW_NAME_LEN : UNSIGNED_BYTE; -- Length of marketing name of this system HD_HW_NAME : STRING(1 .. 31); -- Marketing name of this system end record; for EMBHD_NONFIXED_TYPE use record HD_SID at 0 range 0 .. 31; HD_HDR_REV at 4 range 0 .. 15; HD_SYSTYPE at 6 range 0 .. 31; CPUID at 10 range 0 .. 31; DEV_CLASS at 14 range 0 .. 7; DEV_TYPE at 15 range 0 .. 7; SCS_NAME at 16 range 0 .. 127; FLAGS at 32 range 0 .. 15; OS_ID at 34 range 0 .. 7; HDRSZ at 35 range 0 .. 7; HD_ENTRY at 36 range 0 .. 15; HD_TIME at 38 range 0 .. 63; HD_ERRSEQ at 46 range 0 .. 15; HD_SWVERS at 48 range 0 .. 63; HD_ERRMSK at 56 range 0 .. 31; HD_ABSTIM at 60 range 0 .. 31; HD_HW_NAME_LEN at 64 range 0 .. 7; HD_HW_NAME at 65 range 0 .. 247; end record; for EMBHD_NONFIXED_TYPE'SIZE use 768; EMBHD_NONFIXED_TYPE_INIT : constant EMBHD_NONFIXED_TYPE := (HD_SID => 0, HD_HDR_REV => 0, HD_SYSTYPE => EMB_HD_SYSTYPE_TYPE_INIT, CPUID => 0, DEV_CLASS => 0, DEV_TYPE => 0, SCS_NAME => SCS_NAME_LEN_TYPE_INIT, FLAGS => 0, OS_ID => 0, HDRSZ => 0, HD_ENTRY => EMB_HD_ENTRY_TYPE_INIT, HD_TIME => (0, 0), HD_ERRSEQ => 0, HD_SWVERS => (0, 0), HD_ERRMSK => 0, HD_ABSTIM => 0, HD_HW_NAME_LEN => 0, HD_HW_NAME => (others => ASCII.NUL)); EMB_K_HD_LENGTH : constant := 96; -- Length of header that is common to all messages EMB_C_HD_LENGTH : constant := 96; -- Length of header that is common to all messages EMB_C_LENGTH : constant := 16; -- LENGTH OF FIXED PART OF MESSAGE HEADER EMB_K_LENGTH : constant := 16; -- LENGTH OF FIXED PART OF MESSAGE HEADER EMB_S_EMBHDDEF : constant := 112; -- Old size name - synonym type EMB_SIZE_TYPE is -- Size of error message in bytes - new style record record SIZE : UNSIGNED_WORD; -- Size of error message in bytes - old style record FILLER_1 : UNSIGNED_WORD; end record; for EMB_SIZE_TYPE use record SIZE at 0 range 0 .. 15; FILLER_1 at 2 range 0 .. 15; end record; for EMB_SIZE_TYPE'SIZE use 32; EMB_SIZE_TYPE_INIT : constant EMB_SIZE_TYPE := (SIZE => 0, FILLER_1 => 0); type EMBHD_TYPE is record FILLER_1 : UNSIGNED_LONGWORD; SIZE : EMB_SIZE_TYPE; -- Size of error message in bytes - new style record BUFIND : UNSIGNED_LONGWORD; -- Buffer index VALID : UNSIGNED_BYTE; -- Error message valid indicator FILLER_2 : UNSIGNED_BYTE_ARRAY (1 .. 3); EMBHD_NONFIXED : EMBHD_NONFIXED_TYPE; -- Non-fixed part of message header end record; for EMBHD_TYPE use record FILLER_1 at 0 range 0 .. 31; SIZE at 4 range 0 .. 31; BUFIND at 8 range 0 .. 31; VALID at 12 range 0 .. 7; FILLER_2 at 13 range 0 .. 23; EMBHD_NONFIXED at 16 range 0 .. 767; end record; for EMBHD_TYPE'SIZE use 896; EMBHD_TYPE_INIT : constant EMBHD_TYPE := (FILLER_1 => 0, SIZE => EMB_SIZE_TYPE_INIT, BUFIND => 0, VALID => 0, FILLER_2 => (others => 0), EMBHD_NONFIXED => EMBHD_NONFIXED_TYPE_INIT); type EMBTRAILER_TYPE is record TR_S2_BUF_ADDR : UNSIGNED_QUADWORD; TR_SPARE : INTEGER_32; TR_ACTUAL_SIZE : INTEGER_32; TR_ACTIVE_CPUS : UNSIGNED_LONGWORD; TR_LOGGING_CPU : UNSIGNED_LONGWORD; TR_TDF : UNSIGNED_QUADWORD; end record; for EMBTRAILER_TYPE use record TR_S2_BUF_ADDR at 0 range 0 .. 63; TR_SPARE at 8 range 0 .. 31; TR_ACTUAL_SIZE at 12 range 0 .. 31; TR_ACTIVE_CPUS at 16 range 0 .. 31; TR_LOGGING_CPU at 20 range 0 .. 31; TR_TDF at 24 range 0 .. 63; end record; for EMBTRAILER_TYPE'SIZE use 256; EMBTRAILER_TYPE_INIT : constant EMBTRAILER_TYPE := (TR_S2_BUF_ADDR => (0, 0), TR_SPARE => 0, TR_ACTUAL_SIZE => 0, TR_ACTIVE_CPUS => 0, TR_LOGGING_CPU => 0, TR_TDF => (0, 0)); EMB_C_TR_LENGTH : constant := 32; -- Length of EMB trailer EMB_K_TR_LENGTH : constant := 32; -- Length of EMB trailer EMB_M_EM_BUS : constant := 16#00000001#; EMB_M_EM_CPU : constant := 16#00000002#; EMB_M_EM_MEMORY : constant := 16#00000004#; EMB_M_EM_ADAPTER : constant := 16#00000008#; EMB_M_EM_CACHE : constant := 16#00000010#; EMB_M_EM_VECTOR : constant := 16#00000020#; EMB_M_RSRVD1 : constant := 16#00000040#; type EMB_ERRMSK_TYPE is record EM_BUS : BOOLEAN; -- Bus error EM_CPU : BOOLEAN; -- CPU error EM_MEMORY : BOOLEAN; -- Memory error EM_ADAPTER : BOOLEAN; -- Adapter error EM_CACHE : BOOLEAN; -- Cache error EM_VECTOR : BOOLEAN; -- Vector error RSRVD1 : BOOLEAN; -- Reserved FILLER_1 : UNSIGNED_25; end record; for EMB_ERRMSK_TYPE use record EM_BUS at 0 range 0 .. 0; EM_CPU at 0 range 1 .. 1; EM_MEMORY at 0 range 2 .. 2; EM_ADAPTER at 0 range 3 .. 3; EM_CACHE at 0 range 4 .. 4; EM_VECTOR at 0 range 5 .. 5; RSRVD1 at 0 range 6 .. 6; FILLER_1 at 0 range 7 .. 31; end record; for EMB_ERRMSK_TYPE'SIZE use 32; EMB_M_FL_DDR : constant := 16#00000001#; EMB_M_FL_OVWRT : constant := 16#00000002#; type EMB_FLAGS_TYPE is record FL_DDR : BOOLEAN; -- DDR packet flag FL_OVWRT : BOOLEAN; -- Overwrite detected FILLER_1 : UNSIGNED_30; end record; for EMB_FLAGS_TYPE use record FL_DDR at 0 range 0 .. 0; FL_OVWRT at 0 range 1 .. 1; FILLER_1 at 0 range 2 .. 31; end record; for EMB_FLAGS_TYPE'SIZE use 32; end EMBHDDEF;