[#5283] set l2 breakpoint would fail to work in the next round of debug
Submitted By: Mingquan Pan
Open Date
2009-06-19 05:21:02 Close Date
2010-06-11 04:09:44
Priority:
Medium Assignee:
Sonic Zhang
Status:
Closed Fixed In Release:
N/A
Found In Release:
2009R1-RC6 Release:
Category:
N/A Board:
N/A
Processor:
BF548 Silicon Revision:
Is this bug repeatable?:
Yes Resolution:
Out of Date
Uboot version or rev.:
Toolchain version or rev.:
09r1-r7
App binary format:
N/A
Summary: set l2 breakpoint would fail to work in the next round of debug
Details:
set l2 breakpoint would fail to work in the next round of debug on bf548 ezbrd on Jun 09.
When setting the hbreak kgdb_l2_test, it would stop for the first time, but after this round finishes, and cat /proc/kgdbtest again on target board, the bfin-uclinux-gdb fails to stop at any of the breakpoints, even breakpoint in RAM also slipps and not run. It still shows continue on gdb side, and on target board the kernel alread stops.
PU: ADSP bf548-0.2 (Detected Rev: 0.2) (parallel flash boot)
Board: ADI BF548 EZ-Kit board
Support: http://blackfin.uclinux.org/
Clock: VCO: 525 MHz, Core: 525 MHz, System: 131.250 MHz
RAM: 64 MB
Flash: 16 MB
NAND: 256 MiB
In: serial
Out: serial
Err: serial
Net: MAC: 00:E0:22:FE:BF:4E
Hit any key to stop autoboot: 0
smc911x: initializing
smc911x: detected LAN9218 controller
smc911x: phy initialized
smc911x: MAC 00:e0:22:fe:bf:4e
TFTP from server 10.100.4.174; our IP address is 10.100.4.50
Filename 'uImage'.
Load address: 0x1000000
Loading: #################################################################
#################################################################
#################################################################
#################################################################
#################################################################
##########################################
done
Bytes transferred = 5386947 (5232c3 hex)
## Booting kernel from Legacy Image at 01000000 ...
Image Name: Linux-2.6.28.10-ADI-2009R1-svn66
Created: 2009-06-09 0:13:43 UTC
Image Type: Blackfin Linux Kernel Image (gzip compressed)
Data Size: 5386883 Bytes = 5.1 MB
Load Address: 00001000
Entry Point: 0027992c
Verifying Checksum ... OK
Uncompressing Kernel Image ... OK
Starting Kernel at = 0027992c
Linux version 2.6.28.10-ADI-2009R1-svn6600 (test@uclinux61-bf548-std) (gcc version 4.1.2 (ADI svn)) #4 Tue Jun 9 00:13:20 GMT 2009
Board Memory: 64MB
Kernel Managed Memory: 64MB
Memory map:
fixedcode = 0x00000400-0x00000490
text = 0x00001000-0x0019f8c0
rodata = 0x0019f8c0-0x0022c4a4
bss = 0x0022d000-0x002486c0
data = 0x002486c0-0x00264000
stack = 0x00262000-0x00264000
init = 0x00264000-0x00a0e000
available = 0x00a0e000-0x03dff000
DMA Zone = 0x03e00000-0x04000000
Hardware Trace Active and Enabled
Boot Mode: 1
Blackfin support (C) 2004-2009 Analog Devices, Inc.
Compiled for ADSP-BF548 Rev 0.2
Blackfin Linux support by http://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-back)
Built 1 zonelists in Zone order, mobility grouping off. Total pages: 15747
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: 52620k/65536k RAM, (7848k init code, 1658k kernel code, 786k data, 2048k dma, 572k reserved)
Calibrating delay loop... 1046.52 BogoMIPS (lpj=2093056)
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)
Blackfin L2 SRAM: 128 KB (127 KB free)
net_namespace: 288 bytes
NET: Registered protocol family 16
Blackfin DMA Controller
ezkit_init(): registering device resources
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
musb_hdrc: version 6.0, musb-dma, host, debug=0
musb_hdrc: USB Host mode controller at ffc03c00 using DMA, IRQ 82
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
dma_alloc_init: dma_page @ 0x00aa7000 - 512 pages at 0x03e00000
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 102
io scheduler noop registered
io scheduler anticipatory registered (default)
io scheduler cfq registered
bf54x-lq043: FrameBuffer initializing...
bfin-otp: initialized
Serial: Blackfin serial driver
bfin-uart.1: ttyBF0 at MMIO 0xffc02000 (irq = 48) is a BFIN-UART
brd: module loaded
smsc911x: Driver version 2007-07-13.
eth0: SMSC911x MAC Address: 00:e0:22:fe:bf:4e
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
eth0: SMSC911x/921x identified at 0x24000000, IRQ: 175
eth0: link down
eth0: link up, 100Mbps, full-duplex, lpa 0x41E1
kgdb: Registered I/O driver kgdboe.
kgdboe: debugging over ethernet enabled
Driver 'sd' needs updating - please use bus_type methods
register bfin atapi driver
scsi0 : pata-bf54x
ata1: PATA max UDMA/66 irq 68
usb 1-1: new high speed USB device using musb_hdrc and address 2
usb 1-1: configuration #1 chosen from 1 choice
ata1.00: ATA-6: TOSHIBA MK4032GAX, AD101A, max UDMA/100
ata1.00: 78140160 sectors, multi 16: LBA48
ata1.00: configured for UDMA/66
blk_queue_max_hw_segments: set to minimum 1
scsi 0:0:0:0: Direct-Access ATA TOSHIBA MK4032GA AD10 PQ: 0 ANSI: 5
sd 0:0:0:0: [sda] 78140160 512-byte hardware sectors: (40.0 GB/37.2 GiB)
sd 0:0:0:0: [sda] Write Protect is off
sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
sd 0:0:0:0: [sda] 78140160 512-byte hardware sectors: (40.0 GB/37.2 GiB)
sd 0:0:0:0: [sda] Write Protect is off
sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
sda: sda1 sda2
sd 0:0:0:0: [sda] Attached SCSI disk
physmap platform flash device: 02000000 at 20000000
physmap-flash.0: Found 1 x16 devices at 0x0 in 16-bit bank
Intel/Sharp Extended Query Table at 0x010A
Intel/Sharp Extended Query Table at 0x010A
Intel/Sharp Extended Query Table at 0x010A
Intel/Sharp Extended Query Table at 0x010A
Intel/Sharp Extended Query Table at 0x010A
Using buffer write method
Using auto-unlock on power-up/resume
cfi_cmdset_0001: Erase suspend on write enabled
RedBoot partition parsing not available
Using physmap partition information
Creating 3 MTD partitions on "physmap-flash.0":
0x00000000-0x00040000 : "bootloader(nor)"
0x00040000-0x00440000 : "linux kernel(nor)"
0x00440000-0x01000000 : "file system(nor)"
BF5xx on-chip NAND FLash Controller Driver, Version 1.2 (c) 2007 Analog Devices, Inc.
bf5xx-nand bf5xx-nand.0: page_size=256, data_width=8, wr_dly=3, rd_dly=3
NAND device: Manufacturer ID: 0x20, Chip ID: 0xda (ST Micro NAND 256MiB 3,3V 8-bit)
Creating 2 MTD partitions on "NAND 256MiB 3,3V 8-bit":
0x00000000-0x00400000 : "linux kernel(nand)"
0x00400000-0x10000000 : "file system(nand)"
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@4
bfin-spi bfin-spi.1: Blackfin on-chip SPI Controller Driver, Version 1.0, regs_base@ffc02300, dma channel@5
Initializing USB Mass Storage driver...
scsi1 : SCSI emulation for USB Mass Storage devices
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
input: bf54x-keys as /devices/platform/bf54x-keys/input/input0
bf54x-keys: Blackfin BF54x Keypad registered IRQ 76
rtc-bfin rtc-bfin: rtc core: registered rtc-bfin as rtc0
i2c /dev entries driver
i2c-bfin-twi i2c-bfin-twi.0: Blackfin BF5xx on-chip I2C TWI Contoller, regs_base@ffc00700
i2c-bfin-twi i2c-bfin-twi.1: Blackfin BF5xx on-chip I2C TWI Contoller, regs_base@ffc02200
bfin-sdh bfin-sdh.0: unable to request DMA channel
bfin-sdh: probe of bfin-sdh.0 failed with error -16
usbcore: registered new interface driver usbhid
usbhid: v2.6:USB HID core driver
Advanced Linux Sound Architecture Driver Version 1.0.18rc3.
ASoC version 0.13.2
dma rx:0 tx:1, err irq:10, regs:ffc00800
AD1980 SoC Audio Codec
asoc: AC97 <-> bf5xx-ac97 mapping ok
ALSA device list:
#0: bf5xx-board (AD1980)
TCP cubic registered
NET: Registered protocol family 17
rtc-bfin rtc-bfin: setting system clock to 2004-06-01 19:51:07 UTC (1086119467)
Freeing unused kernel memory: 7848k freed
_____________________________________
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| - http://blackfin.uclinux.org/
\ YP" `| 8P `. - http://docs.blackfin.uclinux.org/
/ \.___.d| .' - http://www.uclinux.org/
`--..__)8888P`._.' jgs/a:f - http://www.analog.com/blackfin
Have a lot of fun...
BusyBox v1.13.4 (2009-06-08 19:59:05 GMT) built-in shell (msh)
Enter 'help' for a list of built-in commands.
root:/> ifconfscsi 1:0:0:0: Direct-Access SanDisk U3 Cruzer Micro 6.51 PQ: 0 ANSI: 0 CCS
sd 1:0:0:0: [sdb] 2014271 512-byte hardware sectors: (1.03 GB/983 MiB)
isd 1:0:0:0: [sdb] Write Protect is off
sd 1:0:0:0: [sdb] Assuming drive cache: write through
sd 1:0:0:0: [sdb] 2014271 512-byte hardware sectors: (1.03 GB/983 MiB)
sd 1:0:0:0: [sdb] Write Protect is off
sd 1:0:0:0: [sdb] Assuming drive cache: write through
sdb: sdb1 sdb2
sd 1:0:0:0: [sdb] Attached SCSI removable disk
g eth0 10.100.4.50
root:/> ifconfig
eth0 Link encap:Ethernet HWaddr 00:E0:22:FE:BF:4E
inet addr:10.100.4.50 Bcast:10.255.255.255 Mask:255.0.0.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:2 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:120 (120.0 B) TX bytes:0 (0.0 B)
Interrupt:175
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
root:/> cat /proc/kgdbtest
kgdb name(12): hello world!, 85, 16
L1(before change) : data variable addr = 0xff800000, data value is 0
L1 : code function addr = 0xffa00378
L1(after change) : data variable addr = 0xff800000, data value is 10
L2(before change) : data variable addr = 0xfeb00084, data value is 0
L2 : code function addr = 0xfeb00000
L2(after change) : data variable addr = 0xfeb00084, data value is 20
root:/> init: /bin/watchdogd respawning too fast
root:/> cat /proc/kgdbtest
kgdb name(12): hello world!, 85, 16
L1(before change) : data variable addr = 0xff800000, data value is 10
L1 : code function addr = 0xffa00378
L1(after change) : data variable addr = 0xff800000, data value is 20
L2(before change) : data variable addr = 0xfeb00084, data value is 20
L2 : code function addr = 0xfeb00000
L2(after change) : data variable addr = 0xfeb00084, data value is 40
root:/> cat /proc/kgdbtest
On host:
test@uclinux61-bf548-std:~/work/cruise/test_scripts/uclinux-dist> bfin-uclinux-gdb /tftpboot/vmlinux
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) 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
1722 atomic_set(&kgdb_setting_breakpoint, 0);
(gdb) break kgdb_test
Breakpoint 1 at 0x8366: file arch/blackfin/kernel/kgdb_test.c, line 57.
(gdb) c
Continuing.
[New Thread 347]
[Switching to Thread 347]
Breakpoint 1, kgdb_test (name=0x1a03c0 "hello world!", len=12, count=85, z=16) at arch/blackfin/kernel/kgdb_test.c:57
57 printk(KERN_DEBUG "kgdb name(%d): %s, %d, %d\n", len, name, count, z);
(gdb) c
Continuing.
[New Thread 348]
[Switching to Thread 348]
Breakpoint 1, kgdb_test (name=0x1a03c0 "hello world!", len=12, count=85, z=16) at arch/blackfin/kernel/kgdb_test.c:57
57 printk(KERN_DEBUG "kgdb name(%d): %s, %d, %d\n", len, name, count, z);
(gdb) break kgdb_l2_test
Breakpoint 2 at 0xfeb00004: file arch/blackfin/kernel/kgdb_test.c, line 45.
(gdb) c
Continuing.
Breakpoint 2, kgdb_l2_test () at arch/blackfin/kernel/kgdb_test.c:45
45 printk(KERN_ALERT "L2(before change) : data variable addr = 0x%p, data value is %d\n", &num2, num2);
(gdb) c
Continuing.
c
Follow-ups
--- Mingquan Pan 2009-06-26 05:58:06
This failure happens when l2 is set to WT as default. Now on branch head with WB
l2, kgdb case can pass ok.
--- Mike Frysinger 2009-06-26 10:32:03
does external memory settings matter ? i.e. does it always fail when L2 is WT
regardless of external memory being WB or WT ? it'd be interesting if extmem-WT
and L2-WT worked, but extmem-WB and L2-WT failed.
--- Sonic Zhang 2009-06-28 23:36:41
This bug occurs only when external memory is configured as WB and L2 is WT. All
other combination works well in kgdb L2 test.
Look like a similar issue in bug 5192.
--- Sonic Zhang 2009-06-28 23:38:20
So, the work around by now is not to usse external memory WB and L2 WT mode.
--- Sonic Zhang 2009-06-30 04:53:37
After fixing bug 5287, this bug disappears. It is possible that kgdb should not
flush address in L2 SRAM if it is configured in WT mode.
Files
Changes
Commits
Dependencies
Duplicates
Associations
Tags
File Name File Type File Size Posted By
config.kgdb application/octet-stream 40917 Mingquan Pan