#include <stdlib.h>
#include <string.h>
#include "debug.h"
#include "nand.h"
#include "vmbitmap.h"
#include "map.h"
#include "ftl.h"
#include "stat.h"
Go to the source code of this file.
Classes | |
struct | vbm_entry |
struct | _t_vm |
Defines | |
#define | MIN_FREE_BLKS 10 |
#define | GC_BLKS 5 |
Enumerations | |
enum | { BLOCK_FREE = 0, BLOCK_DATA, BLOCK_INDEX, BLOCK_GC } |
Functions | |
_t_blk | vm_alloc_block (int reqtype) |
_u32 | vm_alloc_page (_t_sect lsn, _t_blk *pbn, _t_page *ppn, int reqtype) |
_t_blk | vm_get_victim () |
int | bitmap_sum (_u8 *bitmap) |
void | vm_gc_run (_t_blk victim) |
void | vm_clear_block (_t_blk victim, int type) |
void | vm_invalidate (_t_blk victim, _t_page ppn, _t_size length) |
int | vm_gc_check () |
void | vm_gc_start () |
void | vm_end () |
void | vm_init () |
Variables | |
int | indexpages |
static struct _t_vm | vm |
anonymous enum |
int bitmap_sum | ( | _u8 * | bitmap | ) |
_t_blk vm_alloc_block | ( | int | reqtype | ) |
void vm_clear_block | ( | _t_blk | victim, | |
int | type | |||
) |
void vm_end | ( | ) |
int vm_gc_check | ( | ) |
void vm_gc_run | ( | _t_blk | victim | ) |
void vm_gc_start | ( | ) |
_t_blk vm_get_victim | ( | ) |
void vm_init | ( | ) |
int indexpages |