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

Re: [bluetooth-dev] segmentaion fault: btd in usermode



Le Jeudi 08 Mars 2001 14:09, Matthias Fuchs a crit :
> Hi,
>
> while solving my uart problems I turned on all HCI debugging function in
> btdebug.h.
> I am using the usermode stack (current cvs version). Everything works
> fine until the server gets data from the ppp client:
>
> I connect my two maschines like this:
>
> client:
>   rf_conn <address of server> 0 0
>   rf_conn <address of server> 2 0
>
> server:
>   rf_conn <address of client> 2 0
>   ppp (see console dump below)
>
> client
>   ppp
>
> Here is the dump from the server's console. I ran the servers btd from
> gdb to where the segfault comes from !
> It comes from btd.c line 2247.
> btd:2247      BT_DATA("   |X|--> %3d [%d]\n", len, rfcomm->line);
>
> When I remove the rfcomm->line output, it works fine ! The rfcomm
> pointer seems to be a little bit low. Perhaps this function get the
> wrong pointer ?
>
> Well, I can life with the line changed to:
> btd:2247      BT_DATA("   |X|--> %3d [-]\n", len);

Yes, I have had exactly the same problem in user mode. I "fixed" it the same 
way.

>
> But that's a bug and this is my bug report :-)
>
> > ppp
>
> wait for a connection on line 0
> bt_waitline : not impl in usermode stack
> using channel 5
> Using interface ppp1
> Connect: ppp1 <--> /dev/pts/3
> BT DATA -->|X|     56
>
> data rec :  (56)
>    0x02 0x01 0x20 0x36 0x00 0x32 0x00 0x40 0x00 0x17 0xef 0x5d 0x7e 0xff
> 0x7d 0x23
>    0xc0 0x21 0x7d 0x21 0x7d 0x21 0x7d 0x20 0x7d 0x34 0x7d 0x22 0x7d 0x26
> 0x7d 0x20
>    0x7d 0x20 0x7d 0x20 0x7d 0x20 0x7d 0x25 0x7d 0x26 0x31 0xa1 0x7d 0x3d
> 0xf7 0x7d
>    0x27 0x7d 0x22 0x7d 0x28 0x7d 0x22 0x46
>
> hci_receive_data,  (56)
>    0x02 0x01 0x20 0x36 0x00 0x32 0x00 0x40 0x00 0x17 0xef 0x5d 0x7e 0xff
> 0x7d 0x23
>    0xc0 0x21 0x7d 0x21 0x7d 0x21 0x7d 0x20 0x7d 0x34 0x7d 0x22 0x7d 0x26
> 0x7d 0x20
>    0x7d 0x20 0x7d 0x20 0x7d 0x20 0x7d 0x25 0x7d 0x26 0x31 0xa1 0x7d 0x3d
> 0xf7 0x7d
>    0x27 0x7d 0x22 0x7d 0x28 0x7d 0x22 0x46
> hci_receive_data, hci-56
> HCI: hci_receive_data, WAIT_FOR_PACKET_TYPE
> HCI: hci_receive_data, WAIT_FOR_ACL_HDR
> HCI: hci_receive_data, new frame
> HCI: get_free_inbuffer, inbuffer 0 was free
> HCI: hci_receive_data, WAIT_FOR_ACL_DATA
> HCI: hci_receive_data, in_buf->count = 51
> HCI: hci_receive_data, Copied 51 bytes into inbuffer
> BT DATA -->|X|      3
>
> data rec :  (3)
>    0xdf 0x7e 0x10
>
> hci_receive_data,  (3)
>    0xdf 0x7e 0x10
> hci_receive_data, hci-3
> HCI: hci_receive_data, WAIT_FOR_ACL_DATA
> HCI: hci_receive_data, in_buf->count = 54
> HCI: hci_receive_data, Copied 3 bytes into inbuffer
> HCI: process_acl_data, in_buf->count:54, in_buf->l2cap_len:0
>
> Program received signal SIGSEGV, Segmentation fault.
> [Switching to Thread 1026 (LWP 6156)]
> 0x804ba44 in bt_receive_top (rfcomm=0x30005,
>     data=0x806d1f3 "~}#!}!}!} }4}\"}&} } } }
> }%}&1}=}'}\"}(}\"F~\020", len=46)
>     at btd.c:2247
> 2247      BT_DATA("   |X|--> %3d [%d]\n", len, rfcomm->line);
> (gdb)
>
>
> Matthias
> -
> 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