[U-Boot] ext4write issue.

S Durga Prasad Paladugu durgaprasad.psdp at gmail.com
Mon May 25 09:01:50 CEST 2015


Hi all,

I am having an ext4write issue on zynq, which fails when i am trying to
write a file to ext4 formatted SD card. here is the log below.

zynq-uboot> ext4ls mmc 0:2
<DIR>       1024 .
<DIR>       1024 ..
<DIR>       1024 lost+found
zynq-uboot>
zynq-uboot>
zynq-uboot> ext4write mmc 0:2 0x40000000 /bar.txt 10
File System is consistent
sdhci_send_command: MMC: 0 busy timeout increasing to: 200 ms.
sdhci_send_command: MMC: 0 busy timeout increasing to: 400 ms.
sdhci_send_command: MMC: 0 busy timeout increasing to: 800 ms.
sdhci_send_command: MMC: 0 busy timeout increasing to: 1600 ms.
sdhci_send_command: MMC: 0 busy timeout increasing to: 3200 ms.
sdhci_send_command: MMC: 0 busy timeout.
sdhci_send_command: MMC: 0 busy timeout.
sdhci_send_command: MMC: 0 busy timeout.
sdhci_send_command: MMC: 0 busy timeout.
sdhci_send_command: MMC: 0 busy timeout.
sdhci_send_command: MMC: 0 busy timeout.
sdhci_send_command: MMC: 0 busy timeout.
 ** ext4fs_devread read error - block
sdhci_send_command: MMC: 0 busy timeout.
sdhci_send_command: MMC: 0 busy timeout.
 ** ext4fs_devread read error - block
Error in getting the block group descriptor table
sdhci_send_command: MMC: 0 busy timeout.
sdhci_send_command: MMC: 0 busy timeout.
 ** ext2fs_devread() read error **
sdhci_send_command: MMC: 0 busy timeout.
 ** ext4fs_devread read error - block
sdhci_send_command: MMC: 0 busy timeout.
sdhci_send_command: MMC: 0 busy timeout.
 ** ext4fs_devread read error - block
sdhci_send_command: MMC: 0 busy timeout.
error in File System init
** Error ext4fs_write() **
zynq-uboot>
sdhci_send_command: MMC: 0 busy timeout.
** Can't read partition table on 0:0 **
** Invalid partition 2 **
zynq-uboot>  ext4ls mmc 0:2
sdhci_send_command: MMC: 0 busy timeout.
** Can't read partition table on 0:0 **
** Invalid partition 2 **
zynq-uboot>

I further debugged and found that the same is working with single block
write commands instead of multi block write commands. Here is the diff of
the changes i made to make it single block write.

 drivers/mmc/mmc_write.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/mmc/mmc_write.c b/drivers/mmc/mmc_write.c
index aa2fdef..269d233 100644
--- a/drivers/mmc/mmc_write.c
+++ b/drivers/mmc/mmc_write.c
@@ -167,7 +167,7 @@ ulong mmc_bwrite(int dev_num, lbaint_t start, lbaint_t
blkcnt, const void *src)
  return 0;

  do {
- cur = (blocks_todo > mmc->b_max) ?  mmc->b_max : blocks_todo;
+ cur = 1;
  if (mmc_write_blocks(mmc, start, cur, src) != cur)
  return 0;
  blocks_todo -= cur;
-- 

Does any one faced same kind of issue? Can any one of you have an idea on
what could be the issue in this case or any further inputs on this will be
helpful.

Regards,
DP


More information about the U-Boot mailing list