0
votes

I'm flashing a filesystem to nand from u-boot. I have the compressed filesystem stored in an mmc. Normally I'd do something like this:

ext4load mmc mmcdev:mmcpart address path
...
ubi write address name size

The problem I have is that ext4load loads the ubifs into ram, and the fs exceeds the amount of ram that is available.

Is there a way to write the fs directly from mmc to nand? Something like this:

ubi write mmcdev:mmcpart name size
1

1 Answers

0
votes

Given that writing to nand from u-boot is limited by the device's ram, I ended up writing the ubifs from user space.

Basically,

  • Pass mtdparts to kernel as boot argument
  • flash_erase mtd partition
  • ubiattach partition
  • create volume with ubimkvol
  • write ubifs with ubiupdatevol
  • ubidetach partition

Here are some useful links: