Success! Subscription added.
Success! Subscription removed.
Sorry, you must verify to complete this action. Please click the verification link in your email. You may re-send via your profile.
UBIFS works with NOR and NAND flash. Please refer to the doc on the MTD community to enable UBI driver support and UBIFS filesystem support in kernel config.
http://www.linux-mtd.infradead.org/faq/ubifs.html
In the Linux configuration menu, go to "Device Drivers" -> "Memory Technology Devices (MTD)" -> "UBI - Unsorted block images", and mark the "Enable UBI" check-box.
Then in the Linux configuration menu, go to "File systems" ->
"Miscellaneous filesystems", and mark the
"UBIFS file system support" check-box.
Next in the User apps configuration menu, go to "Flash Tools" ---> [*] "mtd-utils" --> [*] " ubifs utilities" .
You will need to add the ubi devices nodes to romfs_list (NOMMU) or device_table.txt (MMU) or use mdev.
crw-rw---- 1 root root 253, 0 Mar 1 11:09 ubi0
crw-rw---- 1 root root 10, 63 Mar 1 11:09 ubi_ctrl
Below is the boot message of UBIFS on a 512MB NAND flash using the nand flash interface described in the nioswiki MTD page.
Kernel command line: ubi.mtd=0
ttyJ0 at MMIO 0x9003250 (irq = 1) is a Altera JTAG UART
console [ttyJ0] enabled, bootconsole disabled
console [ttyJ0] enabled, bootconsole disabled
NAND device: Manufacturer ID: 0xec, Chip ID: 0xdc (Samsung NAND 512MiB 3,3V 8-bit)
Scanning device for bad blocks
Bad eraseblock 711 at 0x00000b1c0000
UBI: attaching mtd0 to ubi0
UBI: physical eraseblock size: 262144 bytes (256 KiB)
UBI: logical eraseblock size: 258048 bytes
UBI: smallest flash I/O unit: 2048
UBI: VID header offset: 2048 (aligned 2048)
UBI: data offset: 4096
UBI: attached mtd0 to ubi0
UBI: MTD device name: "gen_nand"
UBI: MTD device size: 512 MiB
UBI: number of good PEBs: 2047
UBI: number of bad PEBs: 1
UBI: max. allowed volumes: 128
UBI: wear-leveling threshold: 4096
UBI: number of internal volumes: 1
UBI: number of user volumes: 0
UBI: available PEBs: 2023
UBI: total number of reserved PEBs: 24
UBI: number of PEBs reserved for bad PEB handling: 20
UBI: max/mean erase counter: 1/1
UBI: image sequence number: 0
UBI: background thread "ubi_bgt0d" started, PID 567
root:/> ubimkvol /dev/ubi0 -m -N data
Set volume size to 522031104
Volume ID 0, size 2023 LEBs (522031104 bytes, 497.8 MiB), LEB size 258048 bytes (252.0 KiB), dynamic, name "data", alignment 1
root:/> mkdir /mnt/data
root:/> mount -t ubifs ubi0_0 /mnt/data
UBIFS: default file-system created
UBIFS: mounted UBI device 0, volume 0, name "data"
UBIFS: file system size: 519450624 bytes (507276 KiB, 495 MiB, 2013 LEBs)
UBIFS: journal size: 26062848 bytes (25452 KiB, 24 MiB, 101 LEBs)
UBIFS: media format: w4/r0 (latest is w4/r0)
UBIFS: default compressor: lzo
UBIFS: reserved for root: 4952683 bytes (4836 KiB)
root:/> df
Filesystem 1K-blocks Used Available Use% Mounted on
ubi0_0 475696 20 470840 0% /mnt/data
root:/> umount /mnt/data
UBIFS: un-mount UBI device 0, volume 0
Community support is provided Monday to Friday. Other contact methods are available here.
Intel does not verify all solutions, including but not limited to any file transfers that may appear in this community. Accordingly, Intel disclaims all express and implied warranties, including without limitation, the implied warranties of merchantability, fitness for a particular purpose, and non-infringement, as well as any warranty arising from course of performance, course of dealing, or usage in trade.
For more complete information about compiler optimizations, see our Optimization Notice.