imx6q-sabresd program android5.1 system.img fail with mfgtool(2.3.3 & 2.6.2)

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

imx6q-sabresd program android5.1 system.img fail with mfgtool(2.3.3 & 2.6.2)

2,093 Views
houyong
Contributor III

Hi,

First, the mfg tool works well while the size of system.img less than 320MB.

But i want to put some prebuilt apk into system, the sparse system.img size grow to 327MB.

I have configured the BOARD_SYSTEMIMAGE_PARTITION_SIZE envrionment var in device/fsl/imx6/BoardConfigCommon.mk as 460MB、512MB and so on.I also even changed the

mksdcard-android.sh to change system partition size to 600MB、800MB、1GB and so on,the error always comes.

I think it is a bug of simg2img tool through the uart log.mfg-error.png

I attach the picture, please analysis this problem.Thanks!

Labels (1)
0 Kudos
9 Replies

1,439 Views
houyong
Contributor III

Top of this discussion!

0 Kudos

1,439 Views
houyong
Contributor III

anyone? you may try to reproduce this with sparse system image.

0 Kudos

1,439 Views
houyong
Contributor III

anyone who care?

0 Kudos

1,439 Views
BiyongSUN
NXP Employee
NXP Employee

It should be the memory size issue on your board. It could not hold the system.img convert  to ram on the board.

Try to convert the system image on your host. And burn the ram image. 

0 Kudos

1,439 Views
houyong
Contributor III

Hi Biyong Sun,

I want to know about the difference between "pipe dd" and "dd", thank you!

0 Kudos

1,439 Views
BiyongSUN
NXP Employee
NXP Employee

The if pipe is not used, the whole file need to send to the memory, which is ramdisk.

That will consumer the lots of memory. Could be the problem for hardware design with small memory volume.

The pipe is as named, it will use the pipe. The entire file don't need to be sent.

The pipe command is filed in the mfg tool document.

Have you read that before you are alway asking here?

In the document, it uses the blod words. Do you notice that?

Document\V2\Manufacturing Tool V2 UCL User Guide.docx

pipe

string require file attribute

Execute shell command and read data from stdio pipe IN. mfg will send file to stdio pipe OUT. It is useful for big data transfer, more than physical memory size  <CMD type="push" body="pipe tar -xv -C /mnt/ubi0" file="files/rootfs.tar"/> <CMD type="push" body="flush">Finish Flashing NAND</CMD>

Note: The above two commands must be combined to use

Recommend: Please add below command prior to pipe command to free some memory.

<CMD type="push" body="$ echo 3 > /proc/sys/vm/drop_caches">release memory</CMD>

1,439 Views
houyong
Contributor III

I modified the ucl2.xml like this:

body="pipe dd of=/dev/mmcblk%mmc%p5 bs=512" file="../../../neo/system.img"

and it boot success now.

But is there any difference between the two commands?

1,439 Views
3401848300
Contributor III

another example from IMX6_L5.1_2.1.0_MFG_TOOL:

<CMD state="Updater" type="push" body="pipe dd of=/dev/mmcblk%mmc%p5 bs=512" file="files/android/%folder%/system_raw.img">writting sparse system.img</CMD>

0 Kudos

1,439 Views
houyong
Contributor III

I have tried it, but after download done.

During bootup, init process can not mount the system partition.Maybe the dd command has broken the

ext4 super block(<CMD state="Updater" type="push" body="$ dd if=$FILE of=/dev/mmcblk%mmc%p5 bs=512">writting sparse system.img</CMD>).but i think the non sparse system.img is a formated image, i even can

mount the system.img on host.

Here is the android5.1 boot error log:

JBD2: no valid journal superblock found
EXT4-fs (mmcblk3p5): error loading journal
fs_mgr: __mount(source=/dev/block/mmcblk3p5,target=/system,type=ext4)=-1
fs_mgr: Failed to mount an un-encryptable or wiped partition on/dev/block/mmcblk3p5 at /system options: barrier=1 error: Invalid argument.

Do you kown why?

0 Kudos