azarton-c1-t31-sdcard Linux kernel uImage
Pre-release
Pre-release
This is a Linux kernel uImage for booting Azarton Cams from a (customized) rootfs located on the sdcard with the following partition layout:
- 1st partition: fat32, with this uImage renamed to:
factory_t31_ZMC6tiIDQN - 2nd partition: ext3, with a proper rootfs, e.g., see here (don't forget to properly configure your wireless lan, see:
/etc/wpa_supplicant.conf.distto use ssh to access the system. Alternatively you could open the cam and connect to its UART)
Compile Hints
- On Linux (or in a Linux VM), setup the Ingenic toolchain, e.g., located here
cd ./path/to/the/toolchain
export CROSS_COMPILE=$(pwd)/bin/mips-linux-gnu-
- Clone this repository and proceed with compiling:
cd ./path/to/the/kernel
make isvp_swan_azartonc1_defconfig
make uImage -j4
ls arch/mips/boot/uImage
Bootlog
Tested with bootloader version: "U-Boot 2013.07 (Jun 02 2020 - 18:53:44)", see boot messages/terminal log captured on UART:
U-Boot SPL 2013.07 (Jun 02 2020 - 18:53:44)
Timer init
CLK stop
PLL init
pll_init:366
pll_cfg.pdiv = 10, pll_cfg.h2div = 5, pll_cfg.h0div = 5, pll_cfg.cdiv = 1, pll_cfg.l2div = 2
nf=116 nr = 1 od0 = 1 od1 = 2
cppcr is 07405100
CPM_CPAPCR 0740510d
nf=100 nr = 1 od0 = 1 od1 = 2
cppcr is 06405100
CPM_CPMPCR 0640510d
nf=100 nr = 1 od0 = 1 od1 = 2
cppcr is 06405100
CPM_CPVPCR 0640510d
cppcr 0x9a7b5510
apll_freq 1392000000
mpll_freq 1200000000
vpll_freq = 1200000000
ddr sel mpll, cpu sel apll
ddrfreq 600000000
cclk 1392000000
l2clk 696000000
h0clk 240000000
h2clk 240000000
pclk 120000000
CLK init
SDRAM init
sdram init start
ddr_inno_phy_init ..!
phy reg = 0x00000007, CL = 0x00000007
ddr_inno_phy_init ..! 11: 00000004
ddr_inno_phy_init ..! 22: 00000006
ddr_inno_phy_init ..! 33: 00000006
REG_DDR_LMR: 00000210
REG_DDR_LMR: 00000310
REG_DDR_LMR: 00000110
REG_DDR_LMR, MR0: 00f73011
T31_0x5: 00000007
T31_0x15: 0000000c
T31_0x4: 00000000
T31_0x14: 00000002
INNO_TRAINING_CTRL 1: 00000000
INNO_TRAINING_CTRL 2: 000000a1
T31_cc: 00000003
INNO_TRAINING_CTRL 3: 000000a0
T31_118: 0000003c
T31_158: 0000003c
T31_190: 0000001e
T31_194: 0000001c
jz-04 : 0x00000051
jz-08 : 0x000000a0
jz-28 : 0x00000024
DDR PHY init OK
INNO_DQ_WIDTH :00000003
INNO_PLL_FBDIV :00000014
INNO_PLL_PDIV :00000005
INNO_MEM_CFG :00000051
INNO_PLL_CTRL :00000018
INNO_CHANNEL_EN :0000000d
INNO_CWL :00000006
INNO_CL :00000007
DDR Controller init
DDRC_STATUS 0x80000001
DDRC_CFG 0x0aa88a42
DDRC_CTRL 0x0000011c
DDRC_LMR 0x00400008
DDRC_DLP 0x00000000
DDRC_TIMING1 0x050f0a06
DDRC_TIMING2 0x021c0a07
DDRC_TIMING3 0x200a0722
DDRC_TIMING4 0x26240031
DDRC_TIMING5 0xff060405
DDRC_TIMING6 0x321c0505
DDRC_REFCNT 0x00910503
DDRC_MMAP0 0x000020f8
DDRC_MMAP1 0x00002800
DDRC_REMAP1 0x030e0d0c
DDRC_REMAP2 0x07060504
DDRC_REMAP3 0x0b0a0908
DDRC_REMAP4 0x0f020100
DDRC_REMAP5 0x13121110
DDRC_AUTOSR_EN 0x00000000
sdram init finished
SDRAM init ok
board_init_r
image entry point: 0x80100000
U-Boot 2013.07 (Jun 02 2020 - 18:53:44)
Board: ISVP (Ingenic XBurst T31 SoC)
DRAM: 128 MiB
Top of RAM usable for U-Boot at: 84000000
Reserving 435k for U-Boot at: 83f90000
Reserving 32772k for malloc() at: 81f8f000
Reserving 32 Bytes for Board Info at: 81f8efe0
Reserving 124 Bytes for Global Data at: 81f8ef64
Reserving 128k for boot params() at: 81f6ef64
Stack Pointer at: 81f6ef48
Now running in RAM - U-Boot at: 83f90000
MMC: msc: 0
the manufacturer 1c
SF: Detected EN25QH128A
*** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
misc_init_r before change the wifi_enable_gpio
gpio_request lable = wifi_enable_gpio gpio = 57
misc_init_r after gpio_request the wifi_enable_gpio ret is 57
misc_init_r after change the wifi_enable_gpio ret is 0
misc_init_r before change the yellow_gpio
gpio_request lable = yellow_gpio gpio = 38
misc_init_r after gpio_request the yellow_gpio ret is 38
misc_init_r after change the yellow_gpio ret is 0
misc_init_r before change the blue_gpio
gpio_request lable = blue_gpio gpio = 39
misc_init_r after gpio_request the blue_gpio ret is 39
misc_init_r after change the blue_gpio ret is 1
gpio_request lable = night_gpio gpio = 49
misc_init_r after gpio_request the night_gpio ret is 49
misc_init_r after change the night_gpio ret is 0
gpio_request lable = USB_able_gpio gpio = 47
misc_init_r after gpio_request the USB_able_gpio ret is 47
misc_init_r after change the USB_able_gpio ret is 1
gpio_request lable = SPK_able_gpio gpio = 63
misc_init_r after gpio_request the SPK_able_gpio ret is 63
misc_init_r after change the SPK_able_gpio ret is 0
gpio_request lable = TF_en_gpio gpio = 50
misc_init_r after gpio_request the TF_en_gpio ret is 50
misc_init_r after change the TF_en_gpio ret is 0
gpio_request lable = TF_cd_gpio gpio = 59
misc_init_r after gpio_request the TF_cd_gpio ret is 59
misc_init_r after change the TF_cd_gpio ret is 0
gpio_request lable = SD_able_gpio gpio = 48
misc_init_r after gpio_request the SD_able_gpio ret is 48
misc_init_r after change the SD_able_gpio ret is 0
misc_init_r before change the wifi_enable_gpio
gpio_request lable = wifi_enable_gpio gpio = 57
misc_init_r after gpio_request the wifi_enable_gpio ret is 57
misc_init_r after change the wifi_enable_gpio ret is 1
Hit any key to stop autoboot: 0
Interface: MMC
Device 0: Vendor: Man 000003 Snr 8d058b00 Rev: 0.13 Prod: SU32G�
Type: Removable Hard Disk
Capacity: 30436.5 MB = 29.7 GB (62333952 x 512)
Filesystem: FAT32 "BOOT "
file_fat_detectfs OK
reading factory_t31_ZMC6tiIDQN
reading factory_t31_ZMC6tiIDQN
## Booting kernel from Legacy Image at 84000000 ...
Image Name: Linux-3.10.14__isvp_swan_1.0__
Image Type: MIPS Linux Kernel Image (lzma compressed)
Data Size: 1818429 Bytes = 1.7 MiB
Load Address: 80010000
Entry Point: 803f58b0
Verifying Checksum ... OK
Uncompressing Kernel Image ... OK
Starting kernel ...
[ 0.000000] Initializing cgroup subsys cpu
[ 0.000000] Initializing cgroup subsys cpuacct
[ 0.000000] Linux version 3.10.14__isvp_swan_1.0__ (b@amuel) (gcc version 4.7.2 (Ingenic r2.3.3 2016.12) ) #19 PREEMPT Mon Nov 2 22:10:12 CET 2020
[ 0.000000] bootconsole [early0] enabled
[ 0.000000] CPU0 RESET ERROR PC:80216380
[ 0.000000] [<80216380>] __delay+0x0/0x10
[ 0.000000] CPU0 revision is: 00d00100 (Ingenic Xburst)
[ 0.000000] FPU revision is: 00b70000
[ 0.000000] CCLK:1392MHz L2CLK:696Mhz H0CLK:200MHz H2CLK:200Mhz PCLK:100Mhz
[ 0.000000] Determined physical RAM map:
[ 0.000000] memory: 00520000 @ 00010000 (usable)
[ 0.000000] memory: 00030000 @ 00530000 (usable after init)
[ 0.000000] User-defined physical RAM map:
[ 0.000000] memory: 05000000 @ 00000000 (usable)
[ 0.000000] Zone ranges:
[ 0.000000] Normal [mem 0x00000000-0x04ffffff]
[ 0.000000] Movable zone start for each node
[ 0.000000] Early memory node ranges
[ 0.000000] node 0: [mem 0x00000000-0x04ffffff]
[ 0.000000] Primary instruction cache 32kB, 8-way, VIPT, linesize 32 bytes.
[ 0.000000] Primary data cache 32kB, 8-way, VIPT, no aliases, linesize 32 bytes
[ 0.000000] pls check processor_id[0x00d00100],sc_jz not support!
[ 0.000000] MIPS secondary cache 128kB, 8-way, linesize 32 bytes.
[ 0.000000] Built 1 zonelists in Zone order, mobility grouping off. Total pages: 20320
[ 0.000000] Kernel command line: console=ttyS1,115200n8 mem=80M@0x0 rmem=48M@0x5000000 init=/linuxrc root=/dev/mmcblk0p2 rdinit=/linuxrc rw mtdparts=jz_sfc:256K(boot),1984K(kernel),3904K(rootfs),3904K(app),1984K(kback),3904K(aback),384K(cfg),64K(para) rootdelay=5
[ 0.000000] PID hash table entries: 512 (order: -1, 2048 bytes)
[ 0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
[ 0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
[ 0.000000] Memory: 74852k/81920k available (4026k kernel code, 7068k reserved, 1221k data, 192k init, 0k highmem)
[ 0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[ 0.000000] Preemptible hierarchical RCU implementation.
[ 0.000000] NR_IRQS:358
[ 0.000000] clockevents_config_and_register success.
[ 0.000015] Calibrating delay loop... 1391.00 BogoMIPS (lpj=6955008)
[ 0.087831] pid_max: default: 32768 minimum: 301
[ 0.092688] Mount-cache hash table entries: 512
[ 0.097597] Initializing cgroup subsys debug
[ 0.101852] Initializing cgroup subsys freezer
[ 0.108031] regulator-dummy: no parameters
[ 0.112220] NET: Registered protocol family 16
[ 0.126626] bio: create slab <bio-0> at 0
[ 0.132102] jz-dma jz-dma: JZ SoC DMA initialized
[ 0.137089] usbcore: registered new interface driver usbfs
[ 0.142600] usbcore: registered new interface driver hub
[ 0.148072] usbcore: registered new device driver usb
[ 0.153226] (null): set:249 hold:250 dev=100000000 h=500 l=500
[ 0.159349] media: Linux media interface: v0.10
[ 0.163886] Linux video capture interface: v2.00
[ 0.169914] Switching to clocksource jz_clocksource
[ 0.175124] cfg80211: Calling CRDA to update world regulatory domain
[ 0.181737] jz-dwc2 jz-dwc2: cgu clk gate get error
[ 0.186640] DWC IN OTG MODE
[ 0.190056] dwc2 dwc2: Keep PHY ON
[ 0.193422] dwc2 dwc2: Using Buffer DMA mode
[ 0.197770] dwc2 dwc2: Core Release: 3.00a
[ 0.201930] dwc2 dwc2: DesignWare USB2.0 High-Speed Host Controller
[ 0.208278] dwc2 dwc2: new USB bus registered, assigned bus number 1
[ 0.215336] hub 1-0:1.0: USB hub found
[ 0.219066] hub 1-0:1.0: 1 port detected
[ 0.223116] dwc2 dwc2: DWC2 Host Initialized
[ 0.227566] NET: Registered protocol family 2
[ 0.232299] TCP established hash table entries: 1024 (order: 1, 8192 bytes)
[ 0.239346] TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
[ 0.245753] TCP: Hash tables configured (established 1024 bind 1024)
[ 0.252220] TCP: reno registered
[ 0.255465] UDP hash table entries: 256 (order: 0, 4096 bytes)
[ 0.261371] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[ 0.267921] NET: Registered protocol family 1
[ 0.272494] RPC: Registered named UNIX socket transport module.
[ 0.278474] RPC: Registered udp transport module.
[ 0.283188] RPC: Registered tcp transport module.
[ 0.287966] RPC: Registered tcp NFSv4.1 backchannel transport module.
[ 0.294780] freq_udelay_jiffys[0].max_num = 10
[ 0.299234] cpufreq udelay loops_per_jiffy
[ 0.303626] dwc2 dwc2: ID PIN CHANGED!
[ 0.307471] 12000 59956 59956
[ 0.310682] 24000 119913 119913
[ 0.314125] 60000 299784 299784
[ 0.317656] 120000 599569 599569
[ 0.321108] 200000 999282 999282
[ 0.324639] 300000 1498924 1498924
[ 0.328423] 600000 2997848 2997848
[ 0.332056] 792000 3957159 3957159
[ 0.335781] 1008000 5036385 5036385
[ 0.339561] 1200000 5995696 5995696
[ 0.347729] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[ 0.354243] jffs2: version 2.2. � 2001-2006 Red Hat, Inc.
[ 0.360083] msgmni has been set to 146
[ 0.364754] io scheduler noop registered
[ 0.368760] io scheduler cfq registered (default)
[ 0.374574] jz-uart.1: ttyS1 at MMIO 0x10031000 (irq = 58) is a uart1
[ 0.382173] console [ttyS1] enabled, bootconsole disabled
[ 0.382173] console [ttyS1] enabled, bootconsole disabled
[ 0.395997] brd: module loaded
[ 0.400505] loop: module loaded
[ 0.404177] zram: Created 2 device(s) ...
[ 0.408444] wifi regulator missing
[ 0.412024] logger: created 256K log 'log_main'
[ 0.417241] jz TCU driver register completed
[ 0.421941] the id code = 1c7018, the flash name is EN25QH128A
[ 0.428009] JZ SFC Controller for SFC channel 0 driver register
[ 0.434134] 8 cmdlinepart partitions found on MTD device jz_sfc
[ 0.440248] Creating 8 MTD partitions on "jz_sfc":
[ 0.445216] 0x000000000000-0x000000040000 : "boot"
[ 0.450542] 0x000000040000-0x000000230000 : "kernel"
[ 0.456038] 0x000000230000-0x000000600000 : "rootfs"
[ 0.461512] 0x000000600000-0x0000009d0000 : "app"
[ 0.466777] 0x0000009d0000-0x000000bc0000 : "kback"
[ 0.472158] 0x000000bc0000-0x000000f90000 : "aback"
[ 0.477601] 0x000000f90000-0x000000ff0000 : "cfg"
[ 0.482808] 0x000000ff0000-0x000001000000 : "para"
[ 0.488164] SPI NOR MTD LOAD OK
[ 0.491454] tun: Universal TUN/TAP device driver, 1.6
[ 0.496692] tun: (C) 1999-2004 Max Krasnyansky <maxk@qualcomm.com>
[ 0.503151] usbcore: registered new interface driver zd1201
[ 0.509132] wait stable.[289][cgu_msc0]
[ 0.513098] jzmmc_v1.2 jzmmc_v1.2.0: vmmc regulator missing
[ 0.524823] jzmmc_v1.2 jzmmc_v1.2.0: card inserted, state=0
[ 0.554817] jzmmc_v1.2 jzmmc_v1.2.0: register success!
[ 0.560161] jzmmc_v1.2 jzmmc_v1.2.1: vmmc regulator missing
[ 0.604892] jzmmc_v1.2 jzmmc_v1.2.1: register success!
[ 0.610422] TCP: cubic registered
[ 0.613842] NET: Registered protocol family 17
[ 0.620130] input: gpio-keys as /devices/platform/gpio-keys/input/input0
[ 0.627243] drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
[ 0.635022] Waiting 5sec before mounting root device...
[ 1.565435] mmc0: new SDHC card at address e624
[ 1.570322] mmcblk0: mmc0:e624 SU32G 29.7 GiB
[ 1.579266] mmcblk0: p1 p2
[ 5.645748] EXT4-fs (mmcblk0p2): mounting ext3 file system using the ext4 subsystem
[ 5.830947] EXT4-fs (mmcblk0p2): recovery complete
[ 5.838187] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[ 5.846593] VFS: Mounted root (ext3 filesystem) on device 179:2.
[ 5.853030] Freeing unused kernel memory: 192K (80530000 - 80560000)
mdev is ok......
[ 6.664074] @@@@ tx-isp-probe ok(version H20200506a), compiler date=May 6 2020 @@@@@
[ 6.702541] exFAT: Version 1.2.9
[ 6.730102] jz_codec_register: probe() successful!
[ 7.145106] dma dma0chan24: Channel 24 have been requested.(phy id 7,type 0x06 desc a25fb000)
[ 7.154204] dma dma0chan25: Channel 25 have been requested.(phy id 6,type 0x06 desc a2635000)
[ 7.163391] dma dma0chan26: Channel 26 have been requested.(phy id 5,type 0x04 desc a1471000)
[ 7.237385] Error: Driver 'tcu_chn0' is already registered, aborting...
[ 7.244213] The version of PWM driver is H20180309a
[ 7.254724] request pwm channel 0 successfully
[ 7.261004] pwm-jz pwm-jz: jz_pwm_probe register ok !
[ 7.495417] RTL871X: module init start
[ 7.499290] RTL871X: rtl8189ftv v4.3.24.7_21113.20170208.nova.1.02
[ 7.507035] RTL871X: build time: Apr 17 2020 15:07:08
[ 7.512260] wlan power on
[ 7.535128] RTL871X: module init ret=0
[ 7.580743] mmc1: card claims to support voltages below the defined range. These will be ignored.
[ 7.601052] mmc1: new SDIO card at address 0001
[ 7.608543] RTL871X: ++++++++rtw_drv_init: vendor=0x024c device=0xf179 class=0x07
[ 7.649962] RTL871X: HW EFUSE
[ 7.653531] RTL871X: hal_com_config_channel_plan chplan:0x20
[ 7.751571] RTL871X: rtw_regsty_chk_target_tx_power_valid return _FALSE for band:0, path:0, rs:0, t:-1
[ 7.763058] RTL871X: rtw_ndev_init(wlan0) if1 mac_addr=b4:c9:b9:03:7b:37
udhcpc: started, v1.29.0.git
udhcpc: sending discover
[ 10.211818] RTL871X: rtw_set_802_11_connect(wlan0) fw_state=0x00000008
udhcpc: sending discover
udhcpc: sending discover
udhcpc: no lease, forking to background
[ 17.965322] RTL871X: rtw_set_802_11_connect(wlan0) fw_state=0x00000008
[ 18.125840] RTL871X: start auth
[ 18.132229] RTL871X: auth success, start assoc
[ 18.140284] RTL871X: assoc success
[ 18.143925] RTL871X: recv eapol packet
[ 18.160659] RTL871X: send eapol packet
[ 18.197572] RTL871X: recv eapol packet
[ 18.203028] RTL871X: send eapol packet
[ 18.210719] RTL871X: set pairwise key camid:4, addr:f8:1a:67:5a:71:67, kid:0, type:AES
[ 18.222102] RTL871X: set group key camid:5, addr:f8:1a:67:5a:71:67, kid:1, type:AES
/etc/init.d/rcS: line 138: /etc/autostart/*: not found
azarton-c1-t31-sdcard login: root
Jan 1 02:00:24 login[185]: root login on 'console'
[root@azarton-c1-t31-sdcard:~]# ping www.google.at
PING www.google.at (216.58.214.227): 56 data bytes
64 bytes from 216.58.214.227: seq=0 ttl=117 time=20.117 ms
64 bytes from 216.58.214.227: seq=1 ttl=117 time=20.791 ms
^C
--- www.google.at ping statistics ---
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max = 20.117/20.454/20.791 ms
[root@azarton-c1-t31-sdcard:~]# nets[root@azarton-c1-t31-sdcard:~]# netstat -ln
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:21 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:443 0.0.0.0:* LISTEN
netstat: /proc/net/tcp6: No such file or directory
netstat: /proc/net/udp6: No such file or directory
netstat: /proc/net/raw6: No such file or directory
Active UNIX domain sockets (only servers)
Proto RefCnt Flags Type State I-Node Path
[root@azarton-c1-t31-sdcard:~]# uname -a
Linux azarton-c1-t31-sdcard 3.10.14__isvp_swan_1.0__ #19 PREEMPT Mon Nov 2 22:10:12 CET 2020 mips GNU/Linux
[root@azarton-c1-t31-sdcard:~]# uptime
00:47:32 up 1 min, 1 users, load average: 0.07, 0.02, 0.01
[root@azarton-c1-t31-sdcard:~]# cat /et[root@azarton-c1-t31-sdcard:~]# cat /sys[root@azarton-c1-t31-sdcard:~]# cat /pro[root@azarton-c1-t31-sdcard:~]# cat /proc/cpu[root@azarton-c1-t31-sdcard:~]# cat /proc/cpuin[root@azarton-c1-t31-sdcard:~]# cat /proc/cpuinfo
system type : Swan
machine : Unknown
processor : 0
cpu model : Ingenic Xburst V0.0 FPU V0.0
BogoMIPS : 1391.00
wait instruction : yes
microsecond timers : no
tlb_entries : 32
extra interrupt vector : yes
hardware watchpoint : yes, count: 1, address/irw mask: [0x0fff]
isa : mips32r1
ASEs implemented :
shadow register sets : 1
kscratch registers : 7
core : 0
VCED exceptions : not available
VCEI exceptions : not available
Hardware : isvp
Serial : 00000000 00000000 00000000 00000000
[root@azarton-c1-t31-sdcard:~]# mount
rootfs on / type rootfs (rw)
/dev/root on / type ext3 (rw,relatime,data=ordered)
tmpfs on /dev type tmpfs (rw,relatime)
proc on /proc type proc (rw,relatime)
devpts on /dev/pts type devpts (rw,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /tmp type tmpfs (rw,relatime)
tmpfs on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
sysfs on /sys type sysfs (rw,relatime)
media on /media type tmpfs (rw,relatime)
/dev/mtdblock3 on /system type squashfs (ro,relatime)
/dev/mtdblock2 on /mtdrootfs type squashfs (ro,relatime)
/dev/mtdblock6 on /configs type jffs2 (rw,relatime)