/* <vms/lib/bbmdef.h>
 *
 *	F11DEF - bad block map definitions	[not in Starlet]
 */
#ifndef _BBMDEF_H
#define _BBMDEF_H

/*
   Bad block map (generated by bad block scan program)
 */
#define BBM$K_POINTERS	4	/* start of retrieval pointers */
#define BBM$C_POINTERS	4
#define BBM$S_BBMDEF	512
struct bbmdef {
    unsigned char bbm$b_countsize;	/* retrieval pointer count field size */
    unsigned char bbm$b_lbnsize;	/* retrieval pointer LBN field size */
    unsigned char bbm$b_inuse;		/* number of retrieval words in use */
    unsigned char bbm$b_avail;		/* number of retrieval words available */
    char bbmdef$$_fill[506];		/* pointer space */
    unsigned short bbm$w_checksum;	/* block checksum */
};
/* retrieval pointer formats */
#define BBM$S_BBMDEF1	4
struct bbmdef1 {
    unsigned char bbm$b_highlbn;	/* high order LBN */
    unsigned char bbm$b_count;		/* block count */
    unsigned short bbm$w_lowlbn;	/* low order LBN */
};
#define BBM$S_BBMDEF2	5
struct bbmdef2 {		/* origin has offset -4 */
    unsigned char bbm$b_prevhlbn;
    unsigned char bbm$b_prevcount;
    unsigned short bbm$w_prevllbn;	/* previous retrieval pointer */
    unsigned	: 8;
};

#endif	/*_BBMDEF_H*/
