AnsweredAssumed Answered

ubifs in slc nand in imx6

Question asked by kiruthika varadarajan on Jul 9, 2015
Latest reply on Jul 12, 2015 by kiruthika varadarajan

Hi All,

I have imx6 solo h/w with SLC nand of size 256 MB.I made ubifs filesystem and flashed it in SLC nand.

Now kernel should take filesystem from SLC nand.

I have configured the kernel for required settings and UBIFS is found but could not boot completely from that.. 

 

Logs:

 

nand: device found, Manufacturer ID: 0x2c, Chip ID: 0xaa

nand: Micron MT29F2G08ABBEAH4

nand: 256MiB, SLC, page size: 2048, OOB size: 64

gpmi-nand 112000.gpmi-nand: enable the asynchronous EDO mode 4

Scanning device for bad blocks

Bad eraseblock 100 at 0x000000c80000

Bad eraseblock 101 at 0x000000ca0000

1 ofpart partitions found on MTD device gpmi-nand

Creating 1 MTD partitions on "gpmi-nand":

0x000000020000-0x000000820000 : "root"

 

UBI: attaching mtd0 to ubi0

UBI: scanning is finished

UBI: attached mtd0 (name "gpmi-nand", size 256 MiB) to ubi0

UBI: PEB size: 131072 bytes (128 KiB), LEB size: 126976 bytes

UBI: min./max. I/O unit sizes: 2048/2048, sub-page size 2048

UBI: VID header offset: 2048 (aligned 2048), data offset: 4096

UBI: good PEBs: 2046, bad PEBs: 2, corrupted PEBs: 0

UBI: user volume: 1, internal volumes: 1, max. volumes count: 128

UBI: max/mean erase counter: 2/1, WL threshold: 4096, image sequence number: 1743731081

UBI: available PEBs: 0, total reserved PEBs: 2046, PEBs reserved for bad PEB handling: 38

UBI: background thread "ubi_bgt0d" started, PID 65

snvs_rtc 20cc034.snvs-rtc-lp: setting system clock to 1970-01-01 00:00:01 UTC (1)

ALSA device list:

  No soundcards found.

VFS: Cannot open root device "ubi0:root" or unknown-block(0,0): error -2

Please append a correct "root=" boot option; here are the available partitions:

b300         7684096 mmcblk0  driver: mmcblk

  b301             504 mmcblk0p1 1a000003-01

  b302             512 mmcblk0p2 1a000003-02

  b303           10240 mmcblk0p3 1a000003-03

  b304               1 mmcblk0p4

  b305            1016 mmcblk0p5 1a000003-05

  b306           24568 mmcblk0p6 1a000003-06

  b307         2058232 mmcblk0p7 1a000003-07

  b308         5588984 mmcblk0p8 1a000003-08

b330             128 mmcblk0rpmb  (driver?)

b320            2048 mmcblk0boot1  (driver?)

b310            2048 mmcblk0boot0  (driver?)

Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)

CPU: 0 PID: 1 Comm: swapper Not tainted 3.10.17 #975

[<80013b70>] (unwind_backtrace+0x0/0x104) from [<80011e60>] (show_stack+0x20/0x24)

[<80011e60>] (show_stack+0x20/0x24) from [<8051deb4>] (dump_stack+0x20/0x28)

[<8051deb4>] (dump_stack+0x20/0x28) from [<8051b978>] (panic+0x8c/0x1dc)

[<8051b978>] (panic+0x8c/0x1dc) from [<80754fb0>] (mount_block_root+0x214/0x2d4)

[<80754fb0>] (mount_block_root+0x214/0x2d4) from [<8075525c>] (prepare_namespace+0x94/0x1c0)

[<8075525c>] (prepare_namespace+0x94/0x1c0) from [<80754be8>] (kernel_init_freeable+0x174/0x1b8)

[<80754be8>] (kernel_init_freeable+0x174/0x1b8) from [<80519960>] (kernel_init+0x1

 

 

cat /proc/partition is not listing the mtdblock. Is this the problem??

 

root@imx6solosabreauto:~# cat /proc/partitions

major minor  #blocks  name

 

179        0    7684096 mmcblk0

179        1        504 mmcblk0p1

179        2        512 mmcblk0p2

179        3      10240 mmcblk0p3

179        4          1 mmcblk0p4

179        5       1016 mmcblk0p5

179        6      24568 mmcblk0p6

179        7    2058232 mmcblk0p7

179        8    5588984 mmcblk0p8

179       48        128 mmcblk0rpmb

179       32       2048 mmcblk0boot1

179       16       2048 mmcblk0boot0

 

 

cat /proc/mtd is listing the mtd device.

root@imx6solosabreauto:~# cat /proc/mtd

dev:    size   erasesize  name

mtd0: 00800000 00020000 "root"

root@imx6solosabreauto:~#

 

I created this partition in dtsi file under gpmi node.

 

       partition@4 {

                        label = "root";

                        reg = <0x00020000 0x00800000>;

                            };

                };

 

Let me know what i am missing for making the kernel to take UBIFS from SLC Nand.

Outcomes