Annotation of truecrypt/common/fat.h, revision 1.1.1.2

1.1.1.2 ! root        1: /* Copyright (C) 2004 TrueCrypt Foundation
1.1       root        2:    This product uses components written by Paul Le Roux <[email protected]> */
                      3: 
                      4: typedef struct fatparams_t
                      5: {
                      6:        char volume_name[11];
                      7:        int num_sectors;        /* total number of sectors */
                      8:        int cluster_count;      /* number of clusters */
                      9:        int size_root_dir;      /* size of the root directory in bytes */
                     10:        int size_fat;           /* size of FAT */
                     11:        int fats;
                     12:        long create_time;
                     13:        int media;
                     14:        int cluster_size;
                     15:        int fat_length;
                     16:        int dir_entries;
                     17:        int sector_size;
                     18:        int hidden;
                     19:        int sectors;
                     20:        long total_sect;
                     21: 
                     22:        int heads;
                     23:        int secs_track;
                     24: 
                     25:        char header[SECTOR_SIZE];
                     26: } fatparams;
                     27: 
                     28: 
                     29: struct msdos_boot_sector
                     30: {
                     31:        unsigned char boot_jump[3];     /* Boot strap short or near jump */
                     32:        char system_id[8];      /* Name - can be used to special case
                     33:                                   partition manager volumes */
                     34:        unsigned char sector_size[2];   /* bytes per logical sector */
                     35:        unsigned char cluster_size;     /* sectors/cluster */
                     36:        unsigned short reserved;/* reserved sectors */
                     37:        unsigned char fats;     /* number of FATs */
                     38:        unsigned char dir_entries[2];   /* root directory entries */
                     39:        unsigned char sectors[2];       /* number of sectors */
                     40:        unsigned char media;    /* media code  */
                     41:        unsigned short fat_length;      /* sectors/FAT */
                     42:        unsigned short secs_track;      /* sectors per track */
                     43:        unsigned short heads;   /* number of heads */
                     44:        unsigned long hidden;   /* hidden sectors */
                     45:        unsigned long total_sect;       /* number of sectors (if sectors ==
                     46:                                           0) */
                     47:        unsigned char drive_number;     /* BIOS drive number */
                     48:        unsigned char RESERVED; /* Unused */
                     49:        unsigned char ext_boot_sign;    /* 0x29 if fields below exist (DOS
                     50:                                           3.3+) */
                     51:        unsigned char volume_id[4];     /* Volume ID number */
                     52:        char volume_label[11];  /* Volume label */
                     53:        char fs_type[8];        /* Typically FAT12 or FAT16 */
                     54:        unsigned char boot_code[448];   /* Boot code (or message) */
                     55:        unsigned short boot_sign;       /* 0xAA55 */
                     56: };
                     57: 
                     58: 
                     59: /* Everything below this line is automatically updated by the -mkproto-tool- */
                     60: 
                     61: void GetFatParams ( fatparams *ft );
                     62: void PutBoot ( fatparams *ft , unsigned char *boot );
                     63: BOOL WriteSector ( HFILE dev , char *sector , char *write_buf , int *write_buf_cnt , __int64 *nSecNo , int *progress , PCRYPTO_INFO cryptoInfo , int nFrequency , diskio_f write );
                     64: int Format (fatparams * ft, HFILE dev, PCRYPTO_INFO cryptoInfo, int nFrequency, diskio_f write, BOOL quickFormat);

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.