You can subscribe to this list here.
2001 |
Jan
|
Feb
(44) |
Mar
(202) |
Apr
(134) |
May
(89) |
Jun
(94) |
Jul
(58) |
Aug
(58) |
Sep
(56) |
Oct
(75) |
Nov
(26) |
Dec
(14) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(24) |
Feb
(30) |
Mar
(15) |
Apr
(49) |
May
(12) |
Jun
(6) |
Jul
(11) |
Aug
(20) |
Sep
(19) |
Oct
(3) |
Nov
(13) |
Dec
(1) |
2003 |
Jan
(7) |
Feb
(4) |
Mar
(7) |
Apr
(5) |
May
(6) |
Jun
(3) |
Jul
(1) |
Aug
(1) |
Sep
|
Oct
(2) |
Nov
(51) |
Dec
(1) |
2004 |
Jan
(11) |
Feb
(5) |
Mar
|
Apr
(5) |
May
(2) |
Jun
|
Jul
(21) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2007 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Fredrik S. <fre...@us...> - 2002-02-12 13:54:02
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.222 1.223=20=20=20=20=20=20=20=20=20=20=20 bnep.c 1.5 1.6=20=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Patch from Fabrizio Gennari <fab...@ph...>: Fix compiler er= rors when building the stack as a module. The diff of the modified file(s): --- bluetooth.c 6 Feb 2002 11:23:13 -0000 1.222 +++ bluetooth.c 12 Feb 2002 13:54:00 -0000 1.223 @@ -2556,6 +2556,9 @@ =20 hci_module_init(); rfcomm_module_init(); +#ifdef CONFIG_BLUETOOTH_PAN + bnep_init_module(); +#endif =20=20=20=20=20=20=20=20=20 return 0; /* success */ } @@ -3269,6 +3272,10 @@ bnep_status_remove_proc_file(); #endif #endif /* CONFIG_BLUETOOTH_PROC */ + +#ifdef CONFIG_BLUETOOTH_PAN + bnep_exit_module(); +#endif =20 DSYS("Bluetooth Driver unregistered\n"); } --- bnep.c 12 Feb 2002 11:02:21 -0000 1.5 +++ bnep.c 12 Feb 2002 13:54:00 -0000 1.6 @@ -128,8 +128,6 @@ =20 /****************** LOCAL FUNCTION DECLARATION SECTION *******************= ***/ =20 -static int bnep_init_module(void); - /* Ethernet interface */ static int __init bnep_init_interface(struct net_device *dev); static int bnep_close(struct net_device *dev); @@ -153,13 +151,10 @@ =20 /****************** FUNCTION DEFINITION SECTION **************************= ***/ =20 -/* Tell the kernel to call my init routine. */ -module_init(bnep_init_module); - /*=20 * Init routine for the BNEP driver.=20 */ -static int +int bnep_init_module(void) { int i, err; @@ -183,6 +178,20 @@ } } return 0; +} + +void +bnep_exit_module(void) +{ + int i; + struct net_device *d; + + for (i =3D 0; i < BNEP_INTERFACES; i++) { + d =3D &dev_bnep[i]; + + D_MISC("Unregister netdev %s\n", d->name); + unregister_netdev(d); + } } =20 /*=20 |
From: Fredrik S. <fre...@us...> - 2002-02-12 13:50:21
|
The following file was modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bnep.h 1.2 1.3=20=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Patch from Fabrizio Gennari <fab...@ph...> The diff of the modified file(s): --- bnep.h 6 Feb 2002 11:19:59 -0000 1.2 +++ bnep.h 12 Feb 2002 13:50:17 -0000 1.3 @@ -191,6 +191,8 @@ =20 /****************** EXPORTED FUNCTION DECLARATION SECTION ****************= ***/ =20 +int bnep_init_module(void); +void bnep_exit_module(void); void bnep_init(void); u32 bnep_connect_req(u8* bd_addr); void bnep_disconnect_req(u8 line); |
From: Fredrik S. <fre...@us...> - 2002-02-12 11:02:23
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bnep.c 1.4 1.5=20=20=20=20=20=20=20=20=20=20=20=20=20 hci.c 1.191 1.192=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Fixed a problem with running out of ACL buffers when a client disconnects u= ngracefully. The diff of the modified file(s): --- bnep.c 11 Feb 2002 17:52:38 -0000 1.4 +++ bnep.c 12 Feb 2002 11:02:21 -0000 1.5 @@ -1407,10 +1407,11 @@ /* acknowledge the disconnect */ if (l2ca_disconnect_rsp(l2cap)) { D_ERR("ether_disconnect_ind: l2ca_disconnect_rsp failed\n"); - return; + //return; } local =3D dev->priv; local->l2cap =3D NULL; + local->state =3D DISCONNECTED; } =20 static void=20 --- hci.c 6 Feb 2002 11:23:15 -0000 1.191 +++ hci.c 12 Feb 2002 11:02:21 -0000 1.192 @@ -714,6 +714,8 @@ update_ncp(u8 nbr_of_hdl, u8 *pkt) { s32 i; + u16 hci_hdl; + u16 count; #ifdef __KERNEL__ unsigned long flags; =20 @@ -729,7 +731,18 @@ that have been sent */ =20 for (i =3D 0; i < 4 * nbr_of_hdl; i +=3D 4) { - hci_ctrl.hc_buf.acl_num +=3D le16_to_cpuu(&pkt[i+2]); + hci_hdl =3D hci_handle(&pkt[i]); + count =3D le16_to_cpuu(&pkt[i+2]); + hci_ctrl.hc_buf.acl_num +=3D count; + + D_REC(__FUNCTION__ ": free %d for handle %d\n", count, hci_hdl); + + if (hci_ctrl.acl_buf_count[hci_hdl] < count) { + D_ERR(__FUNCTION__ ": completed packets > pending, hdl %d\n", hci_hdl); + hci_ctrl.acl_buf_count[hci_hdl] =3D 0; + } else { + hci_ctrl.acl_buf_count[hci_hdl] -=3D count; + } } =20=09 D_QUEUE("<NCP:%d>\n", hci_ctrl.hc_buf.acl_num); @@ -836,6 +849,7 @@ if (lp_connect_cfm(buf + 3, (u32) buf[0], hci_hdl)) { hci_ctrl.nbr_of_connections++; hci_update_load_factor(); + hci_ctrl.acl_buf_count[hci_hdl] =3D 0; } =20 #ifndef HCI_EMULATION @@ -897,27 +911,37 @@ break; =20 case DISCONNECTION_COMPLETE: + { + u16 hci_hdl =3D hci_handle(&buf[1]); DSYS(__FUNCTION__ ": DISCONNECTION_COMPLETE %s\n", get_err_msg(buf[3])); =20 release_cmd_timer(); wake_up_interruptible(&hci_wq); =20 - if (lp_disconnect_ind(hci_handle(&buf[1]))) + if (lp_disconnect_ind(hci_hdl)) if (hci_ctrl.nbr_of_connections > 0) { hci_ctrl.nbr_of_connections--; hci_update_load_factor(); } =20 + if (hci_ctrl.acl_buf_count[hci_hdl] > 0) { + DSYS(__FUNCTION__ ": Reset %d pending packets for handle %d\n",=20 + hci_ctrl.acl_buf_count[hci_hdl], hci_hdl); + hci_ctrl.hc_buf.acl_num +=3D hci_ctrl.acl_buf_count[hci_hdl]; + hci_ctrl.acl_buf_count[hci_hdl] =3D 0; + } + /* FIXME: No more NBR_OF_COMPLETE_PACKETS will arrive for this connection handle, if we only support point-to-point connections we can acl_num by reading the buffersizes again, but this will not work in a multipoint connection. */ =20 - reset_hci_con_bd(hci_handle(&buf[1])); + reset_hci_con_bd(hci_hdl); =20=09=09 if (hci_ctrl.nbr_of_connections <=3D 0) { hci_read_buffer_size(HCI_NON_BLOCK); } + } break; =20 case AUTHENTICATION_COMPLETE: @@ -3423,6 +3447,7 @@ if (sent_bytes !=3D 0) { bytes2send -=3D sent_bytes; cli(); + hci_ctrl.acl_buf_count[tx_buf->hci_hdl]++; hci_ctrl.hc_buf.acl_num--; sti(); } else { |
From: Fredrik S. <fre...@us...> - 2002-02-12 10:57:42
|
The following file was modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- hci_internal.h 1.21 1.22=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Added a counter of number of pending packets for each HCI handle. The diff of the modified file(s): --- hci_internal.h 2 Oct 2001 11:00:25 -0000 1.21 +++ hci_internal.h 12 Feb 2002 10:57:41 -0000 1.22 @@ -116,6 +116,8 @@ =20 #define NBR_CMD_BUFS 10 =20 +#define MAX_HCI_HANDLE_NBR 0xFF + /* Define the different OpCode Group Field (OGF) values */ #define HCI_LC 0x01 /* Link Control Command */ #define HCI_LP 0x02 /* Link Policy Command */ @@ -337,6 +339,9 @@ u32 nbr_of_connections; u8 local_bd[6]; hci_con con[MAX_NBR_OF_CONNECTIONS]; + + /* A counter of # of pending packets for each HCI handle */ + u8 acl_buf_count[MAX_HCI_HANDLE_NBR+1]; } hci_controller; =20 /****************** EXPORTED FUNCTION DECLARATION SECTION ****************= ***/ |
From: Anders J. <and...@us...> - 2002-02-11 17:52:40
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bnep.c 1.3 1.4=20=20=20=20=20=20=20=20=20=20=20=20=20 l2cap.c 1.128 1.129=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Deny multiple bnepconnections from the same client. * Don't delete the connection if non-initiator when replying negative on a connection request. The diff of the modified file(s): --- bnep.c 29 Jan 2002 15:57:26 -0000 1.3 +++ bnep.c 11 Feb 2002 17:52:38 -0000 1.4 @@ -410,7 +410,7 @@ struct bnep_compressed_ethernet_source_only bnep_c_s; struct bnep_compressed_ethernet bnep_c; void *bhdr; - int i, bhdrlen, ethhdrlen =3D sizeof(struct ethhdr), buflen, strip_len = =3D 0; + int i, bhdrlen, ethhdrlen =3D sizeof(struct ethhdr), buflen, strip_len = =3D 0, j; u16 proto, payload_proto;=20 int send_packet =3D 0; int dest =3D 1; @@ -1239,10 +1239,30 @@ static void=20 bnep_connect_ind(l2cap_con *l2cap)=20 { - int i; + int i, j, dupe; struct net_local *local; D_MISC("bnep_connect_ind: remote cid %d\n", l2cap->remote_cid); =20=09 + for (i=3D0 ; i < BNEP_MAX_CON ; i++) { + local =3D dev_bnep[i].priv; + if(local->l2cap) { + dupe =3D 1; + for (j =3D 0; j < 6; j++) { + if (l2cap->remote_bd[j] !=3D local->l2cap->remote_bd[j]) { + dupe =3D 0; + break; + } + } + if(dupe) { + D_ERR(__FUNCTION__ ": Already have a bnep connection from that client\= n"); + if (l2ca_connect_rsp(l2cap, RES_NOSRC, STAT_NOINFO)) { + D_ERR("bnep_connect_ind: l2ca_connect_rsp failed\n"); + } + return; + }=09 + } + } + /* Check for free interfaces */ for (i=3D0 ; i < BNEP_MAX_CON ;i++) { local =3D dev_bnep[i].priv; --- l2cap.c 24 Jan 2002 12:41:31 -0000 1.128 +++ l2cap.c 11 Feb 2002 17:52:38 -0000 1.129 @@ -1788,8 +1788,12 @@ ENTERSTATE(con, CLOSED); PRINTSTATE(con); =20 - /* remove connection */ + /* As the hcihdl is stored in the l2cap connection + object we need to keep it if we are non-initiator + */ + if(con->initiator || (count_con(con->hci_hdl) > 1)) { delete_con(con); + } }=20=20 return result; } |
From: Anders J. <and...@us...> - 2002-02-06 11:31:59
|
The following files were modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- Makefile 1.11 1.12=20=20=20=20=20=20=20=20=20=20=20=20 bt_if.h 1.30 1.31=20=20=20=20=20=20=20=20=20=20=20=20 bttest.c 1.23 1.24=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Patch from Alain Paschoud: * Added IOCTL to get remotename of a device. * Added INCLUDE_PAN to the Makefile. * Added remote_name command to bttest. * Added bnep_test command to bttest. The diff of the modified file(s): --- Makefile 2001/10/18 15:56:25 1.11 +++ Makefile 2002/02/06 11:31:56 1.12 @@ -16,6 +16,7 @@ #HAVE_READLINE =3D 1 =20 INCLUDE_UNPLUG_TEST =3D 1 +INCLUDE_PAN =3D 1 =20 INSTDIR =3D $(prefix)/bin/ INSTMODE =3D 0755 @@ -44,6 +45,10 @@ =20 ifdef INCLUDE_UNPLUG_TEST CFLAGS +=3D -DCONFIG_BLUETOOTH_UNPLUG_TEST +endif + +ifdef INCLUDE_PAN +CFLAGS +=3D -DCONFIG_BLUETOOTH_PAN endif =20 CFLAGS +=3D -MMD --- bt_if.h 2002/01/18 13:44:39 1.30 +++ bt_if.h 2002/02/06 11:31:56 1.31 @@ -78,6 +78,8 @@ #define L2CAP_TEST2_LAYER 0x1233 #define L2CAP_TEST3_LAYER 0x4461 =20 +#define BT_NAME_LENGTH 248 + /* =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D */ /* SDP server */ =20 @@ -147,6 +149,7 @@ #define HCIPINCODENEGATIVEREPLY _IOWR(BT_IOC_MAGIC, 0x24, unsigned char[6]) #define HCIAUTHENTICATION_REQUESTED _IOW(BT_IOC_MAGIC, 0x25, unsigned char= [6]) #define HCISETCONNECTION_ENCRYPTION _IOW(BT_IOC_MAGIC, 0x26, unsigned char= [7]) +#define HCIREMOTENAME_REQUEST _IOW(BT_IOC_MAGIC, 0x27, unsigned char[255]) =20 /* Link Policy Commands */ =20 --- bttest.c 2001/10/16 16:26:43 1.23 +++ bttest.c 2002/02/06 11:31:56 1.24 @@ -80,6 +80,7 @@ "\nMenu", "------------------------", " inq <max nbr resp> <inq time>", + " remote_name <xx:xx:xx:xx:xx:xx>", " rf_conn <xx:xx:xx:xx:xx:xx> <srv ch> <line>", " rf_send <nbr bytes> <nbr repeats> <line>",=20 " rf_disc <line>", @@ -102,6 +103,9 @@ #endif #ifdef CONFIG_BLUETOOTH_UNPLUG_TEST " upt <teststring>", /* e.g testcase 4.3 't 43' */ +#ifdef CONFIG_BLUETOOTH_PAN + " bnep_test <param> <testcase>", +#endif #endif " quit",=20 =20 @@ -522,7 +526,7 @@ retval =3D bt_testcmd(bt_cfd, buf); } else if(sscanf(buf, "hotlist_set %d %x:%x:%x:%x:%x:%x",=20 - &tmp[6], &tmp[0], &tmp[1], &tmp[2], &tmp[3], &tmp[4], &tm= p[5])) + &tmp[6], &tmp[0], &tmp[1], &tmp[2], &tmp[3], &tmp[4], &tm= p[5])=3D=3D 7) { FILE *hotlist_fd; int i, j; @@ -571,6 +575,30 @@ printf("Enabling sending of disconnect respons\n"); bt_testcmd(bt_cfd, buf); }=20=20=20 + else if(sscanf(buf, "bnep_test %d %d",=20 + &tmp[0], &tmp[1]) =3D=3D 2) + {=20 + if (ioctl(bt_cfd, BNEPTEST, &tmp[0]) < 0) + { + perror(__FUNCTION__); + return 0; + } + }=20 + else if(sscanf(buf, "remote_name %x:%x:%x:%x:%x:%x",=20=20 + &bd[0], &bd[1], &bd[2], &bd[3], &bd[4], &bd[5]) =3D=3D 6) + { + unsigned char remote_name[BT_NAME_LENGTH + 1]; + memcpy(&remote_name[0], &bd[0], 6); +=20=20=20=20 + if (retval =3D ioctl(bt_cfd, HCIREMOTENAME_REQUEST, &remote_name[0])) + { + printf("Remote Name Request Failed (status %d)\n", retval); + return 0; + } + printf("Remote Name (%02X:%02X:%02X:%02X:%02X:%02X): %s\n",=20 + bd[0], bd[1], bd[2], bd[3], bd[4], bd[5], remote_name); + } + else { printf("> error: command not recognized or wrong syntax\n"); |
From: Anders J. <and...@us...> - 2002-02-06 11:23:16
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.221 1.222=20=20=20=20=20=20=20=20=20=20=20 btmem.c 1.47 1.48=20=20=20=20=20=20=20=20=20=20=20=20 hci.c 1.190 1.191=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Patch from Alain Paschoud: * Added IOCTL to get remotename of a device. * Added wait_queue to block until we got a reply of the remote_name_request. * get_remote_name now takes an extra parameter to be used if we want to wait for the reply before returning from the function. * Changed returnvalue of btmem_init. The diff of the modified file(s): --- bluetooth.c 2002/01/29 15:57:26 1.221 +++ bluetooth.c 2002/02/06 11:23:13 1.222 @@ -91,7 +91,11 @@ #ifdef CONFIG_BLUETOOTH_SUPPORT_BCSP #include <linux/bluetooth/bcsp.h> #endif +#ifdef CONFIG_BLUETOOTH_PAN +#include <linux/bluetooth/bnep.h> +#endif =20 + #ifdef CONFIG_BLUETOOTH_USE_TCI #include <linux/bluetooth/tci.h> #endif @@ -267,6 +271,7 @@ =20 extern hci_controller hci_ctrl; static u8 btdm_pid =3D 0; +extern u8 name_request_response[BT_NAME_LENGTH + 1]; =20 /****************** LOCAL VARIABLE DECLARATION SECTION *******************= ***/ =20 @@ -878,12 +883,10 @@ =20=09 case HCISETLOCALNAME: { - /* FIXME: If we send the length of the string too, we don't - have to copy all the 248 byte... */ - u8 local_name[248]; + u8 local_name[BT_NAME_LENGTH]; =20 BT_DRIVER(__FUNCTION__ ": HCISETLOCALNAME\n"); - copy_from_user(local_name, (s32*)arg, 248); + copy_from_user(local_name, (s32*)arg, BT_NAME_LENGTH); hci_change_local_name(local_name); break; } @@ -1219,6 +1222,32 @@ =20 #endif /* CONFIG_BLUETOOTH_PAN */ =20 + case HCIREMOTENAME_REQUEST: + { + u8 param[6]; + u8 tmp_bd_addr[6]; + int i; +=09=09 + BT_DRIVER(__FUNCTION__ ": HCIREMOTENAME_REQUEST\n"); + /* I recieve the BD_ADDR in param, and I send back the name */ + copy_from_user(param, (u8*)arg, 6); + BT_DRIVER("HCIREMOTENAME_REQUEST: message: bd_addr : %02X:%02X:%02X:%02= X:%02X:%02X\n", + param[0], param[1], param[2], param[3], param[4], param[= 5]); +=20 + /* Swap the whole address */ + for (i =3D 0; i< 6; i++) + tmp_bd_addr[i] =3D param[5 - i]; +=20 + if((err =3D remote_name_request(tmp_bd_addr, 1)) < 0) { + return err; + } + + /* We have to copy it in param from a global variable */ + copy_to_user((s32*)arg, name_request_response + 1, BT_NAME_LENGTH); +=20=09=09 + return name_request_response[0];=09 + } + default:=09=09 return -ENOIOCTLCMD; } @@ -2600,7 +2629,9 @@ bt_init_stack(void) { unsigned long page;=09 + s32 retval =3D 0; =20 + /* shutdown if already initiated */ if (bt_stack_initiated) bt_shutdown(); @@ -2636,13 +2667,13 @@ add_timer(&bt_clear_led_timer); #endif =20 - if(btmem_init() =3D=3D -1) { + if((retval =3D btmem_init()) < 0) { D_ERR("BTMEM init failed"); #ifdef __CRIS__ del_timer(&bt_clear_led_timer); bt_set_leds(NO_BLUETOOTH_ACTIVITY); #endif - return -1; + return retval; } =20=09 =20 --- btmem.c 2002/01/24 16:08:47 1.47 +++ btmem.c 2002/02/06 11:23:15 1.48 @@ -129,6 +129,7 @@ #if BTMEM_TEST btmem_test(); #endif + return 0; } =20=20 /* Returns success if deallocation was successful */ --- hci.c 2001/12/06 11:21:21 1.190 +++ hci.c 2002/02/06 11:23:15 1.191 @@ -192,7 +192,6 @@ static s32 accept_connection_request(u8 bd_addr[], u8 role); static s32 reject_connection_request(u8 bd_addr[], u32 reason); static s32 change_connection_packet_type(u32 hci_hdl, u32 pkt_type); -static s32 remote_name_request(u8 *bd); =20 /* Link Policy Commands */ static s32 role_discovery(u16 con_hdl); @@ -305,11 +304,13 @@ struct wait_queue *inq_wq =3D NULL; struct wait_queue *set_baudrate_wq =3D NULL; struct wait_queue *test_wq =3D NULL; +struct wait_queue *get_name_wq =3D NULL; #else wait_queue_head_t hci_wq; wait_queue_head_t inq_wq; wait_queue_head_t set_baudrate_wq; wait_queue_head_t test_wq; +wait_queue_head_t get_name_wq; #endif /* LINUX_VERSION_CODE */ =20 static s32 test_wq_active =3D 0; @@ -320,6 +321,8 @@ =20 static s32 test_hci_hdl; =20 +u8 name_request_response[BT_NAME_LENGTH + 1]; /* 1 byte more to keep resul= t */ + /* temp solution to handle m/s switch */ static s32 force_msswitch =3D 0; static s32 i_am_initiator =3D 0; @@ -853,7 +856,7 @@ DM1|DH1|DM3|DH3|DM5|DH5); #endif set_hci_con(buf + 3, hci_hdl); - remote_name_request(buf + 3); + remote_name_request(buf + 3, 0); =20 /* enable m/s switch */=20 write_link_policy_settings(hci_hdl, 0x01); @@ -940,10 +943,17 @@ } else { if (strlen(buf + 7) > 248) { D_ERR(__FUNCTION__ ": REMOTE_NAME_REQUEST_COMPLETE: too long name leng= th %d\n", (int)strlen(buf + 7)); - break; - } + } else { set_hci_con_name(buf + 1, buf + 7); } +=09=09=09 + } + /* Store the name in a global variable to send back to userland */ + memcpy(name_request_response + 1, buf + 7, BT_NAME_LENGTH); + memcpy(name_request_response, buf, 1); /* Copy the status */ +=20=09=09 + D_CMD(__FUNCTION__ ": wake_up(get_name_wq)\n"); + wake_up_interruptible(&get_name_wq); break; =20 case ENCRYPTION_CHANGE: @@ -1686,8 +1696,6 @@ return; } } - - D_ERR(__FUNCTION__ ": Didn't fin connecton with BD adress 0x%02x:%= 02x:%02x:%02x:%02x:%02x\n", bd[5],bd[4],bd[3],bd[2],bd[1],bd[0]); } =20 s32 hci_sprint_local_bd(u8 *buf) @@ -1827,6 +1835,7 @@ init_waitqueue_head(&inq_wq); init_waitqueue_head(&set_baudrate_wq); init_waitqueue_head(&test_wq); + init_waitqueue_head(&get_name_wq); sema_init(&hci_cmd_semaphore, 1); sema_init(&hci_inq_semaphore, 1); #endif /* LINUX_VERSION_CODE */ @@ -2377,9 +2386,9 @@ } =20 s32 -remote_name_request(u8 *bd) +remote_name_request(u8 *bd, s32 block) { - s32 c =3D 0; + s32 c =3D 0, retval =3D 0; s32 zero =3D 0; =20=09=09 D_CMD(__FUNCTION__ ": for bd address 0x%02x:%02x:%02x:%02x:%02x:%02x\n" @@ -2394,8 +2403,11 @@ c +=3D 4; =20 c_pkt.len =3D c; - - return send_cmd((u8*) &c_pkt, c_pkt.len + CMD_HDR_LEN + HCI_HDR_LEN); + retval =3D send_cmd((u8*) &c_pkt, c_pkt.len + CMD_HDR_LEN + HCI_HDR_LEN); + if(block) { + interruptible_sleep_on(&get_name_wq); + } + return retval; } =20 /* Definitions of the Link Policy Commands functions */ @@ -2518,17 +2530,15 @@ s32 hci_change_local_name(u8 *new_name) { -#define NAME_LEN 248 D_CMD(__FUNCTION__ ": New name: %s\n", new_name); c_pkt.type =3D CMD_PKT; c_pkt.opcode =3D hci_put_opcode(CHANGE_LOCAL_NAME, HCI_HC); =20 - memset(c_pkt.data, 0, NAME_LEN); + memset(c_pkt.data, 0, BT_NAME_LENGTH); strcpy(c_pkt.data, new_name); - c_pkt.len =3D NAME_LEN; + c_pkt.len =3D BT_NAME_LENGTH; =20 return send_cmd_block((u8*) &c_pkt , c_pkt.len + CMD_HDR_LEN + HCI_HDR_LE= N, DEFAULT_TIMEOUT);=09 -#undef NAME_LEN } =20 =20 |
From: Anders J. <and...@us...> - 2002-02-06 11:20:00
|
The following files were modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bnep.h 1.1 1.2=20=20=20=20=20=20=20=20=20=20=20=20=20 bnep_internal.h 1.1 1.2=20=20=20=20=20=20=20=20=20=20=20=20=20 btcommon.h 1.92 1.93=20=20=20=20=20=20=20=20=20=20=20=20 hci.h 1.73 1.74=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Patch from Alain Paschoud: * Added ioctl to send a REMOTE_NAME_REQUEST. * Define of BT_NAME_LENGTH. * get_remote_name function now takes an extra parameter to allow the command to block. * Moved some declarations from bnep_internal.h -> bnep.h The diff of the modified file(s): --- bnep.h 2002/01/24 16:09:59 1.1 +++ bnep.h 2002/02/06 11:19:59 1.2 @@ -196,6 +196,8 @@ void bnep_disconnect_req(u8 line); u32 bnep_test(u8 *p); =20 +s32 bnep_status_create_proc_file(void); +s32 bnep_status_remove_proc_file(void); =20 #endif /****************** END OF FILE bnep.h ***********************************= ***/ --- bnep_internal.h 2002/01/24 16:10:00 1.1 +++ bnep_internal.h 2002/02/06 11:19:59 1.2 @@ -90,9 +90,4 @@ =20 int bnep_send_raw_packet(l2cap_con *l2cap, u8 *data, u16 len); void print_ip_packet(char *data, u16 proto); - -/* Proc file interface */ -s32 bnep_create_proc_file(void); -s32 bnep_remove_proc_file(void); -s32 bnep_status_create_proc_file(void); #endif --- btcommon.h 2002/01/18 12:50:32 1.92 +++ btcommon.h 2002/02/06 11:19:58 1.93 @@ -57,7 +57,7 @@ #include "local.h" #include "btdebug.h" #include "btconfig.h" -#include <sys/unistd.h> /* for the sleep ..*/ +#include <unistd.h> /* for the sleep ..*/ #endif =20 /* Defines common to all files */ @@ -100,6 +100,10 @@ #define le16_to_cpuu(addr) (le16_to_cpu(get_unaligned((u16 *)(addr)))) #define le32_to_cpuu(addr) (le32_to_cpu(get_unaligned((u32 *)(addr)))) =20 + +/******************* Define Values from Bluetooth specs ******************= ***/ +#define BT_NAME_LENGTH 248 + /****************** Defines realted to the bluetooth implementation ******= ***/ =20 #define SERIAL_PORT_PROFILE 0 @@ -155,6 +159,7 @@ #define HCIPINCODENEGATIVEREPLY _IOWR(BT_IOC_MAGIC, 0x24, u8[6]) #define HCIAUTHENTICATION_REQUESTED _IOW(BT_IOC_MAGIC, 0x25, u8[6]) #define HCISETCONNECTION_ENCRYPTION _IOW(BT_IOC_MAGIC, 0x26, u8[7]) +#define HCIREMOTENAME_REQUEST _IOW(BT_IOC_MAGIC, 0x27, u8[255]) =20 /* Link Policy Commands */ #define HCISWITCHROLE _IOW(BT_IOC_MAGIC, 0x28, u8[7]) @@ -172,7 +177,7 @@ #define HCIREADSTOREDLINKKEY _IOWR(BT_IOC_MAGIC, 0x33, u8[7]) #define HCIWRITESTOREDLINKKEY _IOWR(BT_IOC_MAGIC, 0x34, u8[22]) #define HCIDELETESTOREDLINKKEY _IOWR(BT_IOC_MAGIC, 0x35, u8[7]) -#define HCISETLOCALNAME _IOW(BT_IOC_MAGIC, 0x36, u8[248]) +#define HCISETLOCALNAME _IOW(BT_IOC_MAGIC, 0x36, u8[BT_NAME_LENGTH]) #define HCIREADSCANENABLE _IOR(BT_IOC_MAGIC, 0x37, s32) #define HCIWRITESCANENABLE _IOW(BT_IOC_MAGIC, 0x38, s32) #define HCIWRITEPAGESCANACTIVITY _IOW(BT_IOC_MAGIC, 0x39, u32[2]) --- hci.h 2001/10/22 12:51:44 1.73 +++ hci.h 2002/02/06 11:19:58 1.74 @@ -185,6 +185,9 @@ s32 hci_read_local_version_info(s32 block); s32 hci_read_country_code(void); =20 +/* Status Parameters */ +s32 remote_name_request(u8 *bd, s32 block); + /* Internal */ /* FIXME -- add parameter to choose from different devices */ s32 get_remote_bd(int line, u8 *bd); |
From: <yh...@ug...> - 2002-02-06 10:04:18
|
Hi I get the following message when I try to insmod 'bt.o' into the kernel 2.2.18 and I can't find the stc/bt.o how to do? bt.o: unresolved symbol __wake_up_R96ded479 bt.o: unresolved symbol ..... best regards |
From: Peter K. <pk...@us...> - 2002-02-04 11:53:46
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- Makefile 1.29 1.30=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Patch from Fabrizio Gennari <fab...@ph...>: * Build the module correctly when building it as part of the kernel. * Added possibility to specify 'make INCLUDE_PAN=3D1' to enable PAN support when building the module stand-alone. The diff of the modified file(s): --- Makefile 2002/01/24 16:09:25 1.29 +++ Makefile 2002/02/04 11:53:45 1.30 @@ -6,17 +6,17 @@ l2cap.o l2cap_con.o l2cap_sec.o rfcomm.o rfcomm_sec.o \ sec_client.o sdp.o tcs.o test.o =20 +BOBJS =3D bcsp.o bcsp_datagram.o bcsp_integrity.o bcsp_mux.o \ + bcsp_sequence.o bcsp_slip.o + +POBJS =3D bnep.o bnep_status_proc.o + TOBJS =3D unplug_test.o =20 ifdef CONFIG_BLUETOOTH_PAN TOBJS +=3D bnep_test.o endif =20 -BOBJS =3D bcsp.o bcsp_datagram.o bcsp_integrity.o bcsp_mux.o \ - bcsp_sequence.o bcsp_slip.o - -POBJS =3D bnep.o bnep_status_proc.o - ifeq ($(TOPDIR)/Rules.make,$(wildcard $(TOPDIR)/Rules.make)) =20 #--------------------------------------------------------------------- @@ -27,22 +27,24 @@ O_TARGET :=3D bt.o =20 # For 2.4.x -obj-$(CONFIG_BLUETOOTH) +=3D $(OBJS) -obj-$(CONFIG_BLUETOOTH_UNPLUG_TEST) +=3D $(TOBJS) +obj-y +=3D $(OBJS) obj-$(CONFIG_BLUETOOTH_SUPPORT_BCSP) +=3D $(BOBJS) obj-$(CONFIG_BLUETOOTH_PAN) +=3D $(POBJS) +obj-$(CONFIG_BLUETOOTH_UNPLUG_TEST) +=3D $(TOBJS) + +obj-m :=3D $(O_TARGET) =20 # For 2.0.x and 2.2.x O_OBJS =3D $(OBJS) -ifdef CONFIG_BLUETOOTH_UNPLUG_TEST -O_OBJS +=3D $(TOBJS) -endif ifdef CONFIG_BLUETOOTH_SUPPORT_BCSP O_OBJS +=3D $(BOBJS) endif ifdef CONFIG_BLUETOOTH_PAN O_OBJS +=3D $(POBJS) endif +ifdef CONFIG_BLUETOOTH_UNPLUG_TEST +O_OBJS +=3D $(TOBJS) +endif M_OBJS =3D $(O_TARGET) =20 include $(TOPDIR)/Rules.make @@ -56,6 +58,9 @@ # Use 'make INCLUDE_BCSP_SUPPORT=3D1' to enable support for BCSP. INCLUDE_BCSP_SUPPORT =3D 0 =20 +# Use 'make INCLUDE_PAN=3D1' to enable the PAN profile. +INCLUDE_PAN =3D 0 + # Use 'make INCLUDE_UNPLUG_TEST=3D1' to enable the unplug testcases. INCLUDE_UNPLUG_TEST =3D 0 =20 @@ -72,14 +77,19 @@ MODFLAGS =3D -DMODVERSIONS -include $(INCLUDEDIR)/linux/modversions.h CFLAGS =3D -D__KERNEL__ -DMODULE -I../../../include -I$(INCLUDEDIR) -Wa= ll -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce $(MODF= LAGS) -MD =20 -ifeq ($(INCLUDE_UNPLUG_TEST),1) -OBJS +=3D $(TOBJS) -CFLAGS +=3D -DCONFIG_BLUETOOTH_UNPLUG_TEST -endif - ifeq ($(INCLUDE_BCSP_SUPPORT),1) OBJS +=3D $(BOBJS) CFLAGS +=3D -DCONFIG_BLUETOOTH_SUPPORT_BCSP +endif + +ifeq ($(INCLUDE_PAN),1) +OBJS +=3D $(POBJS) +CFLAGS +=3D -DCONFIG_BLUETOOTH_PAN +endif + +ifeq ($(INCLUDE_UNPLUG_TEST),1) +OBJS +=3D $(TOBJS) +CFLAGS +=3D -DCONFIG_BLUETOOTH_UNPLUG_TEST endif =20 all: $(O_TARGET) |
From: Fredrik S. <fre...@us...> - 2002-01-29 15:57:27
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.220 1.221=20=20=20=20=20=20=20=20=20=20=20 bnep.c 1.2 1.3=20=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Close BNEP sessions before shutting down stack. The diff of the modified file(s): --- bluetooth.c 2002/01/24 16:08:47 1.220 +++ bluetooth.c 2002/01/29 15:57:26 1.221 @@ -256,6 +256,7 @@ =20 #ifdef CONFIG_BLUETOOTH_PAN void bnep_init(void); +void bnep_shutdown(void); u32 bnep_connect_req(u8 *bd_addr); u32 bnep_test(u8 *p); u32 bnep_set_multicast_filter(u8 *filter); @@ -3065,6 +3066,10 @@ =20 #ifdef CONFIG_BLUETOOTH_USE_SECURITY_MANAGER sec_client_shutdown(); /* Inform that stack is getting closed */ +#endif + +#ifdef CONFIG_BLUETOOTH_PAN + bnep_shutdown(); #endif =20 rfcomm_close(); --- bnep.c 2002/01/29 09:00:37 1.2 +++ bnep.c 2002/01/29 15:57:26 1.3 @@ -111,6 +111,8 @@ #define PRINTIPPKT(data, len) #endif =20 +#define BNEP_INTERFACES 7 + /****************** TYPE DEFINITION SECTION ******************************= ***/ =20 /****************** GLOBAL VARIABLE DECLARATION SECTION ******************= ***/ @@ -121,7 +123,7 @@ /****************** LOCAL VARIABLE DECLARATION SECTION *******************= ***/ =20 static u8 bd_addr[6] =3D { 0x00, 0x40, 0x8c, 0xcd, 0x00, 0x00 }; -struct net_device dev_bnep[7]; /* Got 7 Interfaces */ +struct net_device dev_bnep[BNEP_INTERFACES]; static protocol_layer this_layer; =20 /****************** LOCAL FUNCTION DECLARATION SECTION *******************= ***/ @@ -163,9 +165,9 @@ int i, err; struct net_device *d; =20=09 - printk("BNEP driver v0.1 (c) 2001 Axis Communications AB\n"); + printk("BNEP driver v0.1 (c) 2002 Axis Communications AB\n"); D_MISC("Init BNEP interfaces\n"); - for (i =3D 0; i < 7; i++) { + for (i =3D 0; i < BNEP_INTERFACES; i++) { d =3D &dev_bnep[i]; d->init =3D bnep_init_interface; err =3D dev_alloc_name(d, "bnep%d"); @@ -184,6 +186,68 @@ } =20 /*=20 + * Final init of the BNEP driver. + * Must be called after the Bluetooth driver has been completely initalize= d. + * - Registers the BNEP layer with L2CAP. + * - Reads the BD address through HCI. + * - Sets the MAC address =3D the BD address for all BNEP interfaces. + */ +void +bnep_init(void) +{ + int i, j; + char temp[8]; +=09 + DSYS("Initializing BNEP\n"); +=09 + /* Set the confirm and indication functions for the L2CAP-layer */ + this_layer.con_ind =3D bnep_connect_ind; + this_layer.con_pnd =3D bnep_connect_pnd; + this_layer.conf_ind =3D bnep_config_ind; + this_layer.disc_ind =3D bnep_disconnect_ind; + this_layer.con_cfm =3D bnep_connect_cfm; + this_layer.conf_cfm =3D bnep_config_cfm; + this_layer.disc_cfm =3D bnep_disconnect_cfm; + this_layer.receive_data =3D bnep_receive_packet; +=09 + /* Register BNEP in the L2CAP layer. */ + l2cap_register_upper(BNEP_LAYER, &this_layer); +=09 + /* Read BD address (converting to big endian) */ + D_MISC("Read local BD addr\n"); + hci_read_local_bd(bd_addr); + for (i =3D 0; i < 6; i++) { + temp[7-i] =3D bd_addr[i]; + } +=09 + /* Set MAC address for all 7 interfaces. */ + for (j =3D 0; j < BNEP_INTERFACES; j++) { + bnep_set_mac_address(&dev_bnep[j], &temp); + } + + D_MISC("BNEP Initialized\n"); +} + +/* + * Shutdown all BNEP sessions. + */ +void +bnep_shutdown(void) +{ + struct net_local *local; + int i; + + DSYS("Shutting down BNEP\n"); + for (i =3D 0; i < BNEP_INTERFACES; i++) { + local =3D dev_bnep[i].priv; + if (local->l2cap !=3D NULL) { + D_MISC("Disconnecting %s\n", dev_bnep[i].name); + l2ca_disconnect_req(local->l2cap); + } + } +} + +/*=20 * Init routine for BNEP interfaces. */ static int __init @@ -234,49 +298,6 @@ } =20 /*=20 - * Final init of the BNEP driver. - * Must be called after the Bluetooth driver has been completely initalize= d. - * - Registers the BNEP layer with L2CAP. - * - Reads the BD address through HCI. - * - Sets the MAC address =3D the BD address for all BNEP interfaces. - */ -void -bnep_init(void) -{ - int i, j; - char temp[8]; -=09 - DSYS("Initializing BNEP\n"); -=09 - /* Set the confirm and indication functions for the L2CAP-layer */ - this_layer.con_ind =3D bnep_connect_ind; - this_layer.con_pnd =3D bnep_connect_pnd; - this_layer.conf_ind =3D bnep_config_ind; - this_layer.disc_ind =3D bnep_disconnect_ind; - this_layer.con_cfm =3D bnep_connect_cfm; - this_layer.conf_cfm =3D bnep_config_cfm; - this_layer.disc_cfm =3D bnep_disconnect_cfm; - this_layer.receive_data =3D bnep_receive_packet; -=09 - /* Register BNEP in the L2CAP layer. */ - l2cap_register_upper(BNEP_LAYER, &this_layer); -=09 - /* Read BD address (converting to big endian) */ - D_MISC("Read local BD addr\n"); - hci_read_local_bd(bd_addr); - for (i =3D 0; i < 6; i++) { - temp[7-i] =3D bd_addr[i]; - } -=09 - /* Set MAC address for all 7 interfaces. */ - for (j =3D 0; j < 7; j++) { - bnep_set_mac_address(&dev_bnep[j], &temp); - } - - D_MISC("BNEP Initialized\n"); -} - -/* * Open/initialize a BNEP interface. This is called (in the current kernel) * sometime after booting when the 'ifconfig' program is run. * @@ -424,6 +445,7 @@ D_XMIT(__FUNCTION__": Multicast packet, dest =3D %02x:%02x:%02x:%02x:%02= x:%02x\n",=20 eth->h_dest[0], eth->h_dest[1], eth->h_dest[2], eth->h_dest[3], eth->h_dest[3], eth->h_dest[5]); + local->stats.multicast++; =20=09=09 /* Step through filter range by filter range */ for (i =3D 0; (i < BNEP_MAX_MCAST_FILTER_RANGES) && (!send_packet); i++)= { @@ -559,7 +581,7 @@ strip 4 bytes when it comes from the LAN.=20 Found during UPF7 but can't reproduce it here.*/ #if 0 - for(i =3D 0 ; i < 7 ; i++) { + for(i =3D 0 ; i < BNEP_INTERFACES; i++) { other =3D dev_bnep[i].priv; if(other->state !=3D CONNECTED) { continue; @@ -1437,5 +1459,3 @@ =20=09 return 0; } - - |
From: Fredrik S. <fre...@us...> - 2002-01-29 09:00:39
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bnep.c 1.1 1.2=20=20=20=20=20=20=20=20=20=20=20=20=20 bnep_test.c 1.1 1.2=20=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Multicast filters should now work. The diff of the modified file(s): --- bnep.c 2002/01/24 16:08:47 1.1 +++ bnep.c 2002/01/29 09:00:37 1.2 @@ -389,7 +389,7 @@ struct bnep_compressed_ethernet_source_only bnep_c_s; struct bnep_compressed_ethernet bnep_c; void *bhdr; - int i, j, bhdrlen, ethhdrlen =3D sizeof(struct ethhdr), buflen, strip_len= =3D 0; + int i, bhdrlen, ethhdrlen =3D sizeof(struct ethhdr), buflen, strip_len = =3D 0; u16 proto, payload_proto;=20 int send_packet =3D 0; int dest =3D 1; @@ -420,36 +420,29 @@ } =20=09 /* Check multicast filters */ - if (eth->h_dest[0] =3D=3D 1) { - D_XMIT(__FUNCTION__": Multicast or broadcast packet\n"); + if (eth->h_dest[0] & 1) { + D_XMIT(__FUNCTION__": Multicast packet, dest =3D %02x:%02x:%02x:%02x:%02= x:%02x\n",=20 + eth->h_dest[0], eth->h_dest[1], eth->h_dest[2], + eth->h_dest[3], eth->h_dest[3], eth->h_dest[5]); =20=09=09 /* Step through filter range by filter range */ for (i =3D 0; (i < BNEP_MAX_MCAST_FILTER_RANGES) && (!send_packet); i++)= { D_MISC(__FUNCTION__": Trying multicast filter range %d\n",i);=09=09=09 - /* Make sure that destination address is equal or within range */ - /* Double 'i' in order to get the start range in each filter */ - for (j =3D 0; j < 6 && - ((local->filter_multi_addr_list[i*2].addr[j] <=3D eth->h_dest[j])= && - (local->filter_multi_addr_list[i*2+1].addr[j] >=3D eth->h_dest[j= ])); - j++) {=09=09 - /* Each byte in destination address is within filter range */ - if (j >=3D 5) - { + if (memcmp(local->filter_multi_addr_list[i*2].addr, eth->h_dest, 6) >= =3D 0 && + memcmp(local->filter_multi_addr_list[i*2+1].addr, eth->h_dest, 6) <= =3D 0) { D_MISC(__FUNCTION__": Multicast filter range %d OK\n",i); send_packet =3D 1; - break; } } =20 /* All filter ranges have been examined */ - if (i >=3D (BNEP_MAX_MCAST_FILTER_RANGES-1)) { + if (!send_packet) { D_XMIT(__FUNCTION__": Discarding multicast packet\n"); local->stats.tx_dropped++; dev_kfree_skb(skb); return 0; } } - } =20 /* Check protocol filters; first examine if 802.1p header */=20 if (proto =3D=3D 0x8100) { @@ -893,7 +886,7 @@ struct net_device *dev; struct net_local *local; struct bnep_filter_response_msg rsp;=20=20 - int n,i,j, size =3D 0; + int n, i, size =3D 0; bt_tx_buf *tx_buf; u16 *filter; =20=09 @@ -1129,16 +1122,17 @@ } else {=20 /* Set filter */ for (i =3D 0; i < n; i++) { - for (j =3D 0; j < 6; j++) { - local->filter_multi_addr_list[(used_filters+i)*2].addr[j] =3D=20 - data[j*i+j+2]; - local->filter_multi_addr_list[(used_filters+i)*2+1].addr[j] =3D=20 - data[6*(i+1)+j+2]; + print_data("Adding multicast filter: ", data+2+i*12, 12); =20=09=09=09=09=09 - D_MISC("Setting multi addr filter %02x - %02x \n", - local->filter_multi_addr_list[i*2].addr[j], - local->filter_multi_addr_list[i*2+1].addr[j]); - } + /* Start address. */ + memcpy(local->filter_multi_addr_list[(used_filters+i)*2].addr, + data+2+i*12, + 6); + + /* End address. */ + memcpy(local->filter_multi_addr_list[(used= _filters+i)*2+1].addr, + data+2+i*12+6, + 6); } used_filters +=3D n; } --- bnep_test.c 2002/01/24 16:08:47 1.1 +++ bnep_test.c 2002/01/29 09:00:37 1.2 @@ -512,7 +512,10 @@ local =3D dev->priv; l2cap =3D local->l2cap; =20=09 - D_MISC("Set remote protocol filter \n"); + printk("Set remote multicast filter %02x:%02x:%02x:%02x:%02x:%02x - " + "%02x:%02x:%02x:%02x:%02x:%02x", + filter[0], filter[1], filter[2], filter[3], filter[4], filter[5], + filter[6], filter[7], filter[8], filter[9], filter[10], filter[11]); =20=09 bnep.bnep_type =3D BNEP_CONTROL; bnep.bnep_control_type =3D BNEP_FILTER_NET_TYPE_SET_MSG; |
From: tall b. <tal...@ya...> - 2002-01-25 05:50:55
|
I think SCO establishment still has to be fixed for open BT........ --- Marco Schuler <mar...@sc...> wrote: > Hi there > > I'm a new user of OpenBt-Stack. I didn't find enough > documentation on > using it. My problem is the following: How can I > initiate a SCO-link? > What's the data delay of a SCO-link (I should have > less than 10 > milliseconds)? > It would also be fine if somebody could tell me > where to find > good documentations on using the stack. > > Thanks in advance > > Marco > > > > _______________________________________________ > openbt-commit mailing list > ope...@li... > https://lists.sourceforge.net/lists/listinfo/openbt-commit __________________________________________________ Do You Yahoo!? Great stuff seeking new owners in Yahoo! Auctions! http://auctions.yahoo.com |
From: Anders J. <and...@us...> - 2002-01-24 16:10:00
|
The following files were modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bnep.h 1.1 Added bnep_internal.h 1.1 Added The accompanying log: * Intital versions for BNEP. |
From: Anders J. <and...@us...> - 2002-01-24 16:09:27
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- Makefile 1.28 1.29=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Changed to include bnep if PAN is defined. The diff of the modified file(s): --- Makefile 2001/12/21 12:06:33 1.28 +++ Makefile 2002/01/24 16:09:25 1.29 @@ -15,7 +15,7 @@ BOBJS =3D bcsp.o bcsp_datagram.o bcsp_integrity.o bcsp_mux.o \ bcsp_sequence.o bcsp_slip.o =20 -POBJS =3D bnep.o # bnep_proc.o bnep_status_proc.o +POBJS =3D bnep.o bnep_status_proc.o =20 ifeq ($(TOPDIR)/Rules.make,$(wildcard $(TOPDIR)/Rules.make)) =20 |
From: Anders J. <and...@us...> - 2002-01-24 16:08:50
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.219 1.220=20=20=20=20=20=20=20=20=20=20=20 bnep.c 1.1 Added bnep_status_proc.c 1.1 Added bnep_test.c 1.1 Added btmem.c 1.46 1.47=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Register BNEP-procfile. * Added initial version of bnep. * Added bnep tests with UPF testcases. * btmem init now returns ENOMEM on error. The diff of the modified file(s): --- bluetooth.c 2002/01/24 12:43:36 1.219 +++ bluetooth.c 2002/01/24 16:08:47 1.220 @@ -2467,6 +2467,14 @@ procfs_status); } =20 +#ifdef CONFIG_BLUETOOTH_PAN + procfs_status =3D bnep_status_create_proc_file(); + if (procfs_status < 0) { + D_ERR("Could not register proc file bnep_status %d\n", + procfs_status); + } +#endif /* CONFIG_BLUETOOTH_PAN */ + #endif /* CONFIG_BLUETOOTH_PROC */ =20 #ifdef CONFIG_BLUETOOTH_USE_TCI @@ -3220,6 +3228,10 @@ proc_unregister(&proc_root, tci_proc_entry.low_ino); #endif /* CONFIG_BLUETOOTH_USE_TCI */ #endif /* LINUX_VERSION_CODE */ + +#ifdef CONFIG_BLUETOOTH_PAN + bnep_status_remove_proc_file(); +#endif #endif /* CONFIG_BLUETOOTH_PROC */ =20 DSYS("Bluetooth Driver unregistered\n"); --- btmem.c 2002/01/24 12:42:33 1.46 +++ btmem.c 2002/01/24 16:08:47 1.47 @@ -114,7 +114,7 @@ =20 if(!(bt_buf.head =3D (u8*) kmalloc(BT_BUF_SIZE,GFP_KERNEL))) { D_ERR("Can't allocate BT memory buffers"); - return -1; + return -ENOMEM; } =20=09 =20=20=20 |
From: Anders J. <and...@us...> - 2002-01-24 12:43:37
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.218 1.219=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Handle btmem init failure. The diff of the modified file(s): --- bluetooth.c 2002/01/15 11:01:56 1.218 +++ bluetooth.c 2002/01/24 12:43:36 1.219 @@ -1195,8 +1195,8 @@ #ifdef CONFIG_BLUETOOTH_UNPLUG_TEST case BNEPTEST: { - s8 temp[5]; - copy_from_user(&temp, (s32*)arg, 5); + s8 temp[2]; + copy_from_user(&temp, (s32*)arg, 2); printk("BNEP TEST %i\n", temp[0]);=20=20=20 return bnep_test(&temp[0]); } @@ -2627,7 +2627,15 @@ add_timer(&bt_clear_led_timer); #endif =20 - btmem_init(); + if(btmem_init() =3D=3D -1) { + D_ERR("BTMEM init failed"); +#ifdef __CRIS__ + del_timer(&bt_clear_led_timer); + bt_set_leds(NO_BLUETOOTH_ACTIVITY); +#endif + return -1; + } +=09 =20 #ifdef CONFIG_BLUETOOTH_SUPPORT_BCSP if (bt_use_bcsp(-1) && !bcsp_issyncronized()) {=20=20 |
From: Anders J. <and...@us...> - 2002-01-24 12:42:34
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- btmem.c 1.45 1.46=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Check if allocation suceeded before trying to use it :). The diff of the modified file(s): --- btmem.c 2001/11/15 11:18:00 1.45 +++ btmem.c 2002/01/24 12:42:33 1.46 @@ -106,12 +106,17 @@ =20 /****************** FUNCTION DEFINITION SECTION **************************= ***/ =20 -void btmem_init(void) +s32 +btmem_init(void) { /* Allocate memory area */ DSYS("Initialising BTMEM [%d bytes]\n", BT_BUF_SIZE); =20 - bt_buf.head =3D (u8*) kmalloc(BT_BUF_SIZE,GFP_KERNEL); + if(!(bt_buf.head =3D (u8*) kmalloc(BT_BUF_SIZE,GFP_KERNEL))) { + D_ERR("Can't allocate BT memory buffers"); + return -1; + } +=09 =20=20=20 /* Initiate main buffer object */ bt_buf.tail =3D bt_buf.head + BT_BUF_SIZE; |
From: Anders J. <and...@us...> - 2002-01-24 12:41:33
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- l2cap.c 1.127 1.128=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * When retrasmitting info requests we should use the same ID. The diff of the modified file(s): --- l2cap.c 2002/01/06 17:33:04 1.127 +++ l2cap.c 2002/01/24 12:41:31 1.128 @@ -1959,7 +1959,7 @@ return; } =20 - D_TIM(__FUNCTION__ ": current no rtx : %d\n", con->timer.rtx_no); + D_TIM(__FUNCTION__ ": current no rtx : %d\n", con->timers.rtx_no); =20 con->timers.rtx.inuse =3D 0; =20 @@ -2074,8 +2074,7 @@ =20 /* Don't increment ID if retransmission */ if (con->timers.rtx_no =3D=3D 0) - cmd->id =3D set_id(con); /* S -ets sig_id_sent in l2cap_con */ + cmd->id =3D set_id(con); /* Sets sig_id_sent in l2cap_con = */ else DSYS("RTX, use same ID\n"); =20 @@ -2303,7 +2302,12 @@ memcpy(req->data, opt_data, opt_len); =20=20=20 cmd->code =3D SIG_ECHOREQ; - cmd->id =3D get_id(); + + + if (con->timers.rtx_no =3D=3D 0) + cmd->id =3D set_id(con); /* Sets sig_id_sent in l2cap_con = */ + else + DSYS("RTX, use same ID\n"); =20=20=20 cmd->len =3D cpu_to_le16(opt_len); =20 |
From: Anders J. <and...@us...> - 2002-01-24 12:37:41
|
The following file was modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- btmem.h 1.21 1.22=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Init now returns a value. The diff of the modified file(s): --- btmem.h 2001/09/18 10:48:22 1.21 +++ btmem.h 2002/01/24 12:37:40 1.22 @@ -69,7 +69,8 @@ /****************** EXPORTED FUNCTION DECLARATION SECTION ****************= ***/ =20 /* Allocated the whole buffer and initates main object */ -void btmem_init(void); +s32 +btmem_init(void); =20 /* Deallocates the whole buffer */ void btmem_shutdown(void); |
From: Anders J. <and...@us...> - 2002-01-24 12:37:18
|
The following file was modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- btdebug.h 1.43 1.44=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Added missing defines The diff of the modified file(s): --- btdebug.h 2001/12/04 10:01:27 1.43 +++ btdebug.h 2002/01/24 12:37:17 1.44 @@ -175,6 +175,8 @@ #define BNEP_PRINT_DATA 0 #define BNEP_DEBUG_REC 0 #define BNEP_DEBUG_PROC 0 +#define BNEP_DEBUG_DATA 0 +#define BNEP_DEBUG_IPDATA 0 #define BNEP_DBG_STR " BNEP " =20 /***************** BTMEM Debug defines ***********************************= ****/ |
From: Marco S. <mar...@sc...> - 2002-01-23 12:37:34
|
Hi there I'm a new user of OpenBt-Stack. I didn't find enough documentation on using it. My problem is the following: How can I initiate a SCO-link? What's the data delay of a SCO-link (I should have less than 10 milliseconds)? It would also be fine if somebody could tell me where to find good documentations on using the stack. Thanks in advance Marco |
From: Fredrik S. <fre...@us...> - 2002-01-22 11:23:48
|
The following file was modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- modememul.c 1.15 1.15.2.1=20=20=20=20=20=20=20=20 The accompanying log: Fix for weird Widcomm client used in Mercator project. The diff of the modified file(s): --- modememul.c 2001/10/16 16:56:25 1.15 +++ modememul.c 2002/01/22 11:23:47 1.15.2.1 @@ -60,7 +60,7 @@ #include "bt_misc.h" #include "bt_if.h" =20 -#define D(x) //x +#define D(x) x =20 #define PPPDCMD "pppd" =20 @@ -168,6 +168,7 @@ fd_set rfd; =20 D(syslog(LOG_INFO, "Modem emulator starting")); + write(bt_fd, client_server, strlen(client_server)); =20 while (!done) {=20=20 |
From: Fredrik S. <fre...@us...> - 2002-01-18 13:44:40
|
The following file was modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- bt_if.h 1.29 1.30=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Corrected parameter type for BNEPADDMULTICASTFILTER. The diff of the modified file(s): --- bt_if.h 2001/12/04 10:19:54 1.29 +++ bt_if.h 2002/01/18 13:44:39 1.30 @@ -156,7 +156,7 @@ #define BNEPCONNECT _IOW(BT_IOC_MAGIC, 0x29, unsigned char[6]) #define BNEPTEST _IOW(BT_IOC_MAGIC, 0x2a, unsigned char[5]) #define BNEPADDPROTOCOLFILTER _IOW(BT_IOC_MAGIC, 0x2b, unsigned int[2]) -#define BNEPADDMULTICASTFILTER _IOW(BT_IOC_MAGIC, 0x2c, unsigned int[2]) +#define BNEPADDMULTICASTFILTER _IOW(BT_IOC_MAGIC, 0x2c, unsigned char[12]) =20 /* Host Controller & Baseband Commands */ =20 |
From: Fredrik S. <fre...@us...> - 2002-01-18 12:50:33
|
The following file was modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- btcommon.h 1.91 1.92=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Corrected parameter type for BNEPADDMULTICASTFILTER. The diff of the modified file(s): --- btcommon.h 2001/12/04 10:01:27 1.91 +++ btcommon.h 2002/01/18 12:50:32 1.92 @@ -163,7 +163,7 @@ #define BNEPCONNECT _IOW(BT_IOC_MAGIC, 0x29, u8[6]) #define BNEPTEST _IOW(BT_IOC_MAGIC, 0x2a, u8[5]) #define BNEPADDPROTOCOLFILTER _IOW(BT_IOC_MAGIC, 0x2b, u32[2]) -#define BNEPADDMULTICASTFILTER _IOW(BT_IOC_MAGIC, 0x2c, u32[2]) +#define BNEPADDMULTICASTFILTER _IOW(BT_IOC_MAGIC, 0x2c, u8[12]) =20 /* Host Controller & Baseband Commands */ #define HCIRESET _IO(BT_IOC_MAGIC, 0x30) |