X-Git-Url: https://git.subgeniuskitty.com/unix-history/.git/blobdiff_plain/8959d9ceb7ede89a5fdde784c92eacf47aac87e3..5c0abf7f0266f9f08a9c0e711dc0c2d70840421b:/usr/src/include/protocols/dumprestore.h diff --git a/usr/src/include/protocols/dumprestore.h b/usr/src/include/protocols/dumprestore.h index 100be0dce1..72291cdf27 100644 --- a/usr/src/include/protocols/dumprestore.h +++ b/usr/src/include/protocols/dumprestore.h @@ -1,10 +1,20 @@ /* Copyright (c) 1981 Regents of the University of California */ -/* "@(#)dumprestore.h 1.1 %G%" */ +/* "@(#)dumprestore.h 2.4 %G%" */ +/* + * TP_BSIZE is the size of file blocks on the dump tapes. + * Note that TP_BSIZE must be a multiple of DEV_BSIZE. + * + * NTREC is the number of TP_BSIZE blocks that are written + * in each tape record. + * + * TP_NINDIR is the number of indirect pointers in a TS_INODE + * or TS_ADDR record. Note that it must be a power of two. + */ +#define TP_BSIZE 1024 #define NTREC 10 -#define MLEN 16 -#define MSIZ 4096 +#define TP_NINDIR (TP_BSIZE/2) #define TS_TAPE 1 #define TS_INODE 2 @@ -12,28 +22,28 @@ #define TS_ADDR 4 #define TS_END 5 #define TS_CLRI 6 -#define MAGIC (int)60011 +#define OFS_MAGIC (int)60011 +#define NFS_MAGIC (int)60012 #define CHECKSUM (int)84446 -struct spcl { - int c_type; - time_t c_date; - time_t c_ddate; - int c_volume; - daddr_t c_tapea; - ino_t c_inumber; - int c_magic; - int c_checksum; - struct dinode c_dinode; - int c_count; - char c_addr[BSIZE]; -} spcl; +union u_spcl { + char dummy[TP_BSIZE]; + struct s_spcl { + int c_type; + time_t c_date; + time_t c_ddate; + int c_volume; + daddr_t c_tapea; + ino_t c_inumber; + int c_magic; + int c_checksum; + struct dinode c_dinode; + int c_count; + char c_addr[TP_NINDIR]; + } s_spcl; +} u_spcl; -struct idates { - char id_name[16]; - char id_incno; - time_t id_ddate; -}; +#define spcl u_spcl.s_spcl #define DUMPOUTFMT "%-16s %c %s" /* for printf */ /* name, incno, ctime(date) */