Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5fb20a83 authored by Sahitya Tummala's avatar Sahitya Tummala
Browse files

mtd: msm_qpic_nand: Fix flash density calculation



Account for the number of logical units (from the
ONFI parameter page) in the flash density calculation
for ONFI complaint devices.

Change-Id: I0dcb35faaaef88a75b46fa12c9443dc9faa0b0fd
Signed-off-by: default avatarSahitya Tummala <stummala@codeaurora.org>
parent c97f5cfd
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -855,6 +855,7 @@ static int msm_nand_flash_onfi_probe(struct msm_nand_info *info)
					flash->pagesize;
	flash->oobsize  = onfi_param_page_ptr->number_of_spare_bytes_per_page;
	flash->density  = onfi_param_page_ptr->number_of_blocks_per_logical_unit
				* onfi_param_page_ptr->number_of_logical_units
					* flash->blksize;
	flash->ecc_correctability = onfi_param_page_ptr->
					number_of_bits_ecc_correctability;