CS350 COS
COS
Loading...
Searching...
No Matches
o2fs.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  ObjID
 
struct  SuperBlock
 
struct  BPtr
 
struct  BNode
 
struct  BDirEntry
 

Macros

#define MAXUSERNAMELEN   32
 
#define MAXNAMELEN   255
 
#define O2FS_VERSION_MAJOR   1
 
#define O2FS_VERSION_MINOR   0
 
#define SUPERBLOCK_MAGIC   "SUPRBLOK"
 
#define O2FS_DIRECT_PTR   (64)
 
#define BNODE_MAGIC   "BLOKNODE"
 
#define BDIR_MAGIC   "DIRENTRY"
 

Typedefs

typedef struct ObjID ObjID
 
typedef struct SuperBlock SuperBlock
 
typedef struct BPtr BPtr
 
typedef struct BNode BNode
 
typedef struct BDirEntry BDirEntry
 

Data Structure Documentation

◆ ObjID

struct ObjID

Definition at line 36 of file o2fs.h.

Collaboration diagram for ObjID:
[legend]
Data Fields
uint64_t device
uint8_t hash[32]
uint64_t offset

◆ SuperBlock

struct SuperBlock

Definition at line 45 of file o2fs.h.

Collaboration diagram for SuperBlock:
[legend]
Data Fields
uint32_t _rsvd0
uint64_t bitmapOffset
uint64_t bitmapSize
uint64_t blockCount
uint64_t blockSize
uint64_t features
uint8_t hash[32]
uint8_t magic[8]
ObjID root
uint64_t version
uint16_t versionMajor
uint16_t versionMinor

◆ BPtr

struct BPtr

Definition at line 68 of file o2fs.h.

Collaboration diagram for BPtr:
[legend]
Data Fields
uint64_t _rsvd0
uint64_t _rsvd1
uint64_t device
uint8_t hash[32]
uint64_t offset

◆ BNode

struct BNode

Definition at line 82 of file o2fs.h.

Collaboration diagram for BNode:
[legend]
Data Fields
BPtr direct[O2FS_DIRECT_PTR]
uint32_t flags
uint8_t magic[8]
uint64_t size
uint16_t versionMajor
uint16_t versionMinor

◆ BDirEntry

struct BDirEntry

Definition at line 98 of file o2fs.h.

Collaboration diagram for BDirEntry:
[legend]
Data Fields
uint64_t ctime
uint64_t flags
uint8_t group[MAXUSERNAMELEN]
uint8_t magic[8]
uint64_t mtime
uint8_t name[MAXNAMELEN+1]
ObjID objId
uint8_t padding[104]
uint64_t size
uint8_t user[MAXUSERNAMELEN]

Macro Definition Documentation

◆ BDIR_MAGIC

#define BDIR_MAGIC   "DIRENTRY"

Definition at line 112 of file o2fs.h.

◆ BNODE_MAGIC

#define BNODE_MAGIC   "BLOKNODE"

Definition at line 93 of file o2fs.h.

◆ MAXNAMELEN

#define MAXNAMELEN   255

Definition at line 23 of file o2fs.h.

◆ MAXUSERNAMELEN

#define MAXUSERNAMELEN   32

Definition at line 22 of file o2fs.h.

◆ O2FS_DIRECT_PTR

#define O2FS_DIRECT_PTR   (64)

Definition at line 77 of file o2fs.h.

◆ O2FS_VERSION_MAJOR

#define O2FS_VERSION_MAJOR   1

Definition at line 30 of file o2fs.h.

◆ O2FS_VERSION_MINOR

#define O2FS_VERSION_MINOR   0

Definition at line 31 of file o2fs.h.

◆ SUPERBLOCK_MAGIC

#define SUPERBLOCK_MAGIC   "SUPRBLOK"

Definition at line 63 of file o2fs.h.

Typedef Documentation

◆ BDirEntry

typedef struct BDirEntry BDirEntry

◆ BNode

typedef struct BNode BNode

◆ BPtr

typedef struct BPtr BPtr

◆ ObjID

typedef struct ObjID ObjID

◆ SuperBlock

typedef struct SuperBlock SuperBlock