Classes | Defines | Enumerations | Functions | Variables

include/nand.h File Reference

#include "types.h"
Include dependency graph for nand.h:

Go to the source code of this file.

Classes

struct  config_nand

Defines

#define LPA_MASK_SECT   (-config_nand.sect_per_page)
#define LPA_F_SECT(sect)   (((sect) & LPA_MASK_SECT) >> (config_nand.bit_sect_per_page))
#define LSN_F_LPA(lpa)   ((lpa)*config_nand.sect_per_page)

Enumerations

enum  config {
  SECT_PER_PAGE = 8, PAGE_PER_BLK = 128, TOTALSIZE_GB = 32, EXTRABLKS = 1967,
  SECT_PER_PAGE = 8, PAGE_PER_BLK = 128, TOTALSIZE_GB = 32, EXTRABLKS = 1967
}
enum  { NAND_REQ_DATA = 0, NAND_REQ_GC, NAND_REQ_WARM }

Functions

int nand_open ()
void nand_close ()
_t_sect nand_page_read (unsigned int blk_no, unsigned int page_no, unsigned int lsn, int optStat)
void nand_page_write (unsigned int blk_no, unsigned int page_no, unsigned int lsn, int optStat)
void nand_block_erase (unsigned int blk_no, int optStat)

Variables

struct config_nand config_nand

Define Documentation

#define LPA_F_SECT (   sect  )     (((sect) & LPA_MASK_SECT) >> (config_nand.bit_sect_per_page))

Definition at line 28 of file nand.h.

#define LPA_MASK_SECT   (-config_nand.sect_per_page)

Definition at line 27 of file nand.h.

#define LSN_F_LPA (   lpa  )     ((lpa)*config_nand.sect_per_page)

Definition at line 29 of file nand.h.


Enumeration Type Documentation

anonymous enum
Enumerator:
NAND_REQ_DATA 
NAND_REQ_GC 
NAND_REQ_WARM 

Definition at line 32 of file nand.h.

enum config
Enumerator:
SECT_PER_PAGE 
PAGE_PER_BLK 
TOTALSIZE_GB 
EXTRABLKS 
SECT_PER_PAGE 
PAGE_PER_BLK 
TOTALSIZE_GB 
EXTRABLKS 

Definition at line 6 of file nand.h.


Function Documentation

void nand_block_erase ( unsigned int  blk_no,
int  optStat 
)

Definition at line 170 of file nand.c.

Here is the caller graph for this function:

void nand_close (  ) 

Definition at line 82 of file nand.c.

Here is the caller graph for this function:

int nand_open (  ) 

Definition at line 37 of file nand.c.

Here is the caller graph for this function:

_t_sect nand_page_read ( unsigned int  blk_no,
unsigned int  page_no,
unsigned int  lsn,
int  optStat 
)

Definition at line 102 of file nand.c.

Here is the caller graph for this function:

void nand_page_write ( unsigned int  blk_no,
unsigned int  page_no,
unsigned int  lsn,
int  optStat 
)

Definition at line 135 of file nand.c.

Here is the caller graph for this function:


Variable Documentation

Definition at line 14 of file nand.c.

 All Classes Files Functions Variables Typedefs Enumerations Enumerator Defines