Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

Superblock Class Reference

A Superblock records the completion of a checkpoint. More...

#include <storage.h>

List of all members.

Public Member Functions

void print ()

Public Attributes

unsigned signature
unsigned checkpoint_counter
unsigned block_directory
unsigned segment_directory
Size blocks_per_segment
unsigned curr_empty_segment

Static Public Attributes

const unsigned CORRECT_SIGNATURE = 0xbb66


Detailed Description

A Superblock records the completion of a checkpoint.

The Torsion storage system has two superblocks at fixed locations on the disk. Every time a checkpoint is completed, various storage meta-data are written to one of the superblocks so that the storage system's state can be easily recovered on boot. There are two superblocks so that at least one superblock is always in a consistent state.


Member Function Documentation

void Superblock::print  ) 
 

Print basic information about this Superblock.


Member Data Documentation

unsigned Superblock::block_directory
 

first block of block directory

Size Superblock::blocks_per_segment
 

number of blocks per disk segment

unsigned Superblock::checkpoint_counter
 

ID number of recent checkpoint.

const unsigned Superblock::CORRECT_SIGNATURE = 0xbb66 [static]
 

unsigned Superblock::curr_empty_segment
 

first block of current empty segment

unsigned Superblock::segment_directory
 

first block of segment directory

unsigned Superblock::signature
 

magic num for a Torsion superblock


The documentation for this class was generated from the following files:

Torsion Operating System, Copyright (C) 2000-2004 Dan Helfman