GKD350H

從MicroSD提取uImage


步驟如下:

$ cd
$ sudo dd if=/dev/sdX of=20mb bs=1M count=20
$ od -A d -t x1 20mb | grep '1f 8b 08'
  3145792 1f 8b 08 00 00 00 00 00 02 03 ec bd 0f 74 5c d5
  7340096 1f 8b 08 00 00 00 00 00 02 03 ec bd 0f 74 1c d5

$ dd if=20mb of=uImage bs=1 skip=3145728
$ file uImage
  uImage: u-boot legacy uImage, Linux-3.10.14, Linux/MIPS, OS Kernel Image (gzip), 2652449 bytes, Sat Dec 21 07:09:18 2019, Load Address: 0x80010000, Entry Point: 0x803D8510, Header CRC: 0xF3AC741F, Data CRC: 0x68C1893B

$ dd if=20mb of=uImage_no_header bs=1 skip=3145792
$ file uImage_no_header
  uImage_no_header: gzip compressed data, max compression, from Unix, original size 0

$ zcat uImage_no_header > kernel
$ strings kernel | grep Linux
  Linux version 3.10.14 (root@avrman-virtual-machine) (gcc version 5.2.0 (Ingenic r3.2.0-gcc520 2017.08-24) ) #2 PREEMPT Sat Dec 21 02:09:15 EST 2019
  No init found.  Try passing init= option to kernel. See Linux Documentation/init.txt for guidance.
  Linux
  [%s] Warning! Received an indication that the LUN assignments on this target have changed. The Linux SCSI layer does not automatically remap LUN assignments.
  Warning! Received an indication that the LUN assignments on this target have changed. The Linux SCSI layer does not automatically remap LUN assignments.
  [%s] Warning! Received an indication that the operating parameters on this target have changed. The Linux SCSI layer does not automatically adjust these parameters.
  Warning! Received an indication that the operating parameters on this target have changed. The Linux SCSI layer does not automatically adjust these parameters.
  6Advanced Linux Sound Architecture Driver Initialized.
  Advanced Linux Sound Architecture Driver Version k%s.
  Linux

啟動參數:

$ strings 20mb | grep bootargs
  bootargs=console=ttyS1,115200n8 mem=128M@0x0 consoleblank=0 root=/dev/ram0 rw rdinit=/sbin/init
  bootargs=console=ttyS1,115200n8 mem=128M@0x0 consoleblank=0 init=/linuxrc root=/dev/mmcblk0p1 rw rootfstype=ext4 rootwait
  bootargs

U-Boot版號:

$ strings 20mb | grep U-Boot
  U-Boot
  U-Boot SPL 2013.07 (Nov 17 2019 - 21:50:26)
  Now running in RAM - U-Boot at: %08lx
  U-Boot
  ** Invalid partition type "%.32s" (expect "U-Boot")
  U-Boot 2013.07 (Nov 17 2019 - 21:50:26)


返回上一頁