[#4836] kgdb on bf527-ezkit would have Ignoring packet error
Submitted By: Mingquan Pan
Open Date
2009-01-22 04:17:01 Close Date
2009-02-09 04:04:08
Priority:
Medium Assignee:
Sonic Zhang
Status:
Closed Fixed In Release:
N/A
Found In Release:
N/A Release:
Category:
N/A Board:
N/A
Processor:
BF527 Silicon Revision:
Is this bug repeatable?:
Yes Resolution:
Fixed
Uboot version or rev.:
Toolchain version or rev.:
Jan 17,2009
App binary format:
N/A
Summary: kgdb on bf527-ezkit would have Ignoring packet error
Details:
kgdb on bf527-ezkit would have Ignoring packet error now.
## Booting image at 02000000 ...
Image Name: Linux-2.6.28-ADI-2009R1-pre-svn6
Created: 2009-01-21 5:20:52 UTC
Image Type: Blackfin Linux Kernel Image (gzip compressed)
Data Size: 3853381 Bytes = 3.7 MB
Load Address: 00001000
Entry Point: 001b7524
Verifying Checksum ... OK
Uncompressing Kernel Image ... OK
Starting Kernel at = 1b7524
Linux version 2.6.28-ADI-2009R1-pre-svn6027 (test@uclinux60-bf527-std) (gcc version 4.1.2 (ADI svn)) #30 Wed Jan 21 13:20:33 CST 2009
Board Memory: 64MB
Kernel Managed Memory: 64MB
Memory map:
fixedcode = 0x00000400-0x00000490
text = 0x00001000-0x00126100
rodata = 0x00126100-0x001822e8
bss = 0x001822f0-0x00196f50
data = 0x00196f50-0x001aa000
stack = 0x001a8000-0x001aa000
init = 0x001aa000-0x0073c000
available = 0x0073c000-0x03eff000
DMA Zone = 0x03f00000-0x04000000
Hardware Trace Active and Enabled
Boot Mode: 1
Blackfin support (C) 2004-2008 Analog Devices, Inc.
Compiled for ADSP-BF527 Rev 0.0
Blackfin Linux support by blackfin.uclinux.org/
Processor Speed: 525 MHz core clock and 131 MHz System Clock
NOMPU: setting up cplb tables
Instruction Cache Enabled for CPU0
Data Cache Enabled for CPU0 (write-through)
Built 1 zonelists in Zone order, mobility grouping off. Total pages: 16001
Kernel command line: console=ttyBF0,57600 kgdboe=@10.100.4.50/,@10.100.4.174/
kgdboe: local port 6443
kgdboe: local IP 10.100.4.50
kgdboe: interface eth0
kgdboe: remote port 6442
kgdboe: remote IP 10.100.4.174
kgdboe: remote ethernet address ff:ff:ff:ff:ff:ff
Configuring Blackfin Priority Driven Interrupts
PID hash table entries: 256 (order: 8, 1024 bytes)
console [ttyBF0] enabled
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
Memory available: 56520k/65536k RAM, (5704k init code, 1172k kernel code, 528k data, 1024k dma, 584k reserved)
Calibrating delay loop... 1044.48 BogoMIPS (lpj=2088960)
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 (42 KB free)
PDA for CPU0 reserved at 00183368
net_namespace: 288 bytes
NET: Registered protocol family 16
Blackfin GPIO Controller
Blackfin DMA Controller
ezkit_init(): registering device resources
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
musb_hdrc: version 6.0, pio, host, debug=0
musb_hdrc: USB Host mode controller at ffc03800 using PIO, IRQ 59
musb_hdrc musb_hdrc.0: MUSB HDRC host driver
musb_hdrc musb_hdrc.0: new USB bus registered, assigned bus number 1
usb usb1: configuration #1 chosen from 1 choice
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 1 port detected
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 110
io scheduler noop registered
io scheduler anticipatory registered (default)
io scheduler cfq registered
bfin-t350mcqb: 320x240 24-bit RGB FrameBuffer initializing...
dma_alloc_init: dma_page @ 0x0302f000 - 256 pages at 0x03f00000
bfin-otp: initialized
Serial: Blackfin serial driver
bfin-uart.1: ttyBF0 at MMIO 0xffc02000 (irq = 31) is a BFIN-UART
brd: module loaded
bfin_mac_mdio: probed
bfin_mac: attached PHY driver [Generic PHY] (mii_bus:phy_addr=0:01, irq=-1, mdc_clk=2500000Hz(mdc_div=25)@sclk=131MHz)
bfin_mac bfin_mac.0: Blackfin on-chip Ethernet MAC driver, Version 1.1
kgdboe: local port 6443
kgdboe: local IP 10.100.4.50
kgdboe: interface eth0
kgdboe: remote port 6442
kgdboe: remote IP 10.100.4.174
kgdboe: remote ethernet address ff:ff:ff:ff:ff:ff
kgdboe: device eth0 not up yet, forcing it
kgdboe: carrier detect appears untrustworthy, waiting 4 seconds
PHY: 0:01 - Link is Up - 100/Full
kgdb: Registered I/O driver kgdboe.
kgdboe: debugging over ethernet enabled
m25p80 spi0.1: m25p16 (2048 Kbytes)
Creating 2 MTD partitions on "m25p80":
0x00000000-0x00040000 : "bootloader(spi)"
0x00040000-0x00200000 : "linux kernel(spi)"
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
hid_tmff: Unknown symbol _input_ff_create_memless
usbcore: registered new interface driver usbhid
usbhid: v2.6:USB HID core driver
TCP cubic registered
NET: Registered protocol family 17
rtc-bfin rtc-bfin: setting system clock to 2004-06-01 10:58:11 UTC (1086087491)
Freeing unused kernel memory: 5704k freed
usb 1-1: new high speed USB device using musb_hdrc and address 2
usb 1-1: configuration #1 chosen from 1 choice
_____________________________________
a8888b. / Welcome to the uClinux distribution \
d888888b. / _ _ \
8P"YP"Y88 / | | |_| __ __ (TM) |
8|o||o|88 _____/ | | _ ____ _ _ \ \/ / |
8' .88 \ | | | | _ \| | | | \ / |
8`._.' Y8. \ | |__ | | | | | |_| | / \ |
d/ `8b. \ \____||_|_| |_|\____|/_/\_\ |
dP . Y8b. \ For embedded processors including |
d8:' " `::88b \ the Analog Devices Blackfin /
d8" 'Y88b \___________________________________/
:8P ' :888
8a. : _a88P For further information, check out:
._/"Yaa_: .| 88P| - blackfin.uclinux.org/
\ YP" `| 8P `. - docs.blackfin.uclinux.org/
/ \.___.d| .' - www.uclinux.org/
`--..__)8888P`._.' jgs/a:f - www.analog.com/blackfin
Have a lot of fun...
BusyBox v1.13.2 (2009-01-21 08:21:29 CST) built-in shell (msh)
Enter 'help' for a list of built-in commands.
root:/>
#### Debugging is through ethernet port.
************** STEP 3: Start KGDB TEST
ifconfig eth0 10.100.4.50
root:/> GNU gdb 6.6
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "--host=i686-pc-linux-gnu --target=bfin-uclinux"...
(gdb)
Case 1 ...PASS
Case 1 ...PASS
target remote udp:10.100.4.50:6443
warning: The remote protocol may be unreliable over UDP.
Some events may be lost, rendering further debugging impossible.
Remote debugging using udp:10.100.4.50:6443
kgdb_breakpoint () at kernel/kgdb.c:1722
Case 2 ...PASS
Case 2 ...PASS
1722 atomic_set(&kgdb_setting_breakpoint, 0);
(gdb) break kgdb_test
Breakpoint 1 at 0x87c2: file arch/blackfin/kernel/kgdb_test.c, line 54.
Case 3 ...PASS
Case 3 ...PASS
(gdb) c
Continuing.
Case 4 ...PASS
Case 4 ...PASS
root:/> [New Thread 215]
Ignoring packet error, continuing...
Program received signal SIGTRAP, Trace/breakpoint trap.
[Switching to Thread 215]
0x00000000 in ?? ()
(gdb) test@uclinux60-bf527-std:~/work/cruise/checkouts/uclinux-dist/testsuites/kgdb> ps aux | grep bfin-uclinux-gdb
test 28411 1.6 2.7 33412 28656 pts/4 Ss+ 13:21 0:00 bfin-uclinux-gdb /home/test/work/cruise/checkouts/uclinux-dist/linux-2.6.x/vmlinux
test 28422 0.0 0.0 2852 724 pts/6 S+ 13:22 0:00 grep bfin-uclinux-gdb
test@uclinux60-bf527-std:~/work/cruise/checkouts/uclinux-dist/testsuites/kgdb> kill -9 `pidof bfin-uclinux-gdb`
test@uclinux60-bf527-std:~/work/cruise/checkouts/uclinux-dist/testsuites/kgdb>
Case 5 ...FAIL
Follow-ups
--- Sonic Zhang 2009-02-04 02:50:08
One of the UDP packets sent out with POLL mode in kgdb kernel is malformed. It
seems a bug in the kernel UDP stack.
0000 00 1d 0f 0b 00 00 00 00 00 00 00 00 00 00 00 00 ........ ........
0010 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ........ ........
0020 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ........ ........
0030 00 00 00 00 00 00 00 00 00 00 00 00 ........ ....
Correct packet is like
0000 00 1d 0f 0b 22 79 00 e0 22 fe b8 14 08 00 45 00 ...."y..
".....E.
0010 00 22 00 00 00 00 40 11 5d 24 0a 64 04 32 0a 64 ."....@.
]$.d.2.d
0020 04 ae 19 2b 82 55 00 0e 9d d6 24 4f 4b 23 39 61 ...+.U.. ..$OK#9a
0030 00 00 00 00 00 00 00 00 00 00 00 00 ........ ....
--- Sonic Zhang 2009-02-06 05:23:14
Fixed.
Make sure data are really written into registers before enabling DMA.
Otherwise, the EMAC dma controller may transfer out malformed packet. This patch
may also fix netperf bugs or scp bugs.
--- Mingquan Pan 2009-02-09 04:04:08
Yeah, this issue doesn't show up in latest kgdb ethernet tests. So close.
Files
Changes
Commits
Dependencies
Duplicates
Associations
Tags
File Name File Type File Size Posted By
No Files Were Found