This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

UBI format in NOR flash

I am using J6 hardware with 3.14 kernel and QSPI interface for NOR flash.

I have created 2 mtd partition in NOR flash with 2nd partition of size 31MB

I am getting CRC error in NOR flash when i do ubiattach.

# ubiformat /dev/mtd1

ubiformat: mtd1 (nor), size 33161216 bytes (31.6[ 67.967698] omap_hwmod: qspi: enabling

MiB), 506 eraseblocks of 65536 bytes (64.0 KiB), min. I/O size 1 bytes
libscan: scanning eraseblock[ 68.043041] random: nonblocking pool is initialized
libscan: scanning eraseblock 505 -- 100 % complete
ubiformat: 506 eraseblocks have valid erase counter, mean value is 4
ubiformat: formatting eraseblock 505 -- 100 % complete

#ubiattach -m 1
[ 173.276460] UBI: attaching mtd1 to ubi0
[ 173.280548] omap_hwmod: qspi: enabling
[ 173.284483] omap_hwmod: qspi: enabling clocks
[ 173.289042] omap_hwmod: qspi: _omap4_enable_module: 2
[ 173.938295] UBI: scanning is finished
[ 174.289707] UBI error: vtbl_check: bad CRC at record 23: 0xe3474cc5, not 0xffffffff
[ 174.297916] Volume table record 23 dump:
[ 174.302018] reserved_pebs 0
[ 174.305362] alignment 0
[ 174.308560] data_pad 0
[ 174.311752] vol_type 0
[ 174.315120] upd_marker 0
[ 174.318315] name_len 0
[ 174.321508] name NULL
[ 174.325164] UBI error: vtbl_check: bad CRC at record 23: 0xe3474cc5, not 0xffffffff
[ 174.333280] Volume table record 23 dump:
[ 174.337385] reserved_pebs 0
[ 174.340571] alignment 0
[ 174.343921] data_pad 0
[ 174.347111] vol_type 0
[ 174.350306] upd_marker 0
[ 174.353655] name_len 0
[ 174.356849] name NULL
[ 174.360314] UBI error: process_lvol: both volume tables are corrupted
[ 174.367368] UBI error: ubi_attach_mtd_dev: failed to attach mtd1, error -22
ubiattach: error!: cannot attach mtd1

Any clues on why its happening