From patchwork Mon Jun 29 09:47:23 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pragnesh Patel X-Patchwork-Id: 243070 List-Id: U-Boot discussion From: pragnesh.patel at sifive.com (Pragnesh Patel) Date: Mon, 29 Jun 2020 15:17:23 +0530 Subject: [PATCH 0/6] mmc_spi: mmc erase resolve Message-ID: <20200629094730.10051-1-pragnesh.patel@sifive.com> Earlier "mmc erase " command reorts Ok but not actually erase the contents of some SD cards. This series will resolve this issue. There is still 1 limitation for some SDHC mmc_spi cards: "mmc erase *blk#* cnt" can not erase only 1 block that means: => mmc erase 0x22 1 will not erase the contents of SD card. User has to erase multiple blocks at a time that means: => mmc erase 0x22 2 will erase the contents of SD card. This limitation is from micro SD card side, i found this limitation in Strontium micro SDHC - 4 GB (class 6). Pragnesh Patel (6): mmc: mmc_spi: correct the while condition mmc: mmc_spi: generate R1 response for different mmc SPI commands mmc: read ssr for SD spi mmc: mmc_spi: Read R2 response for send status command - CMD13 mmc: mmc_spi: Generate R1 response for erase block start and end address mmc_spi: generate R1b response for erase and stop transmission command drivers/mmc/mmc.c | 5 +++++ drivers/mmc/mmc_spi.c | 52 ++++++++++++++++++++++++++++++++++++------- 2 files changed, 49 insertions(+), 8 deletions(-)