2010-10-06 02:17:24 kernel application hanged on BF537 stampkit
Shyam sundar (INDIA)
Message: 94210
Hello world,
I am using the BF537 stamp kit.I am not able to see the kernel application executed.
This what the console displays.
U-Boot 2008.10-svn2396 (ADI-2009R1.1-rc1) (Sep 30 2010 - 18:22:32)
CPU: ADSP bf537-0.3 (Detected Rev: 0.3) (parallel flash boot)
Board: ADI BF537 stamp board
Support: blackfin.uclinux.org/
Clock: VCO: 500 MHz, Core: 500 MHz, System: 125 MHz
RAM: 64 MB
Flash: 4 MB
In: serial
Out: serial
Err: serial
Net: Blackfin EMAC
MAC: 00:E0:22:FE:61:73
Hit any key to stop autoboot: 0
bfin>tftpboot 0x1000000 vmlinux
TFTP from server X.X.X.46; our IP address is X.X.X.99
Filename 'vmlinux'.
Load address: 0x1000000
Loading: #################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#########################################################
done
Bytes transferred = 24679375 (17893cf hex)
bfin>boote
Loading phdr 0 to 0x00001000 (1322284 bytes)
Loading phdr 1 to 0x00144000 (0 bytes)
Loading phdr 2 to 0x00156334 (4938900 bytes)
Loading phdr 3 to 0x0060bfc8 (10996 bytes)
Loading phdr 4 to 0x0060eabc (192 bytes)
## Starting application at 0x00173f80 ...
QuoteReplyEditDelete
2010-10-06 02:45:28 Re: kernel application hanged on BF537 stampkit
Mike Frysinger (UNITED STATES)
Message: 94215
not a bug ... working as designed
do not boot kernel elfs. boot uImages.
QuoteReplyEditDelete
2010-10-06 07:43:55 Re: kernel application hanged on BF537 stampkit
Shyam sundar (INDIA)
Message: 94268
Thanks Mike!! The documentations said that the newer versions of uboot loaders sometimes doesnt support the elf format.
Probably that should have been the problem then !!
I used the uImage.initramfs image, but the application got stuck at
"turn off boot console early_BFuart0"
This was the console display!!
bfin> loady
## Ready for binary (ymodem) download to 0x01000000 at 57600 bps...
CModem - CRC mode, 24120(SOH)/0(STX)/0(CAN) packets, 7 retries
## Total Size = 0x002f18da = 3086554 Bytes
bfin> iminfo 0x1000000
## Checking Image at 01000000 ...
Legacy image found
Image Name: Linux-2.6.28.10-ADI-2009R1.1-svn
Created: 2010-10-06 6:33:24 UTC
Image Type: Blackfin Linux Kernel Image (gzip compressed)
Data Size: 3086490 Bytes = 2.9 MB
Load Address: 00001000
Entry Point: 00173f80
Verifying Checksum ... OK
bfin> bootm 0x1000000
## Booting kernel from Legacy Image at 01000000 ...
Image Name: Linux-2.6.28.10-ADI-2009R1.1-svn
Created: 2010-10-06 6:33:24 UTC
Image Type: Blackfin Linux Kernel Image (gzip compressed)
Data Size: 3086490 Bytes = 2.9 MB
Load Address: 00001000
Entry Point: 00173f80
Verifying Checksum ... OK
Uncompressing Kernel Image ... OK
Starting Kernel at = 00173f80
Linux version 2.6.28.10-ADI-2009R1.1-svn9124 (tcoe@tcoe-laptop) (gcc version 4.1.2 (ADI svn)) #31 Wed Oct 6 12:03:15 IST 2010
bootconsole [early_shadow0] enabled
bootconsole [early_BFuart0] enabled
early printk enabled on early_BFuart0
Board Memory: 64MB
Kernel Managed Memory: 64MB
Memory map:
fixedcode = 0x00000400-0x00000490
text = 0x00001000-0x000f3e00
rodata = 0x000f3e00-0x00143d2c
bss = 0x00144000-0x00156334
data = 0x00156334-0x00166000
stack = 0x00164000-0x00166000
init = 0x00166000-0x0060f000
available = 0x0060f000-0x03eff000
DMA Zone = 0x03f00000-0x04000000
Hardware Trace Active and Enabled
Boot Mode: 1
Blackfin support (C) 2004-2009 Analog Devices, Inc.
Compiled for ADSP-BF537 Rev 0.3
Blackfin Linux support by blackfin.uclinux.org/
Processor Speed: 500 MHz core clock and 125 MHz System Clock
NOMPU: setting up cplb tables
Instruction Cache Enabled for CPU0
Data Cache Enabled for CPU0 (write-back)
Built 1 zonelists in Zone order, mobility grouping off. Total pages: 16001
Kernel command line: root=/dev/mtdblock0 rw clkin_hz=25000000 earlyprintk=serial,uart0,57600 console=ttyBF0,57600
Configuring Blackfin Priority Driven Interrupts
PID hash table entries: 256 (order: 8, 1024 bytes)
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
Memory available: 57736k/65536k RAM, (4772k init code, 971k kernel code, 457k data, 1024k dma, 572k reserved)
Calibrating delay loop... 989.18 BogoMIPS (lpj=494592)
Security Framework initialized
Mount-cache hash table entries: 512
Blackfin Scratchpad data SRAM: 4 KB
Blackfin L1 Data A SRAM: 16 KB (15 KB free)
Blackfin L1 Data B SRAM: 16 KB (16 KB free)
Blackfin L1 Instruction SRAM: 48 KB (37 KB free)
net_namespace: 288 bytes
NET: Registered protocol family 16
Blackfin DMA Controller
stamp_init(): registering device resources
NET: Registered protocol family 2
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 2048 (order: 2, 16384 bytes)
TCP bind hash table entries: 2048 (order: 1, 8192 bytes)
TCP: Hash tables configured (established 2048 bind 2048)
TCP reno registered
NET: Registered protocol family 1
msgmni has been set to 112
io scheduler noop registered
io scheduler anticipatory registered (default)
io scheduler cfq registered
Serial: Blackfin serial driver
bfin-uart.1: ttyBF0 at MMIO 0xffc00400 (irq = 18) is a BFIN-UART
bfin-uart.1: ttyBF1 at MMIO 0xffc02000 (irq = 20) is a BFIN-UART
brd: module loaded
PPP generic driver version 2.4.2
bfin_mii_bus: probed
bfin_mac: attached PHY driver [SMSC LAN83C185] (mii_bus:phy_addr=0:01, irq=-1, mdc_clk=2500000Hz(mdc_div=24)@sclk=125MHz)
bfin_mac bfin_mac.0: Blackfin on-chip Ethernet MAC driver, Version 1.1
bfin-spi bfin-spi.0: Blackfin on-chip SPI Controller Driver, Version 1.0, regs_base@ffc00500, dma channel@7
rtc-bfin rtc-bfin: rtc core: registered rtc-bfin as rtc0
bfin-wdt: initialized: timeout=20 sec (nowayout=0)
TCP cubic registered
NET: Registered protocol family 17
turn off boot console early_BFuart0
Just small doubt,I hope my understandings are clear.Please let me know if i am wrong!
I was just going through the following documents!!
docs.blackfin.uclinux.org/doku.php?id=bootloaders:u-boot:uimage
docs.blackfin.uclinux.org/doku.php?id=bootloaders:u-boot:serial-flash
Suppose I want to run the kernel application from serial flash connected to SSEL1 ,then if i give the following commands
sf probe 1; sf read 0x1000000 0x2000 0x2F189A; bootm 0x1000000
Does it mean that uImage.initramfs (image size=0x2F189A) which is in the address 0x2000 of the SPI flash will be read to SDRAM location 0x1000000 and the bootm command will uncompress the image in the SDRAM at the location as specified in the image info. When I gave the command iminfo 0x1000000,I do get some info about the kernel application image loaded in the location 0x1000000.So the bootm command then has to uncompress the image at 0x1000000 to the location 0x00001000 and kernel application will execute from 00173f80. So i can directly load the kernel application image using a flash programmer routine.
How can i ensure that while uncompressing overlapping doesnt happen?Does the file size of the vmlinux file(elf format of the kernel application image) gives the size of the uncompressed kernel application?
QuoteReplyEditDelete
2010-10-06 08:32:40 Re: kernel application hanged on BF537 stampkit
Shyam sundar (INDIA)
Message: 94269
According to the following document,
docs.blackfin.uclinux.org/doku.php?id=linux-kernel:debug:early_printk
When the early printk is enabled on early_BFuart0, console handover has to happen!!
console handover: boot [early_BFuart0] -> real [ttyBF0]
What could have gone wrong?
QuoteReplyEditDelete
2010-10-06 10:21:35 Re: kernel application hanged on BF537 stampkit
Mike Frysinger (UNITED STATES)
Message: 94278
did you disable CONFIG_SERIAL_BFIN_CONSOLE in your kernel config ? this is really the only way you could get this behavior and once again, this is the correct behavior. if you want a console on the Blackfin UART, you must enable the correct config settings.
pick a high enough address so overlap does not occur.
QuoteReplyEditDelete
2010-10-08 00:40:25 Re: kernel application hanged on BF537 stampkit
Shyam sundar (INDIA)
Message: 94320
Thanks a ton Mike,
I think by mistake,I would have disabled the CONFIG_SERIAL_BFIN_CONSOLE !!
Problem solved !!