1: /*
   2:  * msdos common header file
   3:  */
   4: 
   5: #define MSECTOR_SIZE    512     /* MSDOS sector size in bytes */
   6: #define MDIR_SIZE   32      /* MSDOS directory size in bytes */
   7: #define MAX_CLUSTER 8192        /* largest cluster size */
   8: #define MAX_PATH    128     /* largest MSDOS path length */
   9: #define MAX_DIR_SECS    64      /* largest directory (in sectors) */
  10: 
  11: #define NEW     1
  12: #define OLD     0
  13: 
  14: struct directory {
  15:     unsigned char name[8];      /* file name */
  16:     unsigned char ext[3];       /* file extension */
  17:     unsigned char attr;     /* attribute byte */
  18:     unsigned char reserved[10]; /* ?? */
  19:     unsigned char time[2];      /* time stamp */
  20:     unsigned char date[2];      /* date stamp */
  21:     unsigned char start[2];     /* starting cluster number */
  22:     unsigned char size[4];      /* size of the file */
  23: };
  24: 
  25: struct device {
  26:     char drive;         /* the drive letter */
  27:     char *name;         /* full path to device */
  28:     long offset;            /* skip this many bytes */
  29:     int fat_bits;           /* FAT encoding scheme */
  30:     int mode;           /* any special open() flags */
  31:     int (*gioctl) ();       /* gioctl() function if needed */
  32:     int tracks;         /* tracks */
  33:     int heads;          /* heads */
  34:     int sectors;            /* sectors */
  35: };
  36: 
  37: struct bootsector {
  38:     unsigned char jump[3];      /* Jump to boot code */
  39:     unsigned char banner[8];    /* OEM name & version */
  40:     unsigned char secsiz[2];    /* Bytes per sector hopefully 512 */
  41:     unsigned char clsiz;        /* Cluster size in sectors */
  42:     unsigned char nrsvsect[2];  /* Number of reserved (boot) sectors */
  43:     unsigned char nfat;     /* Number of FAT tables hopefully 2 */
  44:     unsigned char dirents[2];   /* Number of directory slots */
  45:     unsigned char psect[2];     /* Total sectors on disk */
  46:     unsigned char descr;        /* Media descriptor=first byte of FAT */
  47:     unsigned char fatlen[2];    /* Sectors in FAT */
  48:     unsigned char nsect[2];     /* Sectors/track */
  49:     unsigned char nheads[2];    /* Heads */
  50:     unsigned char nhs[4];       /* number of hidden sectors */
  51:     unsigned char bigsect[4];   /* big total sectors */
  52:     unsigned char junk[476];    /* who cares? */
  53: };
  54: 
  55: /* typedef void SIG_TYPE; */
  56: typedef int SIG_TYPE;
  57: 
  58: #ifdef BSD
  59: #define strchr index
  60: #define strrchr rindex
  61: #endif /* BSD */

Defined struct's

bootsector defined in line 37; used 10 times
device defined in line 25; used 20 times

Defined typedef's

Defined macros

NEW defined in line 11; used 1 times
OLD defined in line 12; used 4 times
strchr defined in line 59; used 3 times
strrchr defined in line 60; used 9 times

Usage of this include

Last modified: 1992-06-24
Generated: 2016-12-26
Generated by src2html V0.67
page hit count: 2152
Valid CSS Valid XHTML 1.0 Strict