Hi,
I developed a board with an iMX28 processor and for mass production I need mfgtool to program the memory. Because it's for a custom board, I generate a new updater_ivt.sb
When I plug the board to the computer, mfgtool see the device.
When I press start, the firmware is download to the board and on the console, I see the boot log :
Linux version 2.6.35.3-g6475bb9-dirty (victorien@BENNEVIS) (gcc version 4.3.3 (4
CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=00053177
CPU: VIVT data cache, VIVT instruction cache
Machine: Ophrys Systemes Misu board rev002
Memory policy: ECC disabled, Data cache writeback
On node 0 totalpages: 16384
free_area_init_node: node 0, pgdat c0324af0, node_mem_map c036b000
DMA zone: 32 pages used for memmap
DMA zone: 0 pages reserved
DMA zone: 4064 pages, LIFO batch:0
Normal zone: 96 pages used for memmap
Normal zone: 12192 pages, LIFO batch:1
Built 1 zonelists in Zone order, mobility grouping on. Total pages: 16256
Kernel command line: console=ttyAM0,115200
PID hash table entries: 256 (order: -2, 1024 bytes)
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
Memory: 64MB = 64MB total
Memory: 57376k/57376k available, 8160k reserved, 0K highmem
Virtual kernel memory layout:
vector : 0xffff0000 - 0xffff1000 ( 4 kB)
fixmap : 0xfff00000 - 0xfffe0000 ( 896 kB)
DMA : 0xfde00000 - 0xffe00000 ( 32 MB)
vmalloc : 0xc4800000 - 0xf0000000 ( 696 MB)
lowmem : 0xc0000000 - 0xc4000000 ( 64 MB)
modules : 0xbf000000 - 0xc0000000 ( 16 MB)
.init : 0xc0008000 - 0xc0027000 ( 124 kB)
.text : 0xc0027000 - 0xc0305000 (2936 kB)
.data : 0xc0306000 - 0xc03254e0 ( 126 kB)
SLUB: Genslabs=11, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
Hierarchical RCU implementation.
RCU-based detection of stalled CPUs is disabled.
Verbose stalled-CPUs detection is disabled.
NR_IRQS:288
Console: colour dummy device 80x30
console [ttyAM0] enabled
Calibrating delay loop... 226.09 BogoMIPS (lpj=1130496)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
regulator: core version 0.5
NET: Registered protocol family 16
regulator: vddd: 800 <--> 1575 mV at 1500 mV fast normal
regulator: vdddbo: 800 <--> 1575 mV fast normal
regulator: vdda: 1500 <--> 2275 mV at 1800 mV fast normal
vddio = 3380000, val=10
regulator: vddio: 2880 <--> 3680 mV at 3380 mV fast normal
regulator: overall_current: fast normal
regulator: vbus5v:
regulator: mxs-duart-1: fast normal
regulator: mxs-bl-1: fast normal
regulator: mxs-i2c-1: fast normal
regulator: mmc_ssp-1: fast normal
regulator: mmc_ssp-2: fast normal
regulator: charger-1: fast normal
regulator: power-test-1: fast normal
regulator: cpufreq-1: fast normal
i.MX IRAM pool: 124 KB@0xc4820000
usb DR wakeup device is registered
IMX usb wakeup probe
the wakeup pdata is 0xc030e514
audit: cannot initialize inotify handle
bio: create slab <bio-0> at 0
SCSI subsystem initialized
Switching to clocksource mxs clock source
Trying to unpack rootfs image as initramfs...
Freeing initrd memory: 4096K
Bus freq driver module loaded
mxs_cpu_init: cpufreq init finished
audit: initializing netlink socket (disabled)
type=2000 audit(1.340:1): initialized
JFFS2 version 2.2. (NAND) © 2001-2006 Red Hat, Inc.
msgmni has been set to 120
Block layer SCSI generic (bsg) driver version 0.4 loaded (major 253)
io scheduler noop registered (default)
Console: switching to colour frame buffer device 100x30
mxs-duart.0: ttyAM0 at MMIO 0x80074000 (irq = 47) is a DebugUART
mxs-auart.0: ttySP0 at MMIO 0x8006a000 (irq = 112) is a mxs-auart.0
Found APPUART 3.1.0
mxs-auart.1: ttySP1 at MMIO 0x8006c000 (irq = 113) is a mxs-auart.1
Found APPUART 3.1.0
mxs-auart.2: ttySP2 at MMIO 0x8006e000 (irq = 114) is a mxs-auart.2
Found APPUART 3.1.0
mxs-auart.3: ttySP3 at MMIO 0x80070000 (irq = 115) is a mxs-auart.3
Found APPUART 3.1.0
mxs-auart.4: ttySP4 at MMIO 0x80072000 (irq = 116) is a mxs-auart.4
Found APPUART 3.1.0
brd: module loaded
loop: module loaded
Loading iSCSI transport class v2.0-870.
i.MX GPMI NFC
NFC: Version 1, 8-chip GPMI and BCH
gpmi-nfc: probe of gpmi-nfc.0 failed with error 1
ARC USBOTG Device Controller driver (1 August 2005)
check_parameters:UTP settings are in place now, overriding defaults
g_file_storage gadget: File-backed Storage Gadget, version: 20 November 2008
g_file_storage gadget: Number of LUNs=1
dr_controller_run: udc out low power mode
fsl-usb2-udc: bind to driver g_file_storage
mice: PS/2 mouse device common for all mice
input: mxs-kbd as /devices/platform/mxs-kbd.0/input/input0
input: MXS touchscreen as /devices/virtual/input/input1
MXS RTC driver v1.0 hardware v2.3.0
mxs-rtc mxs-rtc.0: rtc core: registered mxs-rtc as rtc0
mxs-mmc: MXS SSP Controller MMC Interface driver
mxs-mmc mxs-mmc.0: mmc0: MXS SSP MMC DMAIRQ 82 ERRIRQ 96
Registered led device: led1:red
Registered led device: led2:green
mxs-rtc mxs-rtc.0: setting system clock to 1970-01-01 00:00:33 UTC (33)
Freeing init memory: 124K
mmc0: new high speed SDHC card at address 0002
mmcblk0: mmc0:0002 00000 7.41 GiB
mmcblk0: p1
charger------ ddi_bc_gBrokenReason=4
and at the and, the kernel launch usb gadget module :
root@freescale /$ g_file_storage gadget: high speed config #1
At this moment, it seem correct. but when mfgtool execute the first push command, I have this message on mfgtool
Operation is not completed.,failed to run command: type="push" body="mknod block,mmcblk0,/dev/mmcblk0,block" file="" timeout="" onERROR="" text=""
and this message on board console
Unable to handle kernel NULL pointer dereference at virtual address 00000009
pgd = c0004000
[00000009] *pgd=00000000
Internal error: Oops: 17 [#1]
last sysfs file:
CPU: 0 Not tainted (2.6.35.3-g6475bb9-dirty #1051)
PC is at do_scsi_command+0x5bc/0x1aa8
LR is at do_scsi_command+0x5bc/0x1aa8
pc : [<c0222850>] lr : [<c0222850>] psr: 60000013
sp : c2c05e88 ip : c2c05e88 fp : c2c05f04
r10: c03692ac r9 : c3c32e00 r8 : 0000c036
r7 : 00c03692 r6 : 00000000 r5 : c2c088a0 r4 : c03692d0
r3 : c03692d0 r2 : 00000001 r1 : 00000000 r0 : c03692bc
Flags: nZCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment kernel
Control: 0005317f Table: 42c7c000 DAC: 00000017
Process file-storage-ga (pid: 885, stack limit = 0xc2c04270)
Stack: (0xc2c05e88 to 0xc2c06000)
5e80: c2c05eac c2c05e98 c2c2e000 c0309d70 c2c05ec4 c2c05ea8
5ea0: 000000c0 c3c32e78 00000000 c2c184c0 c03692bc c2c2e000 c2c05eec 00000000
5ec0: c2c088a0 c0055b0c c2c05ec8 c2c05ec8 00000200 c3c32e78 c3c32e40 c339c000
5ee0: c3c32e00 00000200 c3c32e78 c3c32e40 c3c32e58 c2c04000 c2c05fc4 c2c05f08
5f00: c02243c8 c02222a4 c3c32e7c c2c05f18 c003d344 c3c32eb0 0000000a 00000000
5f20: 00000000 00000000 00000000 c0310028 c3c20038 c0310058 c3c20030 c0310058
5f40: c2c05f64 c2c05f50 c3c2201c c2c088a0 00000017 c0318474 c2c04000 00000000
5f60: c2c05f84 c2c05f70 c0318474 c3c20000 c2c05f9c c2c05f80 c003df70 c0070270
5f80: 00000000 c2c088a0 c3c20000 c0318474 c2c05fc4 c2c05fa0 c027a904 c2c05fcc
5fa0: c3c23ed0 c3c32e00 c0223d3c 00000000 00000000 00000000 c2c05ff4 c2c05fc8
5fc0: c00556d8 c0223d4c 00000000 00000000 c2c05fd0 c2c05fd0 c3c23ed0 c0055650
5fe0: c0044420 00000013 00000000 c2c05ff8 c0044420 c0055660 00000000 00000000
Backtrace:
[<c0222294>] (do_scsi_command+0x0/0x1aa8) from [<c02243c8>] (fsg_main_thread+0x)
[<c0223d3c>] (fsg_main_thread+0x0/0xa24) from [<c00556d8>] (kthread+0x88/0x90)
[<c0055650>] (kthread+0x0/0x90) from [<c0044420>] (do_exit+0x0/0x5e8)
r7:00000013 r6:c0044420 r5:c0055650 r4:c3c23ed0
Code: 11a06003 03a06000 e51b0054 eb0161cd (e5d62009)
---[ end trace c4cc3e0f4feb6a88 ]---
I suppose ot miss something in ramrootfs or in kernel but I can't find what. Is there someone who have an idea ?
Best regards
Now I can generate updater_ivt.sb with ltib and it works on my board with mfgtools.
The download and programming work few time. But now the process always fails after the boot and the board is seeing as "Linux file storage gadget USB device" on mfgtools.
How resolve this problem ?
Hi victorien
please create new Community thread.
~igor
I installed ltib on a virtual machine with ubuntu 12.04 (I don't find how to do with newer version) and now I can compile with ltib.
I genrerate initramfs and use it on my usual toolchain to generate updater_ivt.sb (with my own zImage and bootlet). Unfortunately, It doesn't work and I have this log when I execute mfgtool :
0x8020a01d HTLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLC
PowerPrep start initialize power... Battery Voltage = 1.86V No valid battery detected. Power supply on 5V only LLLLCOct 30 201415:55:01 FRAC 0x92925552 memory type is DDR2 Wait for ddr ready 1 - 1130 power 0x00820616 Frac 0x92925552 start change cpu freq hbus 0x00000003 cpu 0x00010001 start test external memory access ddr2 0x40000000 finish simple test LLLLLLLFLCLFLLJUncompressing Linux... done, booting the kernel. Linux version 2.6.35.3-g6475bb9-dirty (victorien@BENNEVIS) (gcc version 4.3.3 (4
CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=00053177 CPU: VIVT data cache, VIVT instruction cache Machine: Ophrys Systemes Misu board rev002 Memory policy: ECC disabled, Data cache writeback Built 1 zonelists in Zone order, mobility grouping on. Total pages: 16256 Kernel command line: console=ttyAM0,115200 PID hash table entries: 256 (order: -2, 1024 bytes) Dentry cache hash table entries: 8192 (order: 3, 32768 bytes) Inode-cache hash table entries: 4096 (order: 2, 16384 bytes) Memory: 64MB = 64MB total Memory: 55328k/55328k available, 10208k reserved, 0K highmem Virtual kernel memory layout: vector : 0xffff0000 - 0xffff1000 ( 4 kB) fixmap : 0xfff00000 - 0xfffe0000 ( 896 kB) DMA : 0xfde00000 - 0xffe00000 ( 32 MB) vmalloc : 0xc4800000 - 0xf0000000 ( 696 MB) lowmem : 0xc0000000 - 0xc4000000 ( 64 MB) modules : 0xbf000000 - 0xc0000000 ( 16 MB) .init : 0xc0008000 - 0xc0027000 ( 124 kB) .text : 0xc0027000 - 0xc0305000 (2936 kB) .data : 0xc0306000 - 0xc0325580 ( 126 kB) SLUB: Genslabs=11, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1 Hierarchical RCU implementation. RCU-based detection of stalled CPUs is disabled. Verbose stalled-CPUs detection is disabled. NR_IRQS:288 Console: colour dummy device 80x30 console [ttyAM0] enabled Calibrating delay loop... 226.09 BogoMIPS (lpj=1130496) pid_max: default: 32768 minimum: 301 Mount-cache hash table entries: 512 CPU: Testing write buffer coherency: ok regulator: core version 0.5 NET: Registered protocol family 16 regulator: vddd: 800 <--> 1575 mV at 1500 mV fast normal regulator: vdddbo: 800 <--> 1575 mV fast normal regulator: vdda: 1500 <--> 2275 mV at 1800 mV fast normal vddio = 3380000, val=10 regulator: vddio: 2880 <--> 3680 mV at 3380 mV fast normal regulator: overall_current: fast normal regulator: vbus5v: regulator: mxs-duart-1: fast normal regulator: mxs-bl-1: fast normal regulator: mxs-i2c-1: fast normal regulator: mmc_ssp-1: fast normal regulator: mmc_ssp-2: fast normal regulator: charger-1: fast normal regulator: power-test-1: fast normal regulator: cpufreq-1: fast normal i.MX IRAM pool: 124 KB@0xc4820000 usb DR wakeup device is registered IMX usb wakeup probe audit: cannot initialize inotify handle bio: create slab <bio-0> at 0 SCSI subsystem initialized Switching to clocksource mxs clock source Trying to unpack rootfs image as initramfs... Freeing initrd memory: 6144K Bus freq driver module loaded mxs_cpu_init: cpufreq init finished audit: initializing netlink socket (disabled) type=2000 audit(2.170:1): initialized JFFS2 version 2.2. (NAND) �© 2001-2006 Red Hat, Inc. msgmni has been set to 120 Block layer SCSI generic (bsg) driver version 0.4 loaded (major 253) io scheduler noop registered (default) Console: switching to colour frame buffer device 100x30 mxs-duart.0: ttyAM0 at MMIO 0x80074000 (irq = 47) is a DebugUART mxs-auart.0: ttySP0 at MMIO 0x8006a000 (irq = 112) is a mxs-auart.0 Found APPUART 3.1.0 mxs-auart.1: ttySP1 at MMIO 0x8006c000 (irq = 113) is a mxs-auart.1 Found APPUART 3.1.0 mxs-auart.2: ttySP2 at MMIO 0x8006e000 (irq = 114) is a mxs-auart.2 Found APPUART 3.1.0 mxs-auart.3: ttySP3 at MMIO 0x80070000 (irq = 115) is a mxs-auart.3 Found APPUART 3.1.0 mxs-auart.4: ttySP4 at MMIO 0x80072000 (irq = 116) is a mxs-auart.4 Found APPUART 3.1.0 brd: module loaded loop: module loaded Loading iSCSI transport class v2.0-870. i.MX GPMI NFC NFC: Version 1, 8-chip GPMI and BCH gpmi-nfc: probe of gpmi-nfc.0 failed with error 1 ARC USBOTG Device Controller driver (1 August 2005) check_parameters:UTP settings are in place now, overriding defaults g_file_storage gadget: File-backed Storage Gadget, version: 20 November 2008
g_file_storage gadget: Number of LUNs=1 fsl-usb2-udc: bind to driver g_file_storage mice: PS/2 mouse device common for all mice input: matrix-keypad as /devices/platform/matrix-keypad/input/input0 input: MXS touchscreen as /devices/virtual/input/input1 MXS RTC driver v1.0 hardware v2.3.0 mxs-rtc mxs-rtc.0: rtc core: registered mxs-rtc as rtc0 mxs-mmc: MXS SSP Controller MMC Interface driver mxs-mmc mxs-mmc.0: mmc0: MXS SSP MMC DMAIRQ 82 ERRIRQ 96 mmc0: new high speed SDHC card at address 0002 charger------ ddi_bc_gBrokenReason=4 mxs-rtc mxs-rtc.0: setting system clock to 1970-01-01 00:02:34 UTC (154) Freeing init memory: 124K mmcblk0: mmc0:0002 00000 7.41 GiB starting pid 1694, tty '': '/etc/rc.d/rcS' p1 Mounting /proc and /sys mount: wrong fs type, bad option, bad superblock on tmpfs, missing codepage or helper program, or other error In some cases useful info is found in syslog - try dmesg | tail or so mknod: /dev/console: File exists mknod: /dev/null: File exists Starting the hotplug events dispatcher udevd udevd[1713]: init_udevd_socket: error getting socket: Address family not supporl
error initializing udevd socket udevd[1713]: main: error initializing udevd socket Synthesizing initial hotplug events g_file_storage gadget: high speed config #1 Setting the hostname to freescale Mounting filesystems mount: wrong fs type, bad option, bad superblock on shm, missing codepage or helper program, or other error In some cases useful info is found in syslog - try dmesg | tail or so mount: wrong fs type, bad option, bad superblock on rwfs, missing codepage or helper program, or other error In some cases useful info is found in syslog - try dmesg | tail or so mount: sysfs already mounted or /sys busy mount: according to mtab, /sys is already mounted on /sys mount: mount point /proc/bus/usb does not exist starting pid 1740, tty '': '/etc/rc.d/rc_gpu.S' can't run '/etc/rc.d/rc_gpu.S': No such file or directory starting pid 1741, tty '': '/sbin/getty -L ttyAM0 115200 vt100' process '/sbin/getty -L ttyAM0 115200 vt100' (pid 1741) exited. Scheduling for .
starting pid 1742, tty '': '/sbin/getty -L ttyAM0 115200 vt100' process '/sbin/getty -L ttyAM0 115200 vt100' (pid 1742) exited. Scheduling for .
starting pid 1743, tty '': '/sbin/getty -L ttyAM0 115200 vt100'
I compile linux zImage with the same config as ltib but I think it's not enough. How can I create my custom board on ltib ?
Please check documents below talking about some common issues met when
using i.mx28. Hope this will be useful for you.
Application note sharing: Issues often met in i.MX28 application
Thanks but I don't find any information to resolve my problem.
In my previous test, I just generate initramfs with ltib and I think it's necessary to generate the bootloader and the kernel with ltib. Unfortunatly, I don't find how to define a custom board on ltib. Is there a procedure to do that ?
I do not think that such kind of document is available,
in ltib you can select drivers which are used on your board and
change bootlets. I would suggest to look below
http://www.jann.cc/2013/08/31/porting_linux_to_a_new_board.html
Hi victorien
you can look at latest L2.6.35_1.1.0 BSP patches:
L2.6.35_1.1.1_UPDATER_PATCH_UP :
The purpose of this patch release is Fix the updater.sb boot issue in the i.MX28 Linux BSP L2.6.35_1.1.0 release
I.MX28_MFG_TOOL_LINUX : Tool and documentation for downloading i.MX28 image during manufacturing.
Size (K): 33397 Format: gz Rev #: L2.6.35_1.1.0 Modified: 2/22/2013
L2.6.35_1.1.0_ER_SOURCE : i.MX28 Linux 2.6.35 Source Code Files and documentation.
Size (K): 726912 Format: gz Rev #: L2.6.35_1.1.0 Modified: 2/22/2013
Best regards
igor
Thanks for your answer. and for giving more detail :
- I don't use ltib to generate the kernel
- I use mfg tool for windows (1.6.2.048)
- I generate my own updater_ivt.sb for my board (no problem with bootlet and zImage)
- I tried the modification from the patch but it change nothing
I find a test where mfgtool works fine :
- generate updater_ivt.sb for my own board
- execute mfgtool with this file
- I see the kernel boot on the board console
- the last line of the boot is : root@freescale /$ g_file_storage gadget: high speed config #1
- after that, ont the console I did : 'enter' uuc 'enter'
- then mfgtool communicate with my board
I think that it's my initramfs.cpio.gz which is bad and don't launch uuc. Do you confirm that ? Where can I find a boot initramfs.cpio.gz ? or how can I generate it ?
Best regards
With the information that you give to me, I need LTIB. I'll try to install but but is there another way to generate this image ?
Hi victorien
I am afraid that updater for MFG Tools can be generated only with ltib.
~igor
Hi
Generate image of type initramfs.
Regards
Pt
there were initramfs fixes in latest L2.6.35_1.1.0 BSP patches: