[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [bluetooth-dev] BT crash when connecting....



Hi, it's me again,

Well, most of the time, the debug output stops here:

bd (6):  0x05 0xe1 0x04 0x96 0xa0 0x00
     l2ca_connect_req: wait baseband, sleep on wq 0xc03c6833
 (and then, after some about 5 seconds)
     lp_connect_cfm (neg), wake up wq 0xc03c6833
     BT SYS: process_event: CONNECTION_COMPLETE Page Timeout
     BT SYS: ERROR: reset_hci_con_bd: Didn't find connection with con_hdl 0
     l2ca_connect_req: wait baseband, woke up !
     BT SYS: ERROR: l2ca_connect_req: lp_connect_req failed, no
 connection(status 4)
     BT SYS: ERROR: rfcomm_connect_req: l2ca_connect_req failed
bd (6): <--garbage, constant string buffers--- kernel freezed!>

We are seeing constant strings and old printed strings.... It seems to be a
memory access violation. More  than that, it seems to be a print() problem
with invalid string in argument...

I've look the source this print is from "print_data" called from
"l2ca_connect_req" in l2cap.c
I've looked the print_data function and it's crashing at the line where it's
printing the Bluetooth address....

I've removed the "print_data" call. The board is still running after 1 hour.
I will let the board for all the week end and see if it's still working on
monday.
(But I don't know why this function can crash!)

Regards,

Farid.


> -----Original Message-----
> From: owner-bluetooth-dev@xxxxxxx.com
> [mailto:owner-bluetooth-dev@xxxxxxx.com]On Behalf Of Benamrouche Farid
> Sent: vendredi 12 mars 2004 11:23
> To: bluetooth-dev@xxxxxxx.com
> Subject: RE: [bluetooth-dev] BT crash when connecting....
>
>
> Hi again,
>
> For the first time, I have some interesting debug messages for you.
> Again, the board crashed, but without any garbage! The last output was:
>
>
>     bd (6):0x05 0xe1 0x04 0x96 0xa0 0x00
>     l2ca_connect_req: wait baseband, sleep on wq 0xc03c6933
>
> (the next two lines should not be there!)
>         Mode : 0x00 BT SYS: rfcomm_disconnect_ind: remote cid 64
>         BT SYS: l2cap channel (1457,64) [RFCOMM] disconnected
>
>     lp_connect_cfm (neg), wake up wq 0xc03c6933
>     BT SYS: process_event: CONNECTION_COMPLETE PageTimeout
>     BT SYS: ERROR: reset_hci_con_bd: Didn't find connection with con_hdl 0
>
> (again, for some reason, the stack think that we were disconnected!)
>         BTSYS: process_event: DISCONNECTION_COMPLETE Other End Terminated
> Connection: User Ended Connection
>         BT SYS: lp_disconnect_ind: Connection handle 40 disconnected
>
>         HW
>         module contains...
>         8 ACL buffers at 192 bytes
>         8 SCO buffers at 64 bytes
> (nothing after that, the board does not respond)
>
> Just for your information, this Bluetooth device does not exist! So, I'm
> sure that it's impossible for the stack to connect to this device.....
>
> Hope that this will help you to figure out what is the problem....
> I will try to check the kernel source.
>
> Best Regards,
>
> Farid.
>
> > -----Original Message-----
> > From: owner-bluetooth-dev@xxxxxxx.com
> > [mailto:owner-bluetooth-dev@xxxxxxx.com]On Behalf Of Benamrouche Farid
> > Sent: vendredi 12 mars 2004 10:38
> > To: bluetooth-dev@xxxxxxx.com
> > Subject: [bluetooth-dev] BT crash when connecting....
> >
> >
> > HI,
> >
> > I'm experiencing some problem with long running tests:
> >
> > We are using a bluetooth access point v2.0 flash with the
> latest SDK from
> > your web site (with all the patches).
> >
> > Our application tries to connect to a Bluetooth devices every 2 seconds
> > (it's done in a thread)
> > The main thread of the application just wait for the connection.
> >
> > So, When the Bluetooth device is off (it's our Bluetooth
> barcode scanner),
> > the thread tries forever to connect without success:
> > The log is:
> >
> >     bd (6):  0x05 0xe1 0x04 0x96 0xa0 0x00
> >     l2ca_connect_req: wait baseband, sleep on wq 0xc03c6833
> > (and then, after some about 5 seconds)
> >     lp_connect_cfm (neg), wake up wq 0xc03c6833
> >     BT SYS: process_event: CONNECTION_COMPLETE Page Timeout
> >     BT SYS: ERROR: reset_hci_con_bd: Didn't find connection
> with con_hdl 0
> >     l2ca_connect_req: wait baseband, woke up !
> >     BT SYS: ERROR: l2ca_connect_req: lp_connect_req failed, no
> > connection(status 4)
> >     BT SYS: ERROR: rfcomm_connect_req: l2ca_connect_req failed
> >
> > (the same output every 2 seconds)
> >
> > When the connection fails, we try again:
> > if(apiOpenBT_rfcomm_connect_sec(bd_addr_str, tty, dev->pin_code)
> > != 0) (..)
> >
> > It's just working fine, but sometimes the access point crash! (this can
> > happen after 5 minutes or 5 days). Sermon just displays a lots
> of garbages
> > and stops.
> >
> > When we check the output, we can see that just before the
> > garbages we have:
> >
> >     <4>bd (6):  0x05 0xe1 0x04 0x96 0xa0 0x00
> >     <4>l2ca_connect_req: wait baseband, sleep on wq 0xc03c6833
> > (and then, after some about 5 seconds)
> >     <4>lp_connect_cfm (neg), wake up wq 0xc03c6833
> >     <4>BT SYS: process_event: CONNECTION_COMPLETE Page Timeout
> >     <4>BT SYS: ERROR: reset_hci_con_bd: Didn't find connection
> > with con_hdl
> > 0
> >     <4>l2ca_connect_req: wait baseband, woke up !
> >     <4>BT SYS: ERROR: l2ca_connect_req: lp_connect_req failed, no
> > connection(status 4)
> >     <4>BT SYS: ERROR: rfcomm_connect_req: l2ca_connect_req failed
> >
> > (the same output every 2 seconds)
> >
> > "<4>" is appended to each line.
> >
> > Well, I know that it will be hard to help us with such
> > information, that why
> > I wanted to compile the kernel with the kgdb option. Unfortunately, the
> > compilation failed with the following errors:
> >
> > make zImage
> > <...>
> >
> > make[1]: Leaving directory
> > `/usr/axis/axis/devboard_bt/os/linux-2.4.19/lib'
> > make
> > CFLAGS="-D__KERNEL__
> > -I/usr/axis/axis/devboard_bt/os/linux-2.4.19/include -W
> > all -Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing
> > -fno-common
> >  -mlinux -pipe -g -fno-omit-frame-pointer " -C  arch/cris/kernel
> > make[1]: Entering directory
> > `/usr/axis/axis/devboard_bt/os/linux-2.4.19/arch/cris/kernel'
> > make[1]: Circular
> > /usr/axis/axis/devboard_bt/os/linux-2.4.19/include/linux/bitops.h <-
> > /usr/axis/axis/devboard_bt/os/linux-2.4.19/include/asm/bitops.h
> dependency
> > dropped.
> > /usr/local/cris/lib/gcc-lib/cris-axis-linux-gnu/3.2.1/../../../../
> > cris-axis-
> > linux-gnu/bin/gcc -D__ASSEMBLY__ -D__KERNEL__
> > -I/usr/axis/axis/devboard_bt/o
> > s/linux-2.4.19/include -mlinux -c entry.S -o entry.o
> > entry.S: Assembler messages:
> > entry.S:216: Error: unassigned file number 2
> > entry.S:216: Error: unassigned file number 3
> > entry.S:216: Error: unassigned file number 4
> > entry.S:216: Error: unassigned file number 5
> > entry.S:216: Error: unassigned file number 6
> > entry.S:216: Error: unassigned file number 7
> > <...>
> > entry.S:216: Error: unassigned file number 118
> >
> > what could be the problem?
> > Once I have the kernel compiled in debug mode, I will be able to
> > provide you
> > better information....
> >
> > Thank you a lot for any answers, and sorry for this very long mail.
> >
> > Farid.
> >
> > -
> > To unsubscribe from this list: send the line "unsubscribe
> > bluetooth-dev" in
> > the body of a message to majordomo@xxxxxxx.com
>
> -
> To unsubscribe from this list: send the line "unsubscribe
> bluetooth-dev" in
> the body of a message to majordomo@xxxxxxx.com

-
To unsubscribe from this list: send the line "unsubscribe bluetooth-dev" in
the body of a message to majordomo@xxxxxxx.com