| Summary: | mkfs.jffs2 uses the --pagesize parameter incorrectly | ||
|---|---|---|---|
| Product: | buildroot | Reporter: | Michał Leśniewski <mlesniew> |
| Component: | Other | Assignee: | unassigned |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | buildroot |
| Priority: | P5 | ||
| Version: | 2015.02 | ||
| Target Milestone: | --- | ||
| Hardware: | All | ||
| OS: | All | ||
| Host: | Target: | ||
| Build: | |||
|
Description
Michał Leśniewski
2015-05-15 06:24:50 UTC
Wow, thanks for this bug report! It seems you are absolutely correct, and I actually learned with your bug report that the --pagesize option is for the virtual memory page size, not the NAND page size. Do you think you can cook a patch to address this problem? One issue is that Buildroot has no idea what is the virtual memory page size on the target system. I would suggest to just not pass any --pagesize option, and leave the default of 4 KB, since this is what the vast majority of systems are using. And I'm pretty sure that if you use --pagesize 4K on a system that uses 8 KB or 64 KB pages, it will continue to work fine. I read a bit about the JFFS2 file system and looked at the JFFS2 code in the Linux kernel. It looks like setting the --pagesize parameter value to the exact size of the virtual memory page would give the best results (best compression ratio). However, setting a smaller --pagesize value should work fine, just as you wrote before. Anyway, I prepared a patch and sent it to the mailing list (http://lists.busybox.net/pipermail/buildroot/2015-May/128576.html). Committed as e3904a890de2a74c290675fdb90324a6ed83e633, thanks! |