home *** CD-ROM | disk | FTP | other *** search
/ Amiga Plus 2000 #1 / Amiga Plus CD - 2000 - No. 1.iso / Tools / HD / SmartFileSystem / V1.58 / Sources / fs / bitmap.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-06-23  |  919 b   |  34 lines

  1. #include <exec/types.h>
  2. #include <libraries/iffparse.h>
  3. #include "blockstructure.h"
  4.  
  5. #define SPACELIST_MAX (1000)
  6.  
  7. /* Used by smartfindandmarkspace() */
  8.  
  9. struct Space {
  10.   BLCK block;
  11.   ULONG blocks;
  12. };
  13.  
  14.  
  15.  
  16. /* The fsBitmap structure is used for Bitmap blocks.  Every partition has
  17.    a bitmap, and the number of blocks the partition consists of determines
  18.    its size.  The position of the first Bitmap block is stored in the root
  19.    block.  If there are any more bitmap blocks then these are located in
  20.    order directly after the first bitmap block.  For every block on disk
  21.    there is a single bit in a bitmap block which tells you whether it is
  22.    in use or not. */
  23.  
  24. #define BITMAP_ID               MAKE_ID('B','T','M','P')
  25.  
  26. struct fsBitmap {
  27.   struct fsBlockHeader bheader;
  28.  
  29.   ULONG bitmap[0];
  30.  
  31.   /* Bits are 1 if the block is free, and 0 if full.
  32.      Bitmap must consist of an integral number of longwords. */
  33. };
  34.