Clone Apalis using dd

Hello,

I’m trying to clone an already configured Apalis iMX6 board into a raw Apalis in order to prepare a production programming procedure. For this I’m using linux dd command to create an .img of the whole eMMC using UMS U-boot feature.

Firstly, I setup the configured Apalis to use UMS feature by entering U-boot and executing ums 0 mm 0 command. With this I’m able to see two partitions, boot and rootfs and their are mounted without errors.
Then I connect Apalis to linux machine and clone the whole device:

> sudo dd if=/dev/sdb of=apalis.img

The image is generated correctly.

After that, I connect the raw Apalis and do the same to access to the eMMC, then run the following:

> sudo dd if=apalis.img of=/dev/sdb

The content of the image appears to be cloned directly to the eMMC, but when I tried to mount the device, the rootfs partition appears to be corrupted. I get the following error:

1079-error-mounting.png

And also there is not possible to boot the linux from new fresh cloned Apalis.

Am I doing something incorrectly? Is it recommended to use dd to clone and snapshot of one Apalis from another one?

Thank you in advance for your support!

Regards,
Jaime.

Hi @jaimelaborda

Welcome to the Toradex Community!!!

You should use the Toradex Easy Installer for your use case. You can take our regular bsp Tezi images and customize them as you wish. Then you can flash them using Toadex Easy Installer using USB or SD Card or even over Ethernet.

Best regards
Jaski

Using dd is definitely a very bad idea as any kind of size difference anywhere may have a devestating effect not to speak of any potential issues on read failures.

Please have a look at the following article about how you may go about cloning a module:

https://developer.toradex.com/how-to-clone-embedded-linux-on-emmc-based-toradex-modules

Hi @jaski.tx

Thank you for your answer. Is there any documentation about Tezi images?
I’m only interested in adding some packages to the default images, as python, gstreamer and samba.
Not building a whole image from scratch.

Regards,
Jaime.

Hi, you can also install these packages using opkg install <pacakge_name>. Only for those packages, which are not included in the regular bsp, you have to do the complete open embedded build.

The documentation about Tezi images can be found here.

Hello @marcel.tx
Thank you for your repply.

I have been following the documentation you passed me without succes. I’m able to extract the image from configured Apalis with success and also to integrate the artefacts and update media (It appears I have succesfully generate flash_blk.img, flash_eth.img, flash_mmc.img and all that stuff).
But when I try to flash the custom image using U-boot (run setupdate; run update), it stops showing that message:

Any idea? Could you please help me?

Thanks!

Regards,
Jaime.

While such screenshots are generally not much helpful at all and a complete serial debug console boot log as a textual file would be much better I guess you may suffer from something like that.

Thank you @marcel.tx . Please find attached the complete log file of serial console.
Thanks!

Industrial temperature grade DDR3 timings.
Trying to boot from MMC1


U-Boot 2016.11-2.7.4+g1b121c6 (Oct 05 2017 - 04:30:53 +0000)

CPU:   Freescale i.MX6Q rev1.5 at 792 MHz
Reset cause: POR
I2C:   ready
DRAM:  2 GiB
PMIC:  device id: 0x10, revision id: 0x21, programmed
MMC:   FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2
*** Warning - bad CRC, using default environment

auto-detected panel vga-rgb
Display: vga-rgb (640x480)
In:    serial
Out:   serial
Err:   serial
Model: Toradex Apalis iMX6 Quad 2GB IT V1.1C, Serial# 05203436
Net:   using PHY at 7
FEC [PRIME]
Hit any key to stop autoboot:  1  0
Apalis iMX6 #   run setupdate
MMC: no card present
** Bad device mmc 1 **
MMC: no card present
** Bad device mmc 2 **
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 1 USB Device(s) found
USB1:   USB EHCI 1.00
scanning bus 1 for devices... 3 USB Device(s) found
       scanning usb for storage devices... 1 Storage Device(s) found
       scanning usb for ethernet devices... 0 Ethernet Device(s) found
reading flash_blk.img
710 bytes read in 23 ms (29.3 KiB/s)
## Executing script at 12000000
reading apalis_imx6/flash_blk.img
4261 bytes read in 30 ms (138.7 KiB/s)
## Executing script at 12000000
enter "run update" to update the entire module
Apalis iMX6 # run update
switch to partitions #1, OK
mmc0(part 1) is current device

MMC read: dev # 0, block # 138, count 1 ... 1 blocks read: OK
reading apalis_imx6/u-boot.imx-spl
371336 bytes read in 56 ms (6.3 MiB/s)
switch to partitions #1, OK
mmc0(part 1) is current device

MMC write: dev # 0, block # 138, count 726 ... 726 blocks written: OK
Fuse 0, 5:     5072
Fast boot mode already fused, no need to fuse
reading apalis_imx6/mbr.bin
512 bytes read in 24 ms (20.5 KiB/s)
switch to partitions #0, OK
mmc0(part 0) is current device

MMC write: dev # 0, block # 0, count 1 ... 1 blocks written: OK
reading apalis_imx6/boot.vfat
16777216 bytes read in 1209 ms (13.2 MiB/s)
switch to partitions #0, OK
mmc0(part 0) is current device

MMC write: dev # 0, block # 8192, count 32768 ... 32768 blocks written: OK
reading apalis_imx6/uImage
5327952 bytes read in 408 ms (12.5 MiB/s)
writing uImage
5327952 bytes written
reading apalis_imx6/imx6q-apalis-eval.dtb
50216 bytes read in 37 ms (1.3 MiB/s)
writing imx6q-apalis-eval.dtb
50216 bytes written
reading apalis_imx6/root.ext4-100
67108864 bytes read in 4756 ms (13.5 MiB/s)
switch to partitions #0, OK
mmc0(part 0) is current device

MMC write: dev # 0, block # 40960, count 131072 ... 131072 blocks written: OK
reading apalis_imx6/root.ext4-101
67108864 bytes read in 4760 ms (13.4 MiB/s)
switch to partitions #0, OK
mmc0(part 0) is current device

MMC write: dev # 0, block # 172032, count 131072 ... 131072 blocks written: OK
reading apalis_imx6/root.ext4-102
67108864 bytes read in 4761 ms (13.4 MiB/s)
switch to partitions #0, OK
mmc0(part 0) is current device

MMC write: dev # 0, block # 303104, count 131072 ... 131072 blocks written: OK
reading apalis_imx6/root.ext4-103
67108864 bytes read in 4757 ms (13.5 MiB/s)
switch to partitions #0, OK
mmc0(part 0) is current device

MMC write: dev # 0, block # 434176, count 131072 ... 131072 blocks written: OK
reading apalis_imx6/root.ext4-104
57671680 bytes read in 4091 ms (13.4 MiB/s)
switch to partitions #0, OK
mmc0(part 0) is current device

MMC write: dev # 0, block # 565248, count 112640 ... 112640 blocks written: OK
resetting ...

Industrial temperature grade DDR3 timings.
Trying to boot from MMC1


U-Boot 2016.11-2.7.4+g1b121c6 (Oct 05 2017 - 04:30:53 +0000)

CPU:   Freescale i.MX6Q rev1.5 at 792 MHz
Reset cause: WDOG
I2C:   ready
DRAM:  2 GiB
PMIC:  device id: 0x10, revision id: 0x21, programmed
k5éþFSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2
*** Warning - bad CRC, using default environment

auto-detected panel vga-rgb
Display: vga-rgb (640x480)
In:    serial
Out:   serial
Err:   serial
Model: Toradex Apalis iMX6 Quad 2GB IT V1.1C, Serial# 05203436
Net:   using PHY at 7
FEC [PRIME]
Hit any key to stop autoboot:  1  0 
Booting from internal eMMC chip...
reading imx6q-apalis-eval.dtb
50216 bytes read in 18 ms (2.7 MiB/s)
reading uImage
5327952 bytes read in 159 ms (32 MiB/s)
## Booting kernel from Legacy Image at 11000000 ...
   Image Name:   Linux-4.1.44
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    5327888 Bytes = 5.1 MiB
   Load Address: 10008000
   Entry Point:  10008000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 12000000
   Booting using the fdt blob at 0x12000000
   Loading Kernel Image ... OK
   Using Device Tree in place at 12000000, end 1200f427

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Initializing cgroup subsys cpu
[    0.000000] Initializing cgroup subsys cpuacct
[    0.000000] Linux version 4.1.44 (sop@Simrad) (gcc version 6.2.1 20161016 (Linaro GCC 6.2-2016.11) ) #3 SMP Wed Feb 21 12:34:24 EST 2018
[    0.000000] CPU: ARMv7 Processor [412fc09a] revision 10 (ARMv7), cr=10c5387d
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] Machine model: Toradex Apalis iMX6Q/D V1.0 Module on Apalis Evaluation Board
[    0.000000] Reserved memory: created CMA memory pool at 0x62000000, size 320 MiB
[    0.000000] Reserved memory: initialized node linux,cma, compatible id shared-dma-pool
[    0.000000] Memory policy: Data cache writealloc
[    0.000000] PERCPU: Embedded 12 pages/cpu @d0efc000 s16588 r8192 d24372 u49152
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 521024
[    0.000000] Kernel command line: enable_wait_mode=off vmalloc=400M ip=off root=/dev/mmcblk0p2 ro rootfstype=ext4 rootwait fec_mac=00:14:2d:4f:65:ec consoleblank=0 no_console_suspend=1 console=tty1 console=ttymxc0,115200n8 mxc_hdmi.only_cea=1 video=mxcfb0:dev=hdmi,1920x1080M@60,if=RGB24 video=mxcfb1:off video=mxcfb2:off video=mxcfb3:off fbmem=32M
[    0.000000] PID hash table entries: 4096 (order: 2, 16384 bytes)
[    0.000000] Dentry cache hash table entries: 262144 (order: 8, 1048576 bytes)
[    0.000000] Inode-cache hash table entries: 131072 (order: 7, 524288 bytes)
[    0.000000] Memory: 1740284K/2097152K available (6923K kernel code, 241K rwdata, 2224K rodata, 336K init, 422K bss, 29188K reserved, 327680K cma-reserved, 425984K highmem)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
[    0.000000]     vmalloc : 0xe6800000 - 0xff000000   ( 392 MB)
[    0.000000]     lowmem  : 0x80000000 - 0xe6000000   (1632 MB)
[    0.000000]     pkmap   : 0x7fe00000 - 0x80000000   (   2 MB)
[    0.000000]     modules : 0x7f000000 - 0x7fe00000   (  14 MB)
[    0.000000]       .text : 0x80008000 - 0x808f70e4   (9149 kB)
[    0.000000]       .init : 0x808f8000 - 0x8094c000   ( 336 kB)
[    0.000000]       .data : 0x8094c000 - 0x80988560   ( 242 kB)
[    0.000000]        .bss : 0x80988560 - 0x809f1e20   ( 423 kB)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000] 	Additional per-CPU info printed with stalls.
[    0.000000] NR_IRQS:16 nr_irqs:16 16
[    0.000000] L2C-310 erratum 769419 enabled
[    0.000000] L2C-310 enabling early BRESP for Cortex-A9
[    0.000000] L2C-310 full line of zeros enabled for Cortex-A9
[    0.000000] L2C-310 ID prefetch enabled, offset 16 lines
[    0.000000] L2C-310 dynamic clock gating enabled, standby mode enabled
[    0.000000] L2C-310 cache controller enabled, 16 ways, 1024 kB
[    0.000000] L2C-310: CACHE_ID 0x410000c7, AUX_CTRL 0x76470001
[    0.000000] mxc_clocksource_init 3000000
[    0.000000] Switching to timer-based delay loop, resolution 333ns
[    0.000007] sched_clock: 32 bits at 3000kHz, resolution 333ns, wraps every 715827882841ns
[    0.000024] clocksource mxc_timer1: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 637086815595 ns
[    0.001107] Console: colour dummy device 80x30
[    0.001776] console [tty1] enabled
[    0.001803] Calibrating delay loop (skipped), value calculated using timer frequency.. 6.00 BogoMIPS (lpj=30000)
[    0.001843] pid_max: default: 32768 minimum: 301
[    0.001955] Mount-cache hash table entries: 4096 (order: 2, 16384 bytes)
[    0.001981] Mountpoint-cache hash table entries: 4096 (order: 2, 16384 bytes)
[    0.002572] Initializing cgroup subsys freezer
[    0.002608] Initializing cgroup subsys debug
[    0.002644] CPU: Testing write buffer coherency: ok
[    0.002959] CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
[    0.003065] Setting up static identity map for 0x10008280 - 0x100082d8
[    0.004927] CPU1: thread -1, cpu 1, socket 0, mpidr 80000001
[    0.005581] CPU2: thread -1, cpu 2, socket 0, mpidr 80000002
[    0.006230] CPU3: thread -1, cpu 3, socket 0, mpidr 80000003
[    0.006295] Brought up 4 CPUs
[    0.006375] SMP: Total of 4 processors activated (24.00 BogoMIPS).
[    0.006397] CPU: All CPU(s) started in SVC mode.
[    0.006901] devtmpfs: initialized
[    0.020195] VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
[    0.020580] clocksource jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.020639] futex hash table entries: 1024 (order: 4, 65536 bytes)
[    0.040605] pinctrl core: initialized pinctrl subsystem
[    0.041779] NET: Registered protocol family 16
[    0.050107] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.079682] cpuidle: using governor ladder
[    0.109679] cpuidle: using governor menu
[    0.110014] CPU identified as i.MX6Q, silicon rev 1.5
[    0.135169] hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.
[    0.135221] hw-breakpoint: maximum watchpoint size is 4 bytes.
[    0.136183] imx6q-pinctrl 20e0000.iomuxc: initialized IMX pinctrl driver
[    0.137881] imx-gpc 20dc000.gpc: no fsl,ldo-bypass found!
[    0.149618] usb_host_vbus: supplied by usb_host_vbus_hub
[    0.150010] vgaarb: loaded
[    0.150817] SCSI subsystem initialized
[    0.151371] usbcore: registered new interface driver usbfs
[    0.151459] usbcore: registered new interface driver hub
[    0.151564] usbcore: registered new device driver usb
[    0.152278] i2c-gpio i2c@0: using pins 80 (SDA) and 62 (SCL)
[    0.153276] i2c i2c-1: IMX I2C adapter registered
[    0.153312] i2c i2c-1: can't use DMA
[    0.154842] stmpe-i2c 2-0041: stmpe811 detected, chip id: 0x811
[    0.156738] i2c i2c-2: IMX I2C adapter registered
[    0.156770] i2c i2c-2: can't use DMA
[    0.157457] i2c i2c-3: IMX I2C adapter registered
[    0.157490] i2c i2c-3: can't use DMA
[    0.157657] Linux video capture interface: v2.00
[    0.157728] pps_core: LinuxPPS API ver. 1 registered
[    0.157749] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    0.157800] PTP clock support registered
[    0.169728] imx-ipuv3 2400000.ipu: IPU DMFC NORMAL mode: 1(0~1), 5B(4,5), 5F(6,7)
[    0.189721] imx-ipuv3 2800000.ipu: IPU DMFC NORMAL mode: 1(0~1), 5B(4,5), 5F(6,7)
[    0.190649] mxc_mipi_csi2 21dc000.mipi_csi: i.MX MIPI CSI2 driver probed ipu0 csi1
[    0.190696] mxc_mipi_csi2 21dc000.mipi_csi: i.MX MIPI CSI2 dphy version is 0x3130302a
[    0.190805] MIPI CSI2 driver module loaded
[    0.191019] Advanced Linux Sound Architecture Driver Initialized.
[    0.192820] Switched to clocksource mxc_timer1
[    0.203621] NET: Registered protocol family 2
[    0.204359] TCP established hash table entries: 16384 (order: 4, 65536 bytes)
[    0.204529] TCP bind hash table entries: 16384 (order: 5, 131072 bytes)
[    0.204793] TCP: Hash tables configured (established 16384 bind 16384)
[    0.204885] UDP hash table entries: 1024 (order: 3, 32768 bytes)
[    0.204975] UDP-Lite hash table entries: 1024 (order: 3, 32768 bytes)
[    0.205231] NET: Registered protocol family 1
[    0.205570] RPC: Registered named UNIX socket transport module.
[    0.205599] RPC: Registered udp transport module.
[    0.205619] RPC: Registered tcp transport module.
[    0.205639] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.206439] CPU PMU: Failed to parse /soc/pmu/interrupt-affinity[0]
[    0.206509] hw perfevents: enabled with armv7_cortex_a9 PMU driver, 7 counters available
[    0.208309] Bus freq driver module loaded
[    0.215392] VFS: Disk quotas dquot_6.6.0
[    0.215586] VFS: Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
[    0.217116] NFS: Registering the id_resolver key type
[    0.217175] Key type id_resolver registered
[    0.217198] Key type id_legacy registered
[    0.217234] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[    0.217755] ntfs: driver 2.1.32 [Flags: R/W].
[    0.218230] fuse init (API version 7.23)
[    0.222422] bounce: pool size: 64 pages
[    0.222462] io scheduler noop registered
[    0.222491] io scheduler deadline registered
[    0.222681] io scheduler cfq registered (default)
[    0.225146] backlight supply power not found, using dummy regulator
[    0.226784] MIPI DSI driver module loaded
[    0.228206] 20e0000.hdmi_video supply HDMI not found, using dummy regulator
[    0.230258] mxc_hdmi 20e0000.hdmi_video: Detected HDMI controller 0x13:0xa:0xa0:0xc1
[    0.230322] fbcvt: 1920x1080@60: CVT Name - 2.073M9
[    0.230462] mxc_sdc_fb fb@0: registered mxc display driver hdmi
[    0.246146] mxc_sdc_fb fb@0: 1920x1080 h_sync,r,l: 44,88,148  v_sync,l,u: 5,4,36 pixclock=148500000 Hz
[    0.262900] imx-ipuv3 2400000.ipu: IPU DMFC DP HIGH RESOLUTION: 1(0,1), 5B(2~5), 5F(6,7)
[    0.296780] mxc_sdc_fb fb@0: 1920x1080 h_sync,r,l: 44,88,148  v_sync,l,u: 5,4,36 pixclock=148500000 Hz
[    0.335047] Console: switching to colour frame buffer device 240x67
[    0.370286] mxc_sdc_fb fb@1: mxcfb1 is turned off!
[    0.370447] mxc_sdc_fb fb@2: mxcfb2 is turned off!
[    0.370597] mxc_sdc_fb fb@3: mxcfb3 is turned off!
[    0.372152] imx-sdma 20ec000.sdma: no iram assigned, using external mem
[    0.372603] imx-sdma 20ec000.sdma: no event needs to be remapped
[    0.372986] imx-sdma 20ec000.sdma: loaded firmware 3.3
[    0.375630] imx-sdma 20ec000.sdma: initialized
[    0.377401] pfuze100-regulator 2-0008: Full layer: 2, Metal layer: 1
[    0.378122] pfuze100-regulator 2-0008: FAB: 0, FIN: 0
[    0.378225] pfuze100-regulator 2-0008: pfuze100 found.
[    0.392501] 2020000.serial: ttymxc0 at MMIO 0x2020000 (irq = 27, base_baud = 5000000) is a IMX
[    1.265273] console [ttymxc0] enabled
[    1.269846] 21e8000.serial: ttymxc1 at MMIO 0x21e8000 (irq = 303, base_baud = 5000000) is a IMX
[    1.279263] 21f0000.serial: ttymxc3 at MMIO 0x21f0000 (irq = 304, base_baud = 5000000) is a IMX
[    1.288635] 21f4000.serial: ttymxc4 at MMIO 0x21f4000 (irq = 305, base_baud = 5000000) is a IMX
[    1.298374] [drm] Initialized drm 1.1.0 20060810
[    1.303549] [drm] Initialized vivante 1.0.0 20120216 on minor 0
[    1.317830] brd: module loaded
[    1.326101] loop: module loaded
[    1.330527] ahci-imx 2200000.sata: fsl,transmit-level-mV not specified, using 00000024
[    1.338635] ahci-imx 2200000.sata: fsl,transmit-boost-mdB not specified, using 00000480
[    1.346813] ahci-imx 2200000.sata: fsl,transmit-atten-16ths not specified, using 00002000
[    1.355160] ahci-imx 2200000.sata: fsl,receive-eq-mdB not specified, using 05000000
[    1.366390] ahci-imx 2200000.sata: SSS flag set, parallel bus scan disabled
[    1.373545] ahci-imx 2200000.sata: AHCI 0001.0300 32 slots 1 ports 3 Gbps 0x1 impl platform mode
[    1.382499] ahci-imx 2200000.sata: flags: ncq sntf stag pm led clo only pmp pio slum part ccc apst 
[    1.393128] scsi host0: ahci-imx
[    1.396724] ata1: SATA max UDMA/133 mmio [mem 0x02200000-0x02203fff] port 0x100 irq 315
[    1.406944] spi_imx 2008000.ecspi: probed
[    1.411868] spi_imx 200c000.ecspi: probed
[    1.416890] vcan: Virtual CAN interface driver
[    1.426513] CAN device driver interface
[    1.435696] 2090000.flexcan supply xceiver not found, using dummy regulator
[    1.448623] flexcan 2090000.flexcan: device registered (reg_base=e6aa0000, irq=36)
[    1.461387] 2094000.flexcan supply xceiver not found, using dummy regulator
[    1.474275] flexcan 2094000.flexcan: device registered (reg_base=e6aa8000, irq=37)
[    1.488198] 2188000.ethernet supply phy not found, using dummy regulator
[    1.513227] pps pps0: new PPS source ptp0
[    1.523685] libphy: fec_enet_mii_bus: probed
[    1.534803] fec 2188000.ethernet eth0: registered PHC device 0
[    1.546124] usbcore: registered new interface driver asix
[    1.556786] usbcore: registered new interface driver ax88179_178a
[    1.568046] usbcore: registered new interface driver cdc_ether
[    1.579020] usbcore: registered new interface driver net1080
[    1.589786] usbcore: registered new interface driver cdc_subset
[    1.600767] usbcore: registered new interface driver zaurus
[    1.611408] usbcore: registered new interface driver cdc_ncm
[    1.622045] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    1.633606] ehci-pci: EHCI PCI platform driver
[    1.643138] ehci-mxc: Freescale On-Chip EHCI Host driver
[    1.653650] usbcore: registered new interface driver usb-storage
[    1.664848] usbcore: registered new interface driver usbserial
[    1.675634] usbcore: registered new interface driver usbserial_generic
[    1.687061] usbserial: USB Serial support registered for generic
[    1.697944] usbcore: registered new interface driver ftdi_sio
[    1.708562] usbserial: USB Serial support registered for FTDI USB Serial Device
[    1.720797] usbcore: registered new interface driver pl2303
[    1.731252] usbserial: USB Serial support registered for pl2303
[    1.743315] 2184800.usbmisc supply vbus-wakeup not found, using dummy regulator
[    1.752859] ata1: SATA link down (SStatus 0 SControl 300)
[    1.752904] ahci-imx 2200000.sata: no device found, disabling link.
[    1.752910] ahci-imx 2200000.sata: pass ahci_imx..hotplug=1 to enable hotplug
[    1.797529] ci_hdrc ci_hdrc.0: EHCI Host Controller
[    1.800289] ci_hdrc ci_hdrc.1: EHCI Host Controller
[    1.800316] ci_hdrc ci_hdrc.1: new USB bus registered, assigned bus number 1
[    1.812858] ci_hdrc ci_hdrc.1: USB 2.0 started, EHCI 1.00
[    1.813714] hub 1-0:1.0: USB hub found
[    1.813751] hub 1-0:1.0: 1 port detected
[    1.814778] mousedev: PS/2 mouse device common for all mice
[    1.823655] input: stmpe-ts as /devices/soc0/soc/2100000.aips-bus/21a4000.i2c/i2c-2/2-0041/stmpe-ts/input/input0
[    1.827078] rtc-ds1307 1-0068: oscillator failed, set time!
[    1.827271] rtc-ds1307 1-0068: rtc core: registered m41t0 as rtc0
[    1.827900] snvs_rtc 20cc000.snvs:snvs-rtc-lp: rtc core: registered 20cc000.snvs:snvs-r as rtc1
[    1.828038] i2c /dev entries driver
[    1.829340] mxc_v4l2_output v4l2_out: V4L2 device registered as video16
[    1.829499] mxc_v4l2_output v4l2_out: V4L2 device registered as video17
[    1.830967] imx2-wdt 20bc000.wdog: timeout 60 sec (nowayout=0)
[    1.831305] sdhci: Secure Digital Host Controller Interface driver
[    1.831307] sdhci: Copyright(c) Pierre Ossman
[    1.831316] sdhci-pltfm: SDHCI platform and OF driver helper
[    1.832398] /soc/aips-bus@02100000/usdhc@02190000: voltage-ranges unspecified
[    1.832427] sdhci-esdhc-imx 2190000.usdhc: Got CD GPIO
[    1.833850] sdhci-esdhc-imx 2190000.usdhc: No vqmmc regulator found
[    1.882947] mmc1: SDHCI controller on 2190000.usdhc [2190000.usdhc] using ADMA
[    1.885432] /soc/aips-bus@02100000/usdhc@02194000: voltage-ranges unspecified
[    1.885459] sdhci-esdhc-imx 2194000.usdhc: Got CD GPIO
[    1.886828] sdhci-esdhc-imx 2194000.usdhc: No vqmmc regulator found
[    1.942948] mmc2: SDHCI controller on 2194000.usdhc [2194000.usdhc] using ADMA
[    1.945592] /soc/aips-bus@02100000/usdhc@02198000: voltage-ranges unspecified
[    1.945984] sdhci-esdhc-imx 2198000.usdhc: No vqmmc regulator found
[    1.982854] mmc0: SDHCI controller on 2198000.usdhc [2198000.usdhc] using ADMA
[    1.993174] mxc_vpu 2040000.vpu_fsl: VPU initialized
[    1.993760] mxc_vdoa 21e4000.vdoa: i.MX Video Data Order Adapter(VDOA) driver probed
[    1.994720] Galcore version 5.0.11.41671
[    2.068666] mmc0: MAN_BKOPS_EN bit is not set
[    2.089155] mmc0: new DDR MMC card at address 0001
[    2.090001] mmcblk0: mmc0:0001 Q2J54A 3.59 GiB 
[    2.090243] mmcblk0boot0: mmc0:0001 Q2J54A partition 1 16.0 MiB
[    2.090540] mmcblk0boot1: mmc0:0001 Q2J54A partition 2 16.0 MiB
[    2.142493]  mmcblk0: p1 p2
[    2.264420] ci_hdrc ci_hdrc.0: new USB bus registered, assigned bus number 2
[    2.465954] caam 2100000.caam: Entropy delay = 3200
[    2.512869] usb 1-1: new high-speed USB device number 2 using ci_hdrc
[    2.532854] ci_hdrc ci_hdrc.0: USB 2.0 started, EHCI 1.00
[    2.536705] caam 2100000.caam: Instantiated RNG4 SH0
[    2.554134] hub 2-0:1.0: USB hub found
[    2.563029] hub 2-0:1.0: 1 port detected
[    2.597468] caam 2100000.caam: Instantiated RNG4 SH1
[    2.607594] caam 2100000.caam: device ID = 0x0a16010000000000 (Era -524)
[    2.619440] caam 2100000.caam: job rings = 2, qi = 0
[    2.684030] hub 1-1:1.0: USB hub found
[    2.688391] caam algorithms registered in /proc/crypto
[    2.693134] caam_jr 2101000.jr0: registering rng-caam
[    2.693997] snvs-secvio 20cc000.caam-snvs: can't get snvs clock
[    2.694050] snvs-secvio 20cc000.caam-snvs: violation handlers armed - non-secure state
[    2.694292] hidraw: raw HID events driver (C) Jiri Kosina
[    2.694466] usbcore: registered new interface driver usbhid
[    2.694468] usbhid: USB HID core driver
[    2.699720] stmpe-adc stmpe-adc: Initialized
[    2.702013] sgtl5000 2-000a: sgtl5000 revision 0x11
[    2.788347] hub 1-1:1.0: 4 ports detected
[    2.885596] imx-sgtl5000 sound: sgtl5000 <-> 2028000.ssi mapping ok
[    2.900923] imx-spdif sound-spdif: snd-soc-dummy-dai <-> 2004000.spdif mapping ok
[    2.917904] imx-audio-hdmi sound-hdmi: hdmi-hifi <-> soc:hdmi_audio@00120000 mapping ok
[    2.932505] NET: Registered protocol family 10
[    2.943312] NET: Registered protocol family 17
[    2.953059] can: controller area network core (rev 20120528 abi 9)
[    2.964596] NET: Registered protocol family 29
[    2.974224] can: raw protocol (rev 20120528)
[    2.983680] can: broadcast manager protocol (rev 20120528 t)
[    2.994538] can: netlink gateway (rev 20130117) max_hops=1
[    3.005640] Key type dns_resolver registered
[    3.016887] Registering SWP/SWPB emulation handler
[    3.027913] 1ffc000.pcie supply pcie-bus not found, using dummy regulator
[    3.102891] usb 1-1.2: new high-speed USB device number 3 using ci_hdrc
[    3.226669] usb-storage 1-1.2:1.0: USB Mass Storage device detected
[    3.239375] scsi host1: usb-storage 1-1.2:1.0
[    3.375601] imx6q-pcie 1ffc000.pcie: phy link never came up
[    3.386311] imx6q-pcie 1ffc000.pcie: failed to initialize host
[    3.397458] imx6q-pcie: probe of 1ffc000.pcie failed with error -22
[    3.411710] input: gpio-keys as /devices/soc0/gpio-keys/input/input1
[    3.424968] rtc-ds1307 1-0068: hctosys: unable to read the hardware clock
[    3.446938] ALSA device list:
[    3.455143]   #0: imx6q-apalis-sgtl5000
[    3.464017]   #1: imx-spdif
[    3.471736]   #2: imx-hdmi-soc
[    3.493903] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[    3.507191] VFS: Mounted root (ext4 filesystem) readonly on device 179:2.
[    3.520209] devtmpfs: mounted
[    3.528511] Freeing unused kernel memory: 336K
/sbin/init: error while loading shared libraries: libkmod.so.2: cannot open shared object file: No such file or directory
[    3.582956] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00007f00
[    3.582956] 
[    3.601966] CPU3: stopping
[    3.609510] CPU: 3 PID: 0 Comm: swapper/3 Not tainted 4.1.44 #3
[    3.620292] Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree)
[    3.631676] Backtrace: 
[    3.638966] [<80012f50>] (dump_backtrace) from [<80013170>] (show_stack+0x18/0x1c)
[    3.651479]  r7:f4a00100 r6:60000193 r5:00000000 r4:8096318c
[    3.662218] [<80013158>] (show_stack) from [<806c4c04>] (dump_stack+0x8c/0xa0)
[    3.674472] [<806c4b78>] (dump_stack) from [<800160cc>] (handle_IPI+0x154/0x174)
[    3.686937]  r7:f4a00100 r6:00000000 r5:00000003 r4:80988860
[    3.697752] [<80015f78>] (handle_IPI) from [<80009434>] (gic_handle_irq+0x64/0x68)
[    3.710415]  r7:f4a00100 r6:ce0a9f10 r5:8094e880 r4:f4a0010c
[    3.721262] [<800093d0>] (gic_handle_irq) from [<80013cc0>] (__irq_svc+0x40/0x54)
[    3.733866] Exception stack(0xce0a9f10 to 0xce0a9f58)
[    3.744017] 9f00:                                     00000000 d0f26200 00000005 0000033a
[    3.757390] 9f20: d686bc9d 00000000 d0f22ed0 00000001 d40e1b7d 00000000 806cc338 ce0a9f94
[    3.770800] 9f40: ce0a9ec8 ce0a9f58 800898b8 804e7b50 60000113 ffffffff
[    3.782687]  r7:ce0a9f44 r6:ffffffff r5:60000113 r4:804e7b50
[    3.793741] [<804e7a7c>] (cpuidle_enter_state) from [<804e7cc0>] (cpuidle_enter+0x1c/0x20)
[    3.807379]  r10:806cc338 r9:ce0a9fa8 r8:80953990 r7:d0f22ed0 r6:8094e554 r5:8094e5a0
[    3.820755]  r4:ce0a8000
[    3.828713] [<804e7ca4>] (cpuidle_enter) from [<80063584>] (cpu_startup_entry+0x1f8/0x308)
[    3.842503] [<8006338c>] (cpu_startup_entry) from [<80015ce8>] (secondary_start_kernel+0x148/0x154)
[    3.857124]  r7:80988888
[    3.865225] [<80015ba0>] (secondary_start_kernel) from [<100094cc>] (0x100094cc)
[    3.878275]  r5:00000015 r4:5e08806a
[    3.887465] CPU2: stopping
[    3.895734] CPU: 2 PID: 0 Comm: swapper/2 Not tainted 4.1.44 #3
[    3.907258] Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree)
[    3.919438] Backtrace: 
[    3.927527] [<80012f50>] (dump_backtrace) from [<80013170>] (show_stack+0x18/0x1c)
[    3.940833]  r7:f4a00100 r6:60010193 r5:00000000 r4:8096318c
[    3.952314] [<80013158>] (show_stack) from [<806c4c04>] (dump_stack+0x8c/0xa0)
[    3.965280] [<806c4b78>] (dump_stack) from [<800160cc>] (handle_IPI+0x154/0x174)
[    3.978373]  r7:f4a00100 r6:00000000 r5:00000002 r4:80988860
[    3.989805] [<80015f78>] (handle_IPI) from [<80009434>] (gic_handle_irq+0x64/0x68)
[    4.003154]  r7:f4a00100 r6:ce0a7f10 r5:8094e880 r4:f4a0010c
[    4.014709] [<800093d0>] (gic_handle_irq) from [<80013cc0>] (__irq_svc+0x40/0x54)
[    4.028017] Exception stack(0xce0a7f10 to 0xce0a7f58)
[    4.038903] 7f00:                                     00000000 809cd7a8 00000004 0000033b
[    4.053006] 7f20: d686bdeb 00000000 d0f16ed0 00000001 d5644e5b 00000000 806cc338 ce0a7f94
[    4.067158] 7f40: 00000000 ce0a7f58 8008acfc 804e7b50 60010013 ffffffff
[    4.079747]  r7:ce0a7f44 r6:ffffffff r5:60010013 r4:804e7b50
[    4.091506] [<804e7a7c>] (cpuidle_enter_state) from [<804e7cc0>] (cpuidle_enter+0x1c/0x20)
[    4.105808]  r10:806cc338 r9:ce0a7fa8 r8:80953990 r7:d0f16ed0 r6:8094e554 r5:8094e5a0
[    4.119834]  r4:ce0a6000
[    4.128393] [<804e7ca4>] (cpuidle_enter) from [<80063584>] (cpu_startup_entry+0x1f8/0x308)
[    4.142794] [<8006338c>] (cpu_startup_entry) from [<80015ce8>] (secondary_start_kernel+0x148/0x154)
[    4.158007]  r7:80988888
[    4.166718] [<80015ba0>] (secondary_start_kernel) from [<100094cc>] (0x100094cc)
[    4.180370]  r5:00000015 r4:5e08806a
[    4.190201] CPU1: stopping
[    4.199056] CPU: 1 PID: 0 Comm: swapper/1 Not tainted 4.1.44 #3
[    4.211167] Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree)
[    4.223908] Backtrace: 
[    4.232598] [<80012f50>] (dump_backtrace) from [<80013170>] (show_stack+0x18/0x1c)
[    4.246546]  r7:f4a00100 r6:60000193 r5:00000000 r4:8096318c
[    4.258651] [<80013158>] (show_stack) from [<806c4c04>] (dump_stack+0x8c/0xa0)
[    4.272216] [<806c4b78>] (dump_stack) from [<800160cc>] (handle_IPI+0x154/0x174)
[    4.285941]  r7:f4a00100 r6:00000000 r5:00000001 r4:80988860
[    4.298064] [<80015f78>] (handle_IPI) from [<80009434>] (gic_handle_irq+0x64/0x68)
[    4.312003]  r7:f4a00100 r6:ce0a5f10 r5:8094e880 r4:f4a0010c
[    4.324128] [<800093d0>] (gic_handle_irq) from [<80013cc0>] (__irq_svc+0x40/0x54)
[    4.338058] Exception stack(0xce0a5f10 to 0xce0a5f58)
[    4.349549] 5f00:                                     ce0a5f60 00000017 d686ba03 00000000
[    4.364240] 5f20: d686ba03 00000000 d0f0aed0 00000000 d40e1113 00000000 806cc338 ce0a5f94
[    4.378943] 5f40: a6aaaaab ce0a5f58 00000009 804e7b50 80000113 ffffffff
[    4.392043]  r7:ce0a5f44 r6:ffffffff r5:80000113 r4:804e7b50
[    4.404283] [<804e7a7c>] (cpuidle_enter_state) from [<804e7cc0>] (cpuidle_enter+0x1c/0x20)
[    4.419069]  r10:806cc338 r9:ce0a5fa8 r8:80953990 r7:d0f0aed0 r6:8094e554 r5:8094e5a0
[    4.433607]  r4:ce0a4000
[    4.442661] [<804e7ca4>] (cpuidle_enter) from [<80063584>] (cpu_startup_entry+0x1f8/0x308)
[    4.457521] [<8006338c>] (cpu_startup_entry) from [<80015ce8>] (secondary_start_kernel+0x148/0x154)
[    4.473178]  r7:80988888
[    4.482264] [<80015ba0>] (secondary_start_kernel) from [<100094cc>] (0x100094cc)
[    4.496254]  r5:00000015 r4:5e08806a
[    4.506413] ---[ end Kernel panic - not syncing: Attempted to kill init! exitcode=0x00007f00
[    4.506413] 
[    4.529477] ------------[ cut here ]------------
[    4.540648] WARNING: CPU: 0 PID: 1 at kernel/time/tick-broadcast.c:621 tick_handle_oneshot_broadcast+0x1ec/0x218()
[    4.557638] Modules linked in:
[    4.567293] CPU: 0 PID: 1 Comm: init Not tainted 4.1.44 #3
[    4.579345] Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree)
[    4.592423] Backtrace: 
[    4.601381] [<80012f50>] (dump_backtrace) from [<80013170>] (show_stack+0x18/0x1c)
[    4.615485]  r7:8008a9dc r6:60000193 r5:00000000 r4:8096318c
[    4.627750] [<80013158>] (show_stack) from [<806c4c04>] (dump_stack+0x8c/0xa0)
[    4.641500] [<806c4b78>] (dump_stack) from [<8002ec84>] (warn_slowpath_common+0x88/0xb8)
[    4.656154]  r7:8008a9dc r6:0000026d r5:00000009 r4:00000000
[    4.668482] [<8002ebfc>] (warn_slowpath_common) from [<8002ed58>] (warn_slowpath_null+0x24/0x2c)
[    4.683924]  r8:ffffffff r7:00000004 r6:80948648 r5:809cd7a4 r4:809883a9
[    4.697393] [<8002ed34>] (warn_slowpath_null) from [<8008a9dc>] (tick_handle_oneshot_broadcast+0x1ec/0x218)
[    4.713891] [<8008a7f0>] (tick_handle_oneshot_broadcast) from [<80021f04>] (mxc_timer_interrupt+0x34/0x3c)
[    4.730297]  r10:8098836c r9:ce003cc0 r8:00000011 r7:00000000 r6:00000000 r5:ce003d24
[    4.744976]  r4:00000001
[    4.754261] [<80021ed0>] (mxc_timer_interrupt) from [<8006ce60>] (handle_irq_event_percpu+0xa4/0x154)
[    4.770305]  r5:ce003d24 r4:809537c0
[    4.780722] [<8006cdbc>] (handle_irq_event_percpu) from [<8006cf60>] (handle_irq_event+0x50/0x74)
[    4.796481]  r10:00000000 r9:ce078000 r8:ce008000 r7:00000000 r6:ce079ec8 r5:ce003d24
[    4.811317]  r4:ce003cc0
[    4.820686] [<8006cf10>] (handle_irq_event) from [<8006ff74>] (handle_fasteoi_irq+0xbc/0x1a0)
[    4.836119]  r7:00000000 r6:ce079ec8 r5:80953e40 r4:ce003cc0
[    4.848747] [<8006feb8>] (handle_fasteoi_irq) from [<8006c49c>] (generic_handle_irq+0x34/0x44)
[    4.864292]  r7:00000000 r6:ce079ec8 r5:00000011 r4:00000011
[    4.876937] [<8006c468>] (generic_handle_irq) from [<8006c778>] (__handle_domain_irq+0x64/0xbc)
[    4.892619]  r5:00000011 r4:80948c34
[    4.903131] [<8006c714>] (__handle_domain_irq) from [<800093fc>] (gic_handle_irq+0x2c/0x68)
[    4.918473]  r9:ce078000 r8:ce008000 r7:f4a00100 r6:ce079dc0 r5:8094e880 r4:f4a0010c
[    4.933311] [<800093d0>] (gic_handle_irq) from [<80013cc0>] (__irq_svc+0x40/0x54)
[    4.947742] Exception stack(0xce079dc0 to 0xce079e08)
[    4.959694] 9dc0: 00000001 80989600 00000000 00000000 00000282 00000010 ce078000 00000000
[    4.974827] 9de0: ce008000 ce078000 00000000 ce079e64 ce079e08 ce079e08 800321ec 80032274
[    4.989951] 9e00: 20000113 ffffffff
[    5.000373]  r7:ce079df4 r6:ffffffff r5:20000113 r4:80032274
[    5.013095] [<800321cc>] (__do_softirq) from [<800326f0>] (irq_exit+0xbc/0x11c)
[    5.027393]  r10:00000000 r9:ce078000 r8:ce008000 r7:00000000 r6:00000000 r5:00000010
[    5.042357]  r4:ffffe000
[    5.051845] [<80032634>] (irq_exit) from [<8006c77c>] (__handle_domain_irq+0x68/0xbc)
[    5.066688]  r5:00000010 r4:80948c34
[    5.077289] [<8006c714>] (__handle_domain_irq) from [<800093fc>] (gic_handle_irq+0x2c/0x68)
[    5.092741]  r9:ce078000 r8:8000fa84 r7:f4a00100 r6:ce079ec8 r5:8094e880 r4:f4a0010c
[    5.107705] [<800093d0>] (gic_handle_irq) from [<80013cc0>] (__irq_svc+0x40/0x54)
[    5.122276] Exception stack(0xce079ec8 to 0xce079f10)
[    5.134379] 9ec0:                   00000051 60000193 80957b3c 80957b3c 00000000 8094e040
[    5.149678] 9ee0: 80989168 00000000 8000fa84 ce078000 00000000 ce079f2c ce079e10 ce079f10
[    5.164962] 9f00: 8006b0e4 806c3edc 60000113 ffffffff
[    5.177069]  r7:ce079efc r6:ffffffff r5:60000113 r4:806c3edc
[    5.189866] [<806c3d60>] (panic) from [<800309b8>] (do_exit+0xa04/0xa28)
[    5.203608]  r3:ce07c000 r2:ce07c00c r1:00007f00 r0:80834c9c
[    5.216400]  r7:ce079f58
[    5.225875] [<8002ffb4>] (do_exit) from [<8003196c>] (do_group_exit+0x48/0xd8)
[    5.240075]  r7:000000f8
[    5.249553] [<80031924>] (do_group_exit) from [<80031a14>] (__wake_up_parent+0x0/0x28)
[    5.264455]  r7:000000f8 r6:76f3d2a8 r5:7eb7dc50 r4:7eb7df9b
[    5.277183] [<800319fc>] (SyS_exit_group) from [<8000f8e0>] (ret_fast_syscall+0x0/0x3c)
[    5.292149] ---[ end trace 9d6dbef90a577cf6 ]---
[   12.577372] ci_hdrc ci_hdrc.0: Device No Response

/sbin/init: error while loading shared libraries: libkmod.so.2: cannot open shared object file: No such file or directory

I guess however/whatever you did the resulting root file system is not proper as it seems to be missing some stuff.

Hello all,

Just notice that documentation seems to be for Apalis TK1: https://developer.toradex.com/how-to-clone-embedded-linux-on-emmc-based-toradex-modules

I’m using Apalis IMX6. Do the process differ on something?

Regards,

No, the process should really be more or less the same across all eMMC based modules.