12.1 EDK - Mfsgen errors generating large image files
Running mfsgen on larger images might result in errors if not enough blocks are specified via the -b switch:
In 12.2: < input file name > ERROR:EDK:3823 - error writing mfs file
In 12.1 and 11.x tools: < input file name > ERROR:EDK:3170 - error writing mfs file
If the -b switch is not specified, the default of 5000 blocks are used. The block size is 532.
Also, if you increase the number or size of files for the image, the old setting might not be enough. For example, XAPP1026 directs you to run this command: mfsgen -cvbfs ../image.mfs 1500 *
However, the input files may change with the updated examples such that 1500 is no longer enough blocks.
If the total size of your input files is larger than 5000 532 blocks or has increased beyond what the -b option previously specified, you will need to increase the -b to match or surpass the total size needed.
An easy way to determine the size needed is to run the du command. (Windows users can run this from an EDK Shell): du --total --block-size=512 < input files >
(Use a slightly smaller block size such as 512 to compensate for MFS overhead.)
For example: du --total --block-size=532 *
$ du -all --total --block-size=512 * 8 css/main.css 8 css/ 8 index.html 16 total
$ mfsgen -cvbfs image.mfs 16 * mfsgen Xilinx EDK 12.2 EDK_MS2.63c Copyright (c) 2004 Xilinx, Inc. All rights reserved.
Then if you want to minimal size it can be found by the usage line. To continue the example: $ mfsgen -cvbfs image.mfs 10 * mfsgen Xilinx EDK 12.2 EDK_MS2.63c Copyright (c) 2004 Xilinx, Inc. All rights reserved.