Couldn't boot Android 9.0 on i.MX8MQ

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

Couldn't boot Android 9.0 on i.MX8MQ

1,973 Views
felix_ye
Contributor II

Dear NXP,

I am having a problem booting Android 9.0 on i.MX8MQ.

When booting with image I had built, the board was unable to enter in user space and rebooted one more time.

Also I have tried the prebuilt image (android_p9.0.0_2.0.0-ga_image_8mqevk) and have the same problem.

Here is the log after the Kernel has started:

[ 3.544884] Freeing unused kernel memory: 5504K
[ 3.572427] init: init first stage started!
[ 3.577211] init: Using Android DT directory /proc/device-tree/firmware/android/
[ 3.586651] init: [libfs_mgr]fs_mgr_read_fstab_default(): failed to find device default fstab
[ 3.635669] init: [libfs_mgr]Returning avb_handle with status: 0
[ 3.642987] init: [libfs_mgr]Loading verity table: '1 /dev/block/platform/30b40000.usdhc/by-name/vendor_a /dev/block/platform/30b40000.usdhc/by-name/vendor_a 4096 4096 64481 64481 sha1 ea5a2a2959162197376cb04ccbd3c2709f87a29c 641869823befddd6c49dac3487f5aaf7e16c7281 10 use_fec_from_device /dev/block/platform/30b40000.usdhc/by-name/vendor_a fec_roots 2 fec_blocks 64990 fec_start 64990 restart_on_corruption ignore_zero_blocks'
[ 3.704366] EXT4-fs (dm-1): mounted filesystem without journal. Opts: barrier=1,inode_readahead_blks=8
[ 3.713766] init: [libfs_mgr]__mount(source=/dev/block/dm-1,target=/vendor,type=ext4)=0: Success
[ 3.722733] init: Skipped setting INIT_AVB_VERSION (not in recovery mode)
[ 3.729753] init: Loading SELinux policy
[ 3.764020] SELinux: Class process2 not defined in policy.
[ 3.770065] SELinux: Class infiniband_pkey not defined in policy.
[ 3.776312] SELinux: Class infiniband_endport not defined in policy.
[ 3.782766] SELinux: the above unknown classes and permissions will be denied
[ 3.789932] SELinux: policy capability network_peer_controls=1
[ 3.795861] SELinux: policy capability open_perms=1
[ 3.800834] SELinux: policy capability extended_socket_class=1
[ 3.806761] SELinux: policy capability always_check_network=0
[ 3.812602] SELinux: policy capability cgroup_seclabel=0
[ 3.818008] SELinux: policy capability nnp_nosuid_transition=0
[ 3.919586] selinux: SELinux: Loaded policy from /vendor/etc/selinux/precompiled_sepolicy
[ 3.919586]
[ 3.919869] audit: type=1403 audit(9.999:2): policy loaded auid=4294967295 ses=4294967295
[ 3.937518] audit: type=1404 audit(10.007:3): enforcing=1 old_enforcing=0 auid=4294967295 ses=4294967295
[ 3.967683] selinux: SELinux: Loaded file_contexts
[ 3.967683]
[ 3.978283] init: init second stage started!
[ 4.002996] init: Using Android DT directory /proc/device-tree/firmware/android/
[ 4.014923] selinux: SELinux: Loaded file_contexts
[ 4.014923]
[ 4.021227] init: Running restorecon...
[ 4.032950] init: waitid failed: No child processes
[ 4.043081] init: Couldn't load property file '/odm/default.prop': open() failed: No such file or directory: No such file or directory
[ 4.058161] init: Created socket '/dev/socket/property_service', mode 666, user 0, group 0
[ 4.067146] init: Forked subcontext for 'u:r:vendor_init:s0' with pid 2347
[ 4.074717] init: Forked subcontext for 'u:r:vendor_init:s0' with pid 2348
[ 4.081821] init: Parsing file /init.rc...
[ 4.188281] audit: type=1400 audit(10.267:4): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 4.193746] ueventd: ueventd started!
[ 4.205182] audit: type=1400 audit(10.267:5): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 4.211838] selinux: SELinux: Loaded file_contexts
[ 4.211838]
[ 4.225737] audit: type=1400 audit(10.267:6): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 4.225742] audit: type=1400 audit(10.267:7): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 4.225750] audit: type=1400 audit(10.271:8): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 4.232253] ueventd: Parsing file /ueventd.rc...
[ 4.248914] audit: type=1400 audit(10.271:9): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 4.248925] audit: type=1400 audit(10.271:10): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 4.272159] ueventd: Parsing file /vendor/ueventd.rc...
[ 4.327346] ueventd: Parsing file /odm/ueventd.rc...
[ 4.332457] ueventd: Unable to read config file '/odm/ueventd.rc': open() failed: No such file or directory
[ 4.342428] ueventd: Parsing file /ueventd.freescale.rc...
[ 4.347956] ueventd: Unable to read config file '/ueventd.freescale.rc': open() failed: No such file or directory
[ 4.374911] ueventd: firmware: loading 'imx/sdma/sdma-imx7d.bin' for '/devices/platform/30bd0000.sdma/firmware/imx!sdma!sdma-imx7d.bin'
[ 4.390881] ueventd: loading /devices/platform/30bd0000.sdma/firmware/imx!sdma!sdma-imx7d.bin took 16ms
[ 4.404907] imx-sdma 30bd0000.sdma: loaded firmware 4.4
[ 4.414400] imx-sdma 302c0000.sdma: loaded firmware 4.4
[ 4.549314] Registered swp emulation handler
[ 4.559383] watchdogd: watchdogd started (interval 10, margin 20)!
[ 4.583505] EXT4-fs (mmcblk0p12): Ignoring removed nomblk_io_submit option
[ 4.626789] EXT4-fs (mmcblk0p12): recovery complete
[ 4.632801] EXT4-fs (mmcblk0p12): mounted filesystem with ordered data mode. Opts: errors=remount-ro,nomblk_io_submit
[ 4.638464] wlan: loading driver v4.5.23.1
[ 4.647909] hif_pci_probe:, con_mode= 0x0
[ 4.652044] PCI device id is 003e :003e
[ 4.655907] hif_pci 0000:01:00.0: BAR 0: assigned [mem 0x18000000-0x181fffff 64bit]
[ 4.663753] hif_pci 0000:01:00.0: enabling device (0000 -> 0002)
[ 4.670837]
[ 4.670837] hif_pci_configure : num_desired MSI set to 1
[ 4.880546] hif_pci_probe: ramdump base 0xffff80005fe00000 size 2095136
[ 4.904984] NUM_DEV=1 FWMODE=0x2 FWSUBMODE=0x0 FWBR_BUF 0
[ 5.555460] +HWT
[ 5.568169] -HWT
[ 5.571132] HTC Service:0x0300 ep:1 TX flow control disabled
[ 5.621528] HTT: full reorder offload enabled
[ 5.648796] Pkt log is disabled
[ 5.652065] target uses HTT version 3.50; host uses 3.28
[ 5.670540] Host SW:4.5.23.1, FW:2.0.1.1048, HW:QCA6174_REV3_2
[ 5.677458] ol_pktlog_init: pktlogmod_init successfull
[ 5.684346] wlan: driver loaded in 1052000
[ 6.142384] e2fsck: e2fsck 1.43.3 (04-Sep-2016)
[ 6.142384]
[ 6.148453] e2fsck: Pass 1: Checking inodes, blocks, and sizes
[ 6.148453]
[ 6.155850] e2fsck: Pass 2: Checking directory structure
[ 6.155850]
[ 6.162765] e2fsck: Pass 3: Checking directory connectivity
[ 6.162765]
[ 6.169830] e2fsck: Pass 4: Checking reference counts
[ 6.169830]
[ 6.176387] e2fsck: Pass 5: Checking group summary information
[ 6.176387]
[ 6.183726] e2fsck: /dev/block/by-name/userdata: 2331/581632 files (0.5% non-contiguous), 68278/2326528 blocks
[ 6.183726]
[ 6.202252] EXT4-fs (mmcblk0p12): Ignoring removed nomblk_io_submit option
[ 6.216360] EXT4-fs (mmcblk0p12): mounted filesystem with ordered data mode. Opts: nomblk_io_submit,noauto_da_alloc,errors=panic
[ 6.238814] kauditd_printk_skb: 5 callbacks suppressed
[ 6.238819] audit: type=1400 audit(12.319:16): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 6.261065] audit: type=1400 audit(12.327:17): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 6.278295] audit: type=1400 audit(12.327:18): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 6.287451] logd.auditd: start
[ 6.295433] audit: type=1400 audit(12.327:19): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 6.296641] zram0: detected capacity change from 0 to 314572800
[ 6.298740] logd.klogd: 6164642263
[ 6.315392] audit: type=1400 audit(12.327:20): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 6.315397] audit: type=1400 audit(12.331:21): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 6.315402] audit: type=1400 audit(12.331:22): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 6.315407] audit: type=1400 audit(12.331:23): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 6.315412] audit: type=1400 audit(12.331:24): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 6.315416] audit: type=1400 audit(12.331:25): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 6.359047] mkswap: Swapspace size: 307196k, UUID=d688742e-f6c3-4403-b4e4-8b99fa79ba2c
[ 6.437670] Adding 307196k swap on /dev/block/zram0. Priority:-2 extents:1 across:307196k SS
[ 6.448631] type=1400 audit(12.527:38): avc: denied { getattr } for pid=2347 comm="init" path="/data/cache" dev="mmcblk0p12" ino=262160 scontext=u:r:vendor_init:s0 tcontext=u:object_r:cache_file:s0 tclass=dir permissive=0
[ 6.469405] type=1400 audit(12.527:38): avc: denied { getattr } for pid=2347 comm="init" path="/data/cache" dev="mmcblk0p12" ino=262160 scontext=u:r:vendor_init:s0 tcontext=u:object_r:cache_file:s0 tclass=dir permissive=0
[ 6.489258] type=1400 audit(12.527:39): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 6.788571] update_verifier: Started with arg 1: nonencrypted
[ 6.798349] update_verifier: Booting slot 0: isSlotMarkedSuccessful=1
[ 6.804822] update_verifier: Leaving update_verifier.
[ 6.861073] logd.daemon: reinit
[ 6.883568] rfkill: BT RF going to : off
[ 6.895565] Mass Storage Function, version: 2009/09/11
[ 6.900844] LUN: removable file: (no medium)
[ 6.909178] using random self ethernet address
[ 6.913765] using random host ethernet address
[ 6.920050] file system registered
[ 7.000932] random: crng init done
[ 7.034536] healthd: battery l=85 v=3 t=35.0 h=2 st=2 c=400 fc=4000000 cc=32 chg=a
[ 7.218829] healthd: battery l=85 v=3 t=35.0 h=2 st=2 c=400 fc=4000000 cc=32 chg=a
evk_8mq:/ $ [ 7.512491] type=1400 audit(12.543:46): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0 duplicate messages suppressed
[ 7.531381] type=1400 audit(13.587:548): avc: denied { read } for pid=3018 comm="usb@1.1-service" name="u:object_r:ffs_prop:s0" dev="tmpfs" ino=11527 scontext=u:r:hal_usb_impl:s0 tcontext=u:object_r:ffs_prop:s0 tclass=file permissive=0
[ 7.552746] type=1400 audit(13.587:548): avc: denied { read } for pid=3018 comm="usb@1.1-service" name="u:object_r:ffs_prop:s0" dev="tmpfs" ino=11527 scontext=u:r:hal_usb_impl:s0 tcontext=u:object_r:ffs_prop:s0 tclass=file permissive=0
[ 7.573956] type=1400 audit(13.591:549): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 7.615861] read descriptors
[ 7.618957] read strings
[ 9.657919] capability: warning: `main' uses 32-bit capabilities (legacy support in use)
[ 12.458645] type=1400 audit(14.851:576): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0 duplicate messages suppressed
[ 12.465592] audit_log_lost: 16 callbacks suppressed
[ 12.465596] audit: audit_lost=522 audit_rate_limit=5 audit_backlog_limit=64
[ 12.477396] type=1400 audit(18.535:577): avc: denied { dac_read_search } for pid=3031 comm="Binder:3031_1" capability=2 scontext=u:r:installd:s0 tcontext=u:r:installd:s0 tclass=capability permissive=0
[ 12.507357] audit: rate limit exceeded
[ 12.623155] healthd: battery l=85 v=3 t=35.0 h=2 st=2 c=400 fc=4000000 cc=32 chg=a
[ 13.060162] healthd: battery l=85 v=3 t=35.0 h=2 st=2 c=400 fc=4000000 cc=32 chg=a
[ 13.070789] healthd: battery l=85 v=3 t=35.0 h=2 st=2 c=400 fc=4000000 cc=32 chg=a
[ 13.229161] init: processing action (sys.sysctl.extra_free_kbytes=*) from (/init.rc:725)
[ 13.499116] audit: audit_lost=2736 audit_rate_limit=5 audit_backlog_limit=64
[ 13.502820] type=1400 audit(18.543:582): avc: denied { dac_read_search } for pid=3031 comm="Binder:3031_1" capability=2 scontext=u:r:installd:s0 tcontext=u:r:installd:s0 tclass=capability permissive=0 duplicate messages suppressed
[ 13.515231] audit: rate limit exceeded
[ 13.527460] type=1400 audit(1554577531.319:2797): avc: denied { dac_read_search } for pid=3031 comm="Binder:3031_5" capability=2 scontext=u:r:installd:s0 tcontext=u:r:installd:s0 tclass=capability permissive=0
[ 15.534442] read descriptors
[ 15.537340] read strings
[ 15.540125] read descriptors
[ 15.543091] read strings
[ 15.563797] acc_open
[ 15.566005] acc_release
[ 15.770912] Atheros 8031 ethernet 30be0000.ethernet-1:00: attached PHY driver [Atheros 8031 ethernet] (mii_bus:phy_addr=30be0000.ethernet-1:00, irq=POLL)
[ 15.785634] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[ 15.806447] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[ 15.821682] type=1400 audit(1554577531.323:2801): avc: denied { dac_read_search } for pid=3031 comm="Binder:3031_5" capability=2 scontext=u:r:installd:s0 tcontext=u:r:installd:s0 tclass=capability permissive=0 duplicate messages suppressed
[ 15.843492] type=1400 audit(1554577533.643:2885): avc: denied { dac_read_search } for pid=3292 comm="main" capability=2 scontext=u:r:zygote:s0 tcontext=u:r:zygote:s0 tclass=capability permissive=0
[ 15.885583] audit: audit_lost=2819 audit_rate_limit=5 audit_backlog_limit=64
[ 15.885878] type=1400 audit(1554577533.643:2888): avc: denied { dac_read_search } for pid=3292 comm="main" capability=2 scontext=u:r:zygote:s0 tcontext=u:r:zygote:s0 tclass=capability permissive=0 duplicate messages suppressed
[ 15.892767] audit: rate limit exceeded
[ 15.919613] type=1400 audit(1554577533.707:2889): avc: denied { dac_read_search } for pid=3308 comm="main" capability=2 scontext=u:r:zygote:s0 tcontext=u:r:zygote:s0 tclass=capability permissive=0
[ 15.965792] sdcardfs version 2.0
[ 15.974668] sdcardfs: dev_name -> /data/media
[ 15.979538] sdcardfs: options -> fsuid=1023,fsgid=1023,multiuser,derive_gid,default_normal,mask=6,userid=0,gid=1015
[ 15.992643] sdcardfs: mnt -> ffff80005286dc20
[ 16.002628] sdcardfs: mounted on top of /data/media type ext4
[ 16.011563] Remount options were mask=23,gid=9997 for vfsmnt ffff80005eae0e20.
[ 16.019999] sdcardfs : options - debug:1
[ 16.024193] sdcardfs : options - gid:9997
[ 16.028393] sdcardfs : options - mask:23
[ 16.033056] Remount options were mask=7,gid=9997 for vfsmnt ffff80005eae1a60.
[ 16.040467] sdcardfs : options - debug:1
[ 16.044668] sdcardfs : options - gid:9997
[ 16.048859] sdcardfs : options - mask:7
[ 16.301352] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[ 17.040366] type=1400 audit(1554577533.707:2889): avc: denied { dac_read_search } for pid=3308 comm="main" capability=2 scontext=u:r:zygote:s0 tcontext=u:r:zygote:s0 tclass=capability permissive=0
[ 17.112526] type=1400 audit(1554577534.863:2917): avc: denied { read } for pid=3151 comm="system_server" name="state" dev="sysfs" ino=21256 scontext=u:r:system_server:s0 tcontext=u:object_r:sysfs:s0 tclass=file permissive=0
[ 18.907229] init: Service 'bootanim' (pid 3122) exited with status 0
[ 18.997765] init: processing action (sys.boot_completed=1) from (/init.rc:719)
[ 19.009050] init: processing action (sys.boot_completed=1) from (/vendor/etc/init/hw/init.freescale.imx8mq.rc:20)
[ 19.022540] init: processing action (sys.boot_completed=1) from (/vendor/etc/init/hw/init.freescale.imx8mq.rc:27)
[ 19.036516] type=1400 audit(1554577534.935:2921): avc: denied { dac_read_search } for pid=3609 comm="main" capability=2 scontext=u:r:zygote:s0 tcontext=u:r:zygote:s0 tclass=capability permissive=0 duplicate messages suppressed
[ 19.042785] init: processing action (sys.boot_completed=1 && sys.logbootcomplete=1) from (/system/etc/init/bootstat.rc:70)
[ 19.070260] init: starting service 'exec 6 (/system/bin/bootstat --set_system_boot_reason --record_boot_complete --record_boot_reason --record_time_since_factory_reset -l)'...
[ 19.071993] type=1400 audit(1554577536.859:2922): avc: denied { dac_read_search } for pid=2919 comm="Binder:2919_1" capability=2 scontext=u:r:vold:s0 tcontext=u:r:vold:s0 tclass=capability permissive=0
[ 19.087543] audit: audit_lost=2846 audit_rate_limit=5 audit_backlog_limit=64
[ 19.108671] type=1400 audit(1554577536.891:2925): avc: denied { dac_read_search } for pid=2919 comm="Binder:2919_1" capability=2 scontext=u:r:vold:s0 tcontext=u:r:vold:s0 tclass=capability permissive=0 duplicate messages suppressed
[ 19.111375] audit: rate limit exceeded
[ 19.132521] type=1400 audit(1554577536.911:2926): avc: denied { dac_read_search } for pid=1 comm="init" capability=2 scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability permissive=0
[ 19.136194] init: Command 'exec_background - system log -- /system/bin/bootstat --set_system_boot_reason --record_boot_complete --record_boot_reason --record_time_since_factory_reset -l' action=sys.boot_completed=1 && sys.logbootcomplete=1 (/system/etc/init/bootstat.rc:76) took 66ms and succeeded
[ 19.179131] init: processing action (sys.boot_completed=1 && sys.wifitracing.started=0) from (/system/etc/init/wifi-events.rc:20)

I appreciate it very much if you could give me some advices.

Thank you ~

Felix

0 Kudos
1 Reply

1,461 Views
karangajjar
Senior Contributor II

Hi Felix Ye

I tried the prebuilt image android_p9.0.0_2.0.0-ga_image_8mqevk on imx8mqevk board and I am able to login into user space.

Please refer https://www.nxp.com/webapp/Download?colCode=P9.0.0_2.0.0_GA_DEMO_8MQ&appType=license  link to download prebuild android image.

While copying the image in SD card, specify the size of SD card in command.

For example, if you are using 16GB SD card then there in no partition table file in that package so you need to use 8GB/32GB SD card. For 8GB SD card mention -c 7  and for 32GB SD card mention -c 28 in command.

For more reference please refer Android user guide section 5.1.1.

https://www.nxp.com/docs/en/supporting-information/android_p9.0.0_2.0.0-ga_docs.zip 

Let us know in case of any concerns.

 

Regards,

Karan Gajjar

0 Kudos