Explorar o código

mmc: fix ERASE_GRP_DEF handling

if we set manually this bit on the eMMC card using mmc_switch(...),
we also have to set it within our (before read) internal structure
'ext_csd'.

Otherwise following checks on this will fail.

Acked-by: Pantelis Antoniou <panto@antoniou-consulting.com>
Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at>
Hannes Petermaier %!s(int64=10) %!d(string=hai) anos
pai
achega
021a80559f
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      drivers/mmc/mmc.c

+ 2 - 0
drivers/mmc/mmc.c

@@ -1010,6 +1010,8 @@ static int mmc_startup(struct mmc *mmc)
 
 			if (err)
 				return err;
+			else
+				ext_csd[EXT_CSD_ERASE_GROUP_DEF] = 1;
 
 			/* Read out group size from ext_csd */
 			mmc->erase_grp_size =