Reboot to emmc/nand [Solved]Failed due to no env partition

Hello,

I just installed coreelec to a mecool m8s pro plus (S905x) and copied gxl_p212_2g.dtb to dtb.img.
I tried to reboot android from internal by selecting boot from emmc/nand but the box rebooted to coreelec.

after manually trying to launch rebootfromnand im getting this error:

CoreELEC:~ # /usr/sbin/rebootfromnand 
Cannot parse config file '/etc/fw_env.config': Invalid argument
Error: environment not initialized

CoreELEC:~ # fw_printenv 
Cannot parse config file '/etc/fw_env.config': Invalid argument

CoreELEC:~ # cat /etc/fw_env.config 
# Configuration file for fw_(printenv/setenv) utility.
# Up to two entries are valid, in this case the redundant
# environment sector is assumed present.
# Notice, that the "Number of sectors" is not required on NOR and SPI-dataflash.
# Futhermore, if the Flash sector size is ommitted, this value is assumed to
# be the same as the Environment size, which is valid for NOR and SPI-dataflash

# NOR example
# MTD device name       Device offset   Env. size       Flash sector size       Number of sectors
#/dev/mtd1              0x0000          0x4000          0x4000
#/dev/mtd2              0x0000          0x4000          0x4000

# MTD SPI-dataflash example
# MTD device name       Device offset   Env. size       Flash sector size       Number of sectors
#/dev/mtd5              0x4200          0x4200
#/dev/mtd6              0x4200          0x4200

# NAND example
#/dev/mtd0              0x4000          0x4000          0x20000                 2

# Block device example
#/dev/mmcblk0           0xc0000         0x20000

# VFAT example
#/boot/uboot.env        0x0000          0x4000

# Amlogic NAND
/dev/nand_env           0x000000        0x10000         0x10000

# Amlogic eMMC
/dev/env                0x000000        0x10000         0x10000


CoreELEC:~ # ls /dev/nand_env
ls: /dev/nand_env: No such file or directory

CoreELEC:~ # ls /dev/env
ls: /dev/env: No such file or directory

CoreELEC:~ # ls /flash/ -lah
total 160224
drwxr-xr-x    3 root     root       16.0K Jan  1  1970 .
drwxrwxr-x   12 root     root         202 Sep 15 03:19 ..
-rwxr-xr-x    1 root     root      146.7M Sep 15 04:20 SYSTEM
-rwxr-xr-x    1 root     root          48 Sep 15 04:20 SYSTEM.md5
-rwxr-xr-x    1 root     root         795 Sep 15 04:20 aml_autoscript
drwxr-xr-x    2 root     root        8.0K Sep 15 04:20 device_trees
-rwxr-xr-x    1 root     root       39.8K Sep 28 18:07 dtb.img
-rwxr-xr-x    1 root     root        9.6M Sep 15 04:20 kernel.img
-rwxr-xr-x    1 root     root          48 Sep 15 04:20 kernel.img.md5

CoreELEC:~ # cat /etc/release 
S905.arm-8.95.2

Finally got time to get back to this.
Turns out the tv box labeld as mecool m8s pro + has a s905w chip…

Hello, I have the same problem on mxq pro 4k s905x/1gb (android 6). Used dtb gxl_p212_1g.
Box rebooting to coreelec all the time.
Also got this error:

Cannot parse config file ‘/etc/fw_env.config’: Invalid argument
Error: environment not initialized

CPU-Z and AIDA64 on android show that this box is gxl p212 so what’s the problem?
To be sure, I checked other dtbs like: p200, p201 - box freezes on AMLogic logo.
Only p212_1gb works.

Same problem on Tanix TX3 Mini - H 2/16. Tried gxl_p212_2g, gxl_p281_2g and few more… It boots and works normally but I cant reboot back to Android, it reboots back to CoreElec every time. Pulling out sd card is the only way to use Android. Any fix?

It won’t work on devices that have no env partition, theres no workaround for this.

1 Like