Skip to content

Commit ad786ad

Browse files
authored
nand: fix TLC/QLC latency tables (#97)
1 parent 262f3ba commit ad786ad

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

hw/femu/nand/nand.c

+3-3
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,10 @@ static void init_tlc_page_pairing(FemuCtrl *n)
5555
/* QLC-NAND Flash Mapping with Shadow-Page programming Sequence */
5656
static void init_qlc_page_pairing(FemuCtrl *n)
5757
{
58-
int i, j;
58+
int i, j;
5959
int rows = (MAX_SUPPORTED_PAGES_PER_BLOCK + 7) / 8;
6060
int lpflag = QLC_LOWER_PAGE;
61-
int page_per_row=8;
61+
int page_per_row=8;
6262

6363
int lowp[] = {0, 1, 2, 3, 4, 5, 8, 9};
6464
int centerlp[] = {6, 7, 10, 11};
@@ -76,7 +76,7 @@ static void init_qlc_page_pairing(FemuCtrl *n)
7676
for (i = 0; i < rows - 3; i++) {
7777
for (j = 0; j < page_per_row; j += 2) {
7878
int idx = 8 + (i * page_per_row) + j;
79-
tlc_tbl[idx] = tlc_tbl[idx+1] = lpflag;
79+
qlc_tbl[idx] = qlc_tbl[idx+1] = lpflag;
8080
lpflag = (lpflag == QLC_UPPER_PAGE) ? QLC_LOWER_PAGE : lpflag + 1;
8181
}
8282
}

0 commit comments

Comments
 (0)