diff options
Diffstat (limited to 'v4.0/src/SELECT/GET_STAT.H')
| -rw-r--r-- | v4.0/src/SELECT/GET_STAT.H | 191 |
1 files changed, 191 insertions, 0 deletions
diff --git a/v4.0/src/SELECT/GET_STAT.H b/v4.0/src/SELECT/GET_STAT.H new file mode 100644 index 0000000..d5a5aa0 --- /dev/null +++ b/v4.0/src/SELECT/GET_STAT.H | |||
| @@ -0,0 +1,191 @@ | |||
| 1 | |||
| 2 | /* */ | ||
| 3 | /* */ | ||
| 4 | /****************************************************************************/ | ||
| 5 | /* Define statements */ | ||
| 6 | /****************************************************************************/ | ||
| 7 | /* Get_status Input */ | ||
| 8 | #define FST_DRV 0x01 | ||
| 9 | #define SEC_DRV 0x02 | ||
| 10 | /* */ | ||
| 11 | /* EQUATES FOR N_PART_NAME */ | ||
| 12 | #define E_PART_PRI_DOS 0x01 | ||
| 13 | #define E_PART_EXT_DOS 0x02 | ||
| 14 | #define E_PART_LOG_DRI 0x03 | ||
| 15 | #define E_FREE_MEM_EDOS 0x04 | ||
| 16 | #define E_FREE_MEM_DISK 0x05 | ||
| 17 | #define E_PART_OTHER 0x06 | ||
| 18 | /* */ | ||
| 19 | /* EQUATES FOR N_PART_STATUS */ | ||
| 20 | #define E_PART_UNFORMAT 0x00 | ||
| 21 | #define E_PART_FORMAT 0x01 | ||
| 22 | /* */ | ||
| 23 | /* EQUATES FOR N_PART_TYPE */ | ||
| 24 | #define E_PART_FAT 0x01 | ||
| 25 | #define E_PART_KSAM 0x02 | ||
| 26 | #define E_PART_UNDEF 0x03 | ||
| 27 | #define E_PART_IGNORE 0x04 | ||
| 28 | |||
| 29 | /* DISK_1_TABLE equals M_DISK_1_ITEMS */ | ||
| 30 | /* DISK_1_VAL_ITEM equals zero */ | ||
| 31 | /* DISK_1_START equals 100 times SIZ_DISKSTRUC bytes */ | ||
| 32 | #define M_DISK_1_ITEMS ( sizeof(disk_1_start) / SIZ_DISKSTRUC ) | ||
| 33 | |||
| 34 | |||
| 35 | /* DISK_2_TABLE equals M_DISK_2_ITEMS */ | ||
| 36 | /* DISK_2_VAL_ITEM equals zero */ | ||
| 37 | /* DISK_2_START equals 100 times SIZ_DISKSTRUC bytes */ | ||
| 38 | #define SIZ_DISKSTRUC ( sizeof(struc disk_status)) | ||
| 39 | #define M_DISK_2_ITEMS ( sizeof(disk_2_start) / SIZ_DISKSTRUC ) | ||
| 40 | /* EQUATES FOR BX FLAGS */ | ||
| 41 | #define E_DISK_PRI 0x01 | ||
| 42 | #define E_DISK_EXT_DOS 0x02 | ||
| 43 | #define E_DISK_LOG_DRI 0x04 | ||
| 44 | #define E_DISK_EDOS_MEM 0x08 | ||
| 45 | #define E_DISK_FREE_MEM 0x10 | ||
| 46 | |||
| 47 | |||
| 48 | /* */ | ||
| 49 | |||
| 50 | #define FLAG char /* AN000 */ | ||
| 51 | #define BEGIN { | ||
| 52 | #define END } | ||
| 53 | #define ESC 0x1B | ||
| 54 | #define NUL 0x00 | ||
| 55 | #define NOT_FOUND 0xFF | ||
| 56 | #define DELETED 0xFF | ||
| 57 | #define INVALID 0xFF | ||
| 58 | #define PRIMARY 0x00 | ||
| 59 | #define EXTENDED 0x05 | ||
| 60 | #define BAD_BLOCK 0xFF | ||
| 61 | #define XENIX1 0x02 | ||
| 62 | #define XENIX2 0x03 | ||
| 63 | #define PCIX 0x75 | ||
| 64 | #define DOS12 0x01 | ||
| 65 | #define DOS16 0x04 | ||
| 66 | #define DOSNEW 0x06 /* AN000 */ | ||
| 67 | #define FAT16_SIZE 32680 | ||
| 68 | #define VOLUME 0x00 | ||
| 69 | #define FALSE (char) (1==0) /* AC000 */ | ||
| 70 | #define TRUE (char) !FALSE /* AC000 */ | ||
| 71 | #define LOGICAL 0x05 | ||
| 72 | #define CR 0x0D | ||
| 73 | #define BACKSPACE 0x08 | ||
| 74 | #define ACTIVE 0x80 | ||
| 75 | #define DOS_MAX (64*1024) /* Allow exactly 32mb worth of partitions */ | ||
| 76 | #define SYSTEM_FILE_SECTORS 100 | ||
| 77 | #define BYTES_PER_SECTOR 512 /* AN000 */ | ||
| 78 | |||
| 79 | |||
| 80 | |||
| 81 | #define NETWORK 0x2F | ||
| 82 | #define INSTALLATION_CHECK 0xB800 | ||
| 83 | #define SERVER_CHECK 0x40 | ||
| 84 | |||
| 85 | |||
| 86 | #define FILE_NAME ":\\????????.???" /* AN000 */ | ||
| 87 | #define NOVOLUME " no label " /* AN000 */ | ||
| 88 | #define NOFORMAT " no fmt " /* AN000 */ | ||
| 89 | #define FAT " FAT " /* AN000 */ | ||
| 90 | #define ZERO 0 /* AN000 */ | ||
| 91 | #define NO_GOOD 0x02 /* AN000 */ | ||
| 92 | #define FIND_FIRST_MATCH 0x4E /* AN000 */ | ||
| 93 | #define GET_DTA 0x2F /* AN000 */ | ||
| 94 | #define GENERIC_IOCTL 0x440D /* AN000 */ | ||
| 95 | #define GET_MEDIA_ID 0x086E /* AN000 */ | ||
| 96 | #define CAPCHAR 0x6520 /* AN000 */ | ||
| 97 | #define CAPSTRING 0x6521 /* AN000 */ | ||
| 98 | #define CAP_YN 0x6523 /* AN000 */ | ||
| 99 | #define INT21 0x21 /* AN000 */ | ||
| 100 | #define DISK 0x13 /* AN000 */ | ||
| 101 | #define NOERROR 0 /* AN000 */ | ||
| 102 | #define BLANKS " " /* AN000 */ | ||
| 103 | |||
| 104 | #define READ_DISK 2 | ||
| 105 | #define WRITE_DISK 3 | ||
| 106 | #define DISK_INFO 8 | ||
| 107 | |||
| 108 | |||
| 109 | #define VOL_LABEL 0x08 /* AN000 */ | ||
| 110 | #define PERCENT 0x025 /* AN000 */ | ||
| 111 | #define PERIOD 0x02E /* AN000 */ | ||
| 112 | #define ONE_MEG 1048576 /* AN000 */ | ||
| 113 | |||
| 114 | #define BYTE unsigned char /* AN000 */ | ||
| 115 | #define WORD unsigned short /* AN000 */ | ||
| 116 | #define DWORD unsigned long /* AN000 */ | ||
| 117 | #define sw_type /* AN000 */ | ||
| 118 | #define sw_item_tag /* AN000 */ | ||
| 119 | #define sw_synonym /* AN000 */ | ||
| 120 | #define sw_value /* AN000 */ | ||
| 121 | |||
| 122 | #define CARRY_FLAG 0x0001 /* mask for carry flag */ /* AN000 */ | ||
| 123 | #define PARITY_FLAG 0x0004 /* mask for parity flag */ /* AN000 */ | ||
| 124 | #define ACARRY_FLAG 0x0010 /* mask for aux carry flag */ /* AN000 */ | ||
| 125 | #define ZERO_FLAG 0x0040 /* mask for zero flag */ /* AN000 */ | ||
| 126 | #define SIGN_FLAG 0x0080 /* mask for sign flag */ /* AN000 */ | ||
| 127 | #define TRAP_FLAG 0x0100 /* mask for trap flag */ /* AN000 */ | ||
| 128 | #define INTERRUPT_FLAG 0x0200 /* mask for interrupt flag */ /* AN000 */ | ||
| 129 | #define DIRECTION_FLAG 0x0400 /* mask for direction flag */ /* AN000 */ | ||
| 130 | #define OVERFLOW_FLAG 0x0800 /* mask for overflow flag */ /* AN000 */ | ||
| 131 | |||
| 132 | #define SEMICOLON 0x3B /* AN000 - VALID COMMAND LINE DELIMITER*/ | ||
| 133 | #define XFLOAT unsigned | ||
| 134 | |||
| 135 | #define u(c) ((unsigned)(c)) /* AN000 */ | ||
| 136 | #define c(c) ((char)(c)) /* AN000 */ | ||
| 137 | #define f(c) ((XFLOAT)(c)) /* AN000 */ | ||
| 138 | #define uc(c) ((unsigned char)(c)) /* AN000 */ | ||
| 139 | #define ui(c) ((unsigned int)(c)) /* AN000 */ | ||
| 140 | #define ul(c) ((unsigned long)(c)) /* AN000 */ | ||
| 141 | |||
| 142 | |||
| 143 | struct entry | ||
| 144 | BEGIN | ||
| 145 | unsigned char boot_ind; | ||
| 146 | unsigned char start_head; | ||
| 147 | unsigned char start_sector; | ||
| 148 | unsigned start_cyl; | ||
| 149 | unsigned char sys_id; | ||
| 150 | unsigned char end_head; | ||
| 151 | unsigned char end_sector; | ||
| 152 | unsigned end_cyl; | ||
| 153 | unsigned long rel_sec; | ||
| 154 | unsigned long num_sec; | ||
| 155 | char order; | ||
| 156 | FLAG formatted; | ||
| 157 | XFLOAT mbytes_used; /* AN000 */ | ||
| 158 | char drive_letter; /* AN000 */ | ||
| 159 | char system_level[4]; /* AN000 */ | ||
| 160 | END; | ||
| 161 | |||
| 162 | struct DISK_STATUS | ||
| 163 | BEGIN | ||
| 164 | unsigned char n_part_name ; | ||
| 165 | unsigned n_part_size ; | ||
| 166 | unsigned char n_part_status; | ||
| 167 | unsigned char p_part_drive ; /* AN000 */ | ||
| 168 | unsigned char n_part_type ; /* AN000 */ | ||
| 169 | char n_part_level[4]; /* AN000 */ | ||
| 170 | END OneDiskStatusEntry; /* TWO ARRAYS to be OUTPUT in ES:DI */ | ||
| 171 | |||
| 172 | typedef struct DISK_STATUS DSE ; | ||
| 173 | |||
| 174 | struct freespace | ||
| 175 | BEGIN | ||
| 176 | unsigned space; | ||
| 177 | unsigned start; | ||
| 178 | unsigned end; | ||
| 179 | unsigned mbytes_unused; /* AN000 */ | ||
| 180 | END; | ||
| 181 | |||
| 182 | struct dx_buffer_ioctl /* AN000 */ | ||
| 183 | BEGIN /* AN000 */ | ||
| 184 | unsigned int info_level; /* Information level */ /* AN000 */ | ||
| 185 | unsigned long serial_num; /* serial number */ /* AN000 */ | ||
| 186 | char vol_label[9]; /* volume label */ /* AN000 */ | ||
| 187 | char file_system[12]; /* file system */ /* AN000 */ | ||
| 188 | END; /* AN000 */ | ||
| 189 | |||
| 190 | |||
| 191 | |||