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: Anders J. <and...@us...> - 2001-11-22 15:31:31
|
The following file was modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- btd.c 1.33 1.34=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * When not using IPA no options to PPP is created except dev and speedstr. The diff of the modified file(s): --- btd.c 2001/11/22 14:42:52 1.33 +++ btd.c 2001/11/22 15:31:30 1.34 @@ -491,10 +491,6 @@ opts[i++] =3D speedstr; =20=20=20 /* move these to options file ? */ - opts[i++] =3D "crtscts"; - opts[i++] =3D "nopersist"; - opts[i++] =3D "silent"; - opts[i++] =3D "passive"; =20=20=20 /* check if we have used IPA */ if (use_ipa && ipset) @@ -502,6 +498,11 @@ /* FIXME -- maybe parhand can modify ppp options=20 file directly */ =20=20=20=20=20 + opts[i++] =3D "crtscts"; + opts[i++] =3D "nopersist"; + opts[i++] =3D "silent"; + opts[i++] =3D "passive"; +=20=20=20=20 /* Use radius ? */ if (ipset->useradius) { @@ -605,32 +606,6 @@ sprintf(netmask, "%s", inet_ntoa(ipset->netmask)); opts[i++] =3D netmask; } - else - {=20=20=20=20 - strcpy(local_ip, get_local_ip_address()); -=20=20=20=20 - /* local IP */ - sprintf(ip_addresses, "%s:", local_ip); - - /* Use /etc/ppp/options file for remote ppp settings. - IPA is needed for correct multipoint setting or use a=20 - ppp options file for each ttyBT e.g options.ttyBT0,=20 - options.ttyBT1 which contains the remote IP address,=20 - dns, wins etc*/ -=20=20=20=20 - syslog(LOG_INFO, "WARNING: No remote ip addr set, only local %s",=20 - ip_addresses); - - opts[i++] =3D ip_addresses; - - /* always do proxyarp */=20 - opts[i++] =3D "proxyarp"; -=20=20=20=20 - /* ktune only works on pppd version > 2.3.10 */ - /* similar as doing ' echo 1 > /proc/sys/net/ipv4/ip_forward */ - opts[i++] =3D "ktune"; /* enables ip_forwarding */ - - } /* end -- no ipa */ =20=20=20=20 opts[i] =3D NULL; =20=20=20 |
From: Anders J. <and...@us...> - 2001-11-22 14:42:53
|
The following file was modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- btd.c 1.32 1.33=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Added option -I, --use-ipa, to enable btdm to use IPA. The diff of the modified file(s): --- btd.c 2001/10/16 15:02:20 1.32 +++ btd.c 2001/11/22 14:42:52 1.33 @@ -80,6 +80,10 @@ force uart communication to not use CTS and RTS default: flow control activated if defined hardware support it =20 + -I, --use-ipa + enable use of ipa + default: not enabled + e.g ./btdm --reset --speed 460800 --physdev /dev/ttyS0 --local-name OpenBT ./btdm --reset --speed 1000000/1 --physdev /dev/ttyS0 --local-name Open= BT @@ -188,6 +192,8 @@ static int phys_fd =3D -1; /* physical device e.g ttyS0 */ static sigjmp_buf jmpbuffer; /* used to jump back in program after doing r= eset */ =20 +static int use_ipa =3D 0;=20 + /* long option list */ static struct option long_options[] =3D { @@ -198,6 +204,7 @@ { "local-name", 1, NULL, 'n' }, /* set local bluetooth name */ { "reset", 0, NULL, 'R' }, /* reset BT HW */ { "speed", 1, NULL, 's' }, /* uart speed towards hw */ + { "use-ipa", 0, NULL, 'I' }, { 0, 0, 0, 0 } }; =20 @@ -230,7 +237,7 @@ } =20=20=20 /* now parse options */ - while ((opt =3D getopt_long(argc, argv, "fi:m:nRs:u:", + while ((opt =3D getopt_long(argc, argv, "fi:m:nRs:u:I", long_options, &option_index)) !=3D -1) { switch(opt) @@ -275,6 +282,10 @@ D(syslog(LOG_INFO, "phys dev: %s", optarg)); physdev =3D optarg; break; + case 'I': + D(syslog(LOG_INFO, "using IPA")); + use_ipa =3D 1; + break; =20 default: break; @@ -335,7 +346,7 @@ =20 FD_ZERO(&rfd);=20=20 =20 - if (ipa_fd >=3D 0) + if (use_ipa && (ipa_fd >=3D 0)) FD_SET(ipa_fd, &rfd); =20=20=20=20=20 result =3D select(FD_SETSIZE, &rfd, NULL, NULL, &tv); @@ -343,7 +354,8 @@ { case 0: { -#ifdef USE_IPASSIGN + if(ipa_fd >=3D 0) + {=20=20 /* Check for outstanding IPA requests */ int i =3D 0, waiting_iparsp =3D 0; while (i < BT_NBR_DATAPORTS) @@ -359,10 +371,8 @@ =20=20=20=20=20=20=20=20=20 if (waiting_iparsp) break; -#endif -=20=20=20=20=20=20=20=20 + } /* Timeout, check for new rfcomm cons */ - discover_connections(bt_cfd); } break; @@ -487,7 +497,7 @@ opts[i++] =3D "passive"; =20=20=20 /* check if we have used IPA */ - if (ipset) + if (use_ipa && ipset) { /* FIXME -- maybe parhand can modify ppp options=20 file directly */ @@ -814,7 +824,8 @@ PEER(i).ipset =3D NULL; } =20 -#ifdef USE_IPASSIGN + if(use_ipa) + { /* Look for IPA server */ ipa_fd =3D -1; i =3D 1; @@ -841,7 +852,7 @@ D(syslog(LOG_INFO, "Found IPA server")); } }=20 -#endif + } =20 if (modem_emul =3D=3D 1) D(syslog(LOG_INFO, "Using modem emulation")); @@ -873,7 +884,7 @@ phys_fd =3D -1; } =20 - if (ipa_fd !=3D -1) + if (ipa_fd >=3D 0) { D(syslog(LOG_INFO, "Closing connection to IPA")); tcflush(ipa_fd, TCIOFLUSH); |
From: Anders J. <and...@us...> - 2001-11-22 14:06:20
|
The following files were modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.h 1.47 1.48=20=20=20=20=20=20=20=20=20=20=20=20 btcommon.h 1.89 1.90=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Added bt_timer_obj. * Removed some not used vars in l2cap_con-obj. * All structures which use timers should now use the new bt_timer_obj. The diff of the modified file(s): --- bluetooth.h 2001/11/15 15:02:37 1.47 +++ bluetooth.h 2001/11/22 14:06:20 1.48 @@ -101,14 +101,14 @@ /* Handles wakeup of failed blocking function calls */ #ifdef __KERNEL__ #if LINUX_VERSION_CODE >=3D KERNEL_VERSION(2,4,0) -void start_wq_timer(struct timer_list *wq_timer, +void start_wq_timer(struct bt_timer_obj *wq_bt_timer, u32 timeout, wait_queue_head_t *wq); #else -void start_wq_timer(struct timer_list *wq_timer, +void start_wq_timer(struct bt_timer_obj *wq_bt_timer, u32 timeout, struct wait_queue **wq); =20 #endif /* LINUX_VERSION_CODE */ -void release_wq_timer(struct timer_list *wq_timer); +void release_wq_timer(struct bt_timer_obj *wq_bt_timer); #endif /* __KERNEL__ */ =20 #endif --- btcommon.h 2001/10/22 12:57:13 1.89 +++ btcommon.h 2001/11/22 14:06:20 1.90 @@ -299,6 +299,17 @@ #define RFCOMM_TX_HDRSIZE sizeof(rfcomm_tx_buf) #define SDP_TX_HDRSIZE sizeof(sdp_tx_buf) =20 +/****************** Definitiion of common bt_timer_obj struct ************= ***/ +typedef struct bt_timer_obj=20 +{ + u8 inuse; +#ifdef __KERNEL__ + struct timer_list timer; +#else + int timer; +#endif +} bt_timer_obj; + /****************** Some typedefs used in the l2cap_con struct ***********= ***/ =20 typedef u8 BD_ADDR[6]; @@ -320,20 +331,12 @@ /* FIXME -- move all layer specific structs into each layers .h file=20 and fix include order ! */ =20 -/* RTX Actions */ -#define RTX_ACTION_DISCONNECT 0 /* default */ -#define RTX_ACTION_START_ERTX 1 /* during con*/ -#define RTX_ACTION_TERMINATE 2 /* if we tried to disconnect and got no res= p */ - -#define ERTX_ACTION_DISCONNECT 0xf0 /* default */ -#define ERTX_ACTION_TERMINATE 0xf1 - typedef struct l2cap_timer_obj { #ifdef __KERNEL__ - struct timer_list rtx; - struct timer_list ertx; - struct timer_list crtx; /* Maximum negotiation time 120 sec */ + struct bt_timer_obj rtx; + struct bt_timer_obj ertx; + struct bt_timer_obj crtx; /* Maximum negotiation time 120 sec */ #else /* dummy */ int rtx; @@ -341,15 +344,6 @@ int crtx; /* Maximum negotiation time 120 sec */ #endif u16 rtx_no; /* nbr retries */ - u16 rtx_action; /* preferred action when rtx expires */=09 - u16 rtx_inuse; /* to avoid concurrent use */ - - u16 ertx_action; /* preferred action when ertx expires */=09 - u16 ertx_inuse; - -=20=20 - - //struct timeval caller_id; /* used to identify caller */ } __attribute__ ((packed)) l2cap_timer_obj; =20 typedef struct l2cap_con { @@ -385,7 +379,7 @@ s32 conf_rsp_ready; /* indicates if we replied pos on a config req */ =20 /* Fixme -- fix multicall */ - struct l2cap_timer_obj timer; + struct l2cap_timer_obj timers; =20 /* Fixme -- fix all return values according this system */ s32 c_result; /* returns result to higher layers, used together with @@ -521,23 +515,16 @@ #define NO_LINE 256 =20 #ifdef __KERNEL__ -#if LINUX_VERSION_CODE >=3D KERNEL_VERSION(2,4,0) typedef struct bt_ctrl_struct { struct bt_session session[BT_NBR_PORTS]; +#if LINUX_VERSION_CODE >=3D KERNEL_VERSION(2,4,0) wait_queue_head_t connect_wq[BT_NBR_PORTS];=20 wait_queue_head_t any_wq; - s32 nbr_active; - s32 nbr_upper; - s32 ctrl_tty_count; /* number of open file descriptors to ttyBTC */ - s32 tty_last_unthrottled; /* indicated which line that was woken=20 - up last time buffers were below the=20 - unthrottle level */ -} bt_ctrl_struct; #else -typedef struct bt_ctrl_struct { - struct bt_session session[BT_NBR_PORTS]; struct wait_queue *connect_wq[BT_NBR_PORTS];=20 struct wait_queue *any_wq; +#endif + struct bt_timer_obj bt_timer[BT_NBR_PORTS]; s32 nbr_active; s32 nbr_upper; s32 ctrl_tty_count; /* number of open file descriptors to ttyBTC */ @@ -545,7 +532,6 @@ up last time buffers were below the=20 unthrottle level */ } bt_ctrl_struct; -#endif /* LINUX_VERSION_CODE */ #endif /* __KERNEL__ */ =20 typedef struct bt_stat_struct @@ -574,6 +560,9 @@ u32 serport_name_length; u8 serport_name[64]; } serport_profile_info; + + + =20 #endif /****************** END OF FILE btcommon.h *******************************= ***/ |
From: Anders J. <and...@us...> - 2001-11-22 14:04:01
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- l2cap_con.c 1.11 1.12=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Use the new timer object and make sure there aren't no outstanding timers when removing a connection. The diff of the modified file(s): --- l2cap_con.c 2001/09/18 12:01:05 1.11 +++ l2cap_con.c 2001/11/22 14:04:00 1.12 @@ -136,8 +136,10 @@ free_con_list(void) { D_CON(__FUNCTION__ ": Freeing connection list\n"); - while (con_list.count) + while (con_list.count) { delete_con(con_list.first); + } +=09 D_CON(__FUNCTION__ ": Connection list removed\n"); }=20 =20 @@ -191,11 +193,9 @@ con->c_status =3D 0; con->c_flags =3D 0; =20 - con->timer.rtx_action =3D RTX_ACTION_DISCONNECT; - con->timer.ertx_action =3D ERTX_ACTION_DISCONNECT; - con->timer.rtx_inuse =3D 0; - con->timer.ertx_inuse =3D 0; - con->timer.rtx_no =3D 0; + con->timers.rtx.inuse =3D 0; + con->timers.ertx.inuse =3D 0; + con->timers.rtx_no =3D 0; =20 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,4,0) con->wq =3D NULL; @@ -436,6 +436,17 @@ /* Issue a warning if connection is not in CLOSED */ if (con->current_state !=3D CLOSED) D_ERR("Deleting an active connection\n"); +=09 + /* Make sure we don't have any outstanding timers on + this connection */ + if(con->timers.rtx.inuse) { + wake_up_interruptible(&con->wq); + del_timer(&con->timers.rtx.timer); + } + if(con->timers.ertx.inuse) { + wake_up_interruptible(&con->wq); + del_timer(&con->timers.ertx.timer); + } =20 if (con_list.count =3D=3D 1) { /* Last element */ |
From: Anders J. <and...@us...> - 2001-11-22 14:02:44
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.213 1.214=20=20=20=20=20=20=20=20=20=20=20 l2cap.c 1.124 1.125=20=20=20=20=20=20=20=20=20=20=20 rfcomm.c 1.128 1.129=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * wq_timers now use a new bt_timer_obj to prevent adding the same timer twi= ce. * l2cap ertx and rtx timers changed to the new one. * One bt_timer on each tty added. * Disable ertx when we receive a connection_complete after pending. * bt_shutdown now disable pagescan to prevent any new connections. The diff of the modified file(s): --- bluetooth.c 2001/11/15 15:01:57 1.213 +++ bluetooth.c 2001/11/22 14:02:41 1.214 @@ -312,8 +312,6 @@ static tty_linebuffer tty_linebuf; #endif /* BT_USELINEBUF */ =20 -static struct timer_list bt_timer; - #define BT_CON_TIMEOUT (10*HZ) =20 /****************** FUNCTION DEFINITION SECTION **************************= ***/ @@ -1881,9 +1879,10 @@ =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 /* sleep if not yet connected */ if (bt_ctrl.session[line].connect_status =3D=3D -1) { - start_wq_timer(&bt_timer, BT_CON_TIMEOUT,=20 + start_wq_timer(&bt_ctrl.bt_timer[line], BT_CON_TIMEOUT,=20 &bt_ctrl.connect_wq[line]); interruptible_sleep_on(&bt_ctrl.connect_wq[line]); + release_wq_timer(&bt_ctrl.bt_timer[line]); } return bt_ctrl.session[line].connect_status; } @@ -1914,11 +1913,7 @@ don't appear to be working out. --gmcnutt */ - /* fixme -- we probably need a lock on this timer since - multiple processes could be trying to use it at the - same time... or maybe use one timer per session. - */ - start_wq_timer(&bt_timer, BT_CON_TIMEOUT,=20 + start_wq_timer(&bt_ctrl.bt_timer[line], BT_CON_TIMEOUT,=20 &bt_ctrl.connect_wq[line]); =20 /* The timeout routine doesn't have a hendle to our=20 @@ -1932,6 +1927,7 @@ =20 BT_DRIVER(__FUNCTION__ ": Sleep on line %d\n", line); interruptible_sleep_on(&bt_ctrl.connect_wq[line]); + release_wq_timer(&bt_ctrl.bt_timer[line]); =20 /*=20 * If the connect_status is >=3D 0, then the lower @@ -2052,7 +2048,7 @@ BT_DRIVER(__FUNCTION__ ": Line %d [%s]\n", line, psmname(psm)); =20 - release_wq_timer(&bt_timer); + release_wq_timer(&bt_ctrl.bt_timer[line]); wake_up_interruptible(&bt_ctrl.connect_wq[line]); wake_up_interruptible(&bt_ctrl.any_wq); break; @@ -2062,7 +2058,7 @@ bt_ctrl.session[line].connect_status =3D status; BT_DRIVER(__FUNCTION__ ": Line %d [%s]\n", line, psmname(psm)); BT_DRIVER(__FUNCTION__ ": Wake up line %d\n", line); - release_wq_timer(&bt_timer); + release_wq_timer(&bt_ctrl.bt_timer[line]); wake_up_interruptible(&bt_ctrl.connect_wq[line]); wake_up_interruptible(&bt_ctrl.any_wq); break; @@ -2137,9 +2133,10 @@ =20 /* Sleep if not yet disconnected */ if (bt_ctrl.session[line].disconnect_status =3D=3D -1) { - start_wq_timer(&bt_timer, BT_CON_TIMEOUT,=20 + start_wq_timer(&bt_ctrl.bt_timer[line], BT_CON_TIMEOUT,=20 &bt_ctrl.connect_wq[line]); interruptible_sleep_on(&bt_ctrl.connect_wq[line]); + release_wq_timer(&bt_ctrl.bt_timer[line]); } =20=09=09 return bt_ctrl.session[line].disconnect_status; @@ -2185,7 +2182,7 @@ =20 bt_ctrl.session[line].disconnect_status =3D status; =20 - release_wq_timer(&bt_timer); + release_wq_timer(&bt_ctrl.bt_timer[line]); wake_up_interruptible(&bt_ctrl.connect_wq[line]); } =20 @@ -2546,7 +2543,6 @@ } } =20 - s32 bt_init_stack(void) { @@ -2698,20 +2694,21 @@ s32 i; BT_DRIVER("Initialising bt ctrl struct\n"); =20 -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,4,0) for (i =3D 0; i < BT_NBR_PORTS; i++) { + bt_ctrl.bt_timer[i].inuse =3D 0; +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,4,0) bt_ctrl.connect_wq[i] =3D NULL; - bt_reset_session(i); - } - bt_ctrl.any_wq =3D NULL; #else - for (i =3D 0; i < BT_NBR_PORTS; i++) { init_waitqueue_head(&bt_ctrl.connect_wq[i]); +#endif bt_reset_session(i); } + +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,4,0) + bt_ctrl.any_wq =3D NULL; +#else init_waitqueue_head(&bt_ctrl.any_wq); #endif - bt_ctrl.nbr_upper =3D 0; bt_ctrl.nbr_active =3D 0; bt_ctrl.tty_last_unthrottled =3D 0; @@ -2981,11 +2978,16 @@ struct bt_session *bt; DSYS("Shutting down bluetooth stack\n"); =20 + /* Disable page scan as we don't want any new connections now */ + DSYS("Disabling page scan\n"); + + hci_write_scan_enable(0x00); if (bt_stack_initiated) { if (!bt_dfu_mode(-1)) { /* disconnect all active connections */ for (i =3D 0; i < BT_NBR_DATAPORTS;i++) { bt =3D &bt_ctrl.session[i]; + release_wq_timer(&bt_ctrl.bt_timer[i]); if ((bt->state =3D=3D BT_ACTIVE) ||=20 (bt->state =3D=3D BT_LOWERCONNECTED)) { DSYS("Disconnecting dlci %d on line %d\n",=20 @@ -3064,32 +3066,43 @@ } } =20 +/* FIXME: Make a general sleepfunction a la L2ca_wait and let the this fun= ction handle all + sleeping. Add a waitqueue object to the timer and let timerdata=3Dbt_ti= mer_obj to set + inuse=3D0 if we timeout */ + #if LINUX_VERSION_CODE >=3D KERNEL_VERSION(2,4,0) void -start_wq_timer(struct timer_list *wq_timer, +start_wq_timer(struct bt_timer_obj *wq_bt_timer, u32 timeout, wait_queue_head_t *wq) #else void -start_wq_timer(struct timer_list *wq_timer, +start_wq_timer(struct bt_timer_obj *wq_bt_timer, u32 timeout, struct wait_queue **wq) #endif /* LINUX_VERSION_CODE */ { - init_timer(wq_timer); - wq_timer->function =3D wq_timeout; - wq_timer->data =3D (unsigned long)wq; - wq_timer->expires =3D jiffies + timeout; - add_timer(wq_timer); -// printk(__FUNCTION__ ": wq: 0x%x, timer: 0x%x\n", wq, wq_timer); + if(wq_bt_timer->inuse) { + D_ERR(__FUNCTION__ ": timer already used\n"); + return; + } +=09 + wq_bt_timer->inuse =3D 1; + init_timer(&wq_bt_timer->timer); + wq_bt_timer->timer.function =3D wq_timeout; + wq_bt_timer->timer.data =3D (unsigned long)wq; + wq_bt_timer->timer.expires =3D jiffies + timeout; + add_timer(&wq_bt_timer->timer); } =20 =20 /* fixme -- only works for one function call at a time */ void -release_wq_timer(struct timer_list *wq_timer) +release_wq_timer(struct bt_timer_obj *wq_bt_timer) { - del_timer(wq_timer); -// printk(__FUNCTION__ ": timer: 0x%x\n", wq_timer); + if(wq_bt_timer->inuse =3D=3D 1) { + del_timer(&wq_bt_timer->timer); + wq_bt_timer->inuse =3D 0; } +} =20 void wq_timeout(unsigned long ptr) @@ -3100,7 +3113,6 @@ struct wait_queue **wq =3D (struct wait_queue **)ptr; #endif /* LINUX_VERSION_CODE */ DSYS(__FUNCTION__ "\n"); - /* wake up wait queue */ wake_up_interruptible(wq); } --- l2cap.c 2001/11/15 15:52:15 1.124 +++ l2cap.c 2001/11/22 14:02:41 1.125 @@ -995,6 +995,7 @@ =20 #ifdef CONFIG_BLUETOOTH_L2CAP_USE_TIMERS disable_rtx(con); + disable_ertx(con); #endif ENTERSTATE(con, CONFIG); PRINTSTATE(con); @@ -1274,6 +1275,7 @@ return; } =20=20 +=20 /* FIXME - add check with control block if this bd_addr is allowed */ =20 /* We are server and creates an l2cap connection object=20 @@ -1940,7 +1942,6 @@ } #endif /* do some paranoia checks */ - if (PARANOIA_CHECKCON(con)) { D_ERR(__FUNCTION__ ": Paranoia check failed\n"); return; @@ -1948,9 +1949,9 @@ =20 D_TIM(__FUNCTION__ ": current no rtx : %d\n", con->timer.rtx_no); =20 - con->timer.rtx_inuse =3D 0; + con->timers.rtx.inuse =3D 0; =20 - if (con->timer.rtx_no =3D=3D MAX_NO_RTX) { + if (con->timers.rtx_no =3D=3D MAX_NO_RTX) { con->c_status =3D CSTATUS_MAX_NO_RTX; =20 D_TIM(__FUNCTION__ ": Max number of retransmit reached\n"); @@ -1963,9 +1964,9 @@ l2ca_wakeup("rtx_timeout", con); =20 /* reset rtx counter */ - con->timer.rtx_no =3D 0; + con->timers.rtx_no =3D 0; } else { - con->timer.rtx_no++; + con->timers.rtx_no++; l2ca_timeoutind(con);=09 } =20 @@ -1980,13 +1981,14 @@ l2cap_con *con; D_TIM(__FUNCTION__ "\n"); con =3D (l2cap_con*)ptr; - /* do paranoia check */ if (PARANOIA_CHECKCON(con)) { D_ERR(__FUNCTION__ ": Paranoia check failed\n"); return; } =20 + con->timers.ertx.inuse =3D 0; + con->c_status =3D CSTATUS_ERTX_TIMEOUT; l2ca_wakeup("ertx_timeout", con); } @@ -2059,7 +2061,7 @@ cmd->code =3D SIG_CONREQ; =20 /* Don't increment ID if retransmission */ - if (con->timer.rtx_no =3D=3D 0) + if (con->timers.rtx_no =3D=3D 0) cmd->id =3D set_id(con); /* S ets sig_id_sent in l2cap_con */ else @@ -2182,7 +2184,7 @@ cmd->code =3D SIG_CONFREQ; =20 /* Don't increment ID if retransmission */ - if (con->timer.rtx_no =3D=3D 0) + 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"); @@ -2241,7 +2243,7 @@ cmd->code =3D SIG_DISCREQ; =20=20=20=20=20=20=20=20=20 /* Don't increment ID if retransmission */ - if (con->timer.rtx_no =3D=3D 0) + 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"); @@ -2992,8 +2994,8 @@ { /* multiply by 2 each rtx */ =20 - if (con->timer.rtx_no > 0) - timeout =3D timeout*(2 << (con->timer.rtx_no - 1)); + if (con->timers.rtx_no > 0) + timeout =3D timeout*(2 << (con->timers.rtx_no - 1)); =20 /* FIXME -- use flush timeout to calculate number of retransmissions */ @@ -3001,18 +3003,18 @@ D_TIM("Starting RTX timer (%d sec)\n", timeout); =20 /* fixme -- add timer list for multiple calls */ - if (con->timer.rtx_inuse) { + if (con->timers.rtx.inuse) { D_ERR(__FUNCTION__ ": timer already used\n"); return; } =20 #ifdef __KERNEL__=09 - init_timer(&con->timer.rtx); - con->timer.rtx.function =3D l2cap_rtx_timeout; - con->timer.rtx.data =3D (unsigned long)con; - con->timer.rtx.expires =3D jiffies + timeout*HZ; - con->timer.rtx_inuse =3D 1; - add_timer(&con->timer.rtx);=20=20 + init_timer(&con->timers.rtx.timer); + con->timers.rtx.timer.function =3D l2cap_rtx_timeout; + con->timers.rtx.timer.data =3D (unsigned long)con; + con->timers.rtx.timer.expires =3D jiffies + timeout*HZ; + con->timers.rtx.inuse =3D 1; + add_timer(&con->timers.rtx.timer);=20=20 =20 #else /* Usermode stack */ =20 @@ -3046,11 +3048,10 @@ { D_TIM("Disabling RTX timer\n"); #ifdef __KERNEL__ - if (con->timer.rtx_inuse) { - del_timer(&con->timer.rtx); - con->timer.rtx_inuse =3D 0; - con->timer.rtx_no =3D 0; - con->timer.rtx_action =3D RTX_ACTION_DISCONNECT; + if (con->timers.rtx.inuse) { + del_timer(&con->timers.rtx.timer); + con->timers.rtx.inuse =3D 0; + con->timers.rtx_no =3D 0; } else D_TIM("RTX never started\n"); #else @@ -3065,18 +3066,18 @@ { D_TIM("Starting ERTX timer (%d sec)\n", timeout); =20 - if (con->timer.ertx_inuse) { + if (con->timers.ertx.inuse) { D_TIM(__FUNCTION__ ": timer already used\n"); return; } =20 #ifdef __KERNEL__ - init_timer(&con->timer.ertx); - con->timer.ertx.function =3D l2cap_ertx_timeout; - con->timer.ertx.data =3D (unsigned long)con; - con->timer.ertx.expires =3D jiffies + timeout*HZ; - con->timer.ertx_inuse =3D 1; - add_timer(&con->timer.ertx); + init_timer(&con->timers.ertx.timer); + con->timers.ertx.timer.function =3D l2cap_ertx_timeout; + con->timers.ertx.timer.data =3D (unsigned long)con; + con->timers.ertx.timer.expires =3D jiffies + timeout*HZ; + con->timers.ertx.inuse =3D 1; + add_timer(&con->timers.ertx.timer); #else /* fixme */ con->timer.ertx_inuse =3D 1; @@ -3088,17 +3089,15 @@ { D_TIM("Disabling ERTX timer\n"); #ifdef __KERNEL__ - if (con->timer.ertx_inuse) { - del_timer(&con->timer.ertx); - con->timer.ertx_inuse =3D 0; - con->timer.ertx_action =3D ERTX_ACTION_DISCONNECT; + if (con->timers.ertx.inuse) { + del_timer(&con->timers.ertx.timer); + con->timers.ertx.inuse =3D 0; } else D_TIM("ERTX never started\n"); #else /* Usermode stack */ /* FIXME */ D_ERR("disable_ertx FIXME\n"); - con->timer.ertx_inuse =3D 0; - con->timer.ertx_action =3D ERTX_ACTION_DISCONNECT; + con->timers.ertx.inuse =3D 0; #endif } #endif /* CONFIG_BLUETOOTH_L2CAP_USE_TIMERS */ --- rfcomm.c 2001/10/23 10:10:28 1.128 +++ rfcomm.c 2001/11/22 14:02:41 1.129 @@ -506,13 +506,13 @@ rfcomm_con rfcomm_con_list[BT_NBR_DATAPORTS]; =20 #ifdef __KERNEL__ -static struct timer_list rfcomm_timer; +static struct bt_timer_obj rfcomm_timer; #endif =20 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,4,0) -static struct wait_queue *rfcomm_disconnect_wq =3D NULL; +struct wait_queue *rfcomm_disconnect_wq; #else -static wait_queue_head_t rfcomm_disconnect_wq; +wait_queue_head_t rfcomm_disconnect_wq; #endif /* LINUX_VERSION_CODE */ =20 rpn_values rpn_val; @@ -553,12 +553,6 @@ s32 rfcomm_module_init(void) { -#ifdef __KERNEL__ -#if LINUX_VERSION_CODE >=3D KERNEL_VERSION(2,4,0) - init_waitqueue_head(&rfcomm_disconnect_wq); -#endif /* LINUX_VERSION_CODE */ -#endif /* __KERNEL__ */ - return 0; } =20 @@ -607,6 +601,16 @@ rpn_val.xoff_u8 =3D 0x13; memset(&rpn_val.pm, 0 , 2); /* Set the mask to zero */ =20=20=20=20=20=20=20=20=20 + rfcomm_timer.inuse =3D 0; +=20=20=20=20 +#ifdef __KERNEL__ +#if LINUX_VERSION_CODE >=3D KERNEL_VERSION(2,4,0) + init_waitqueue_head(&rfcomm_disconnect_wq); +#else + rfcomm_disconnect_wq =3D NULL; +#endif +#endif /* __KERNEL__ */ + #ifdef CONFIG_BLUETOOTH_USE_SECURITY_MANAGER rfcomm_sec_man_init(); #endif @@ -650,6 +654,9 @@ =20=20=20 DSYS("Shutting down RFCOMM\n"); =20 + /* Make sure we don't have any outstanding timers */ + release_wq_timer(&rfcomm_timer); + /* First try disconnecting */ for (i =3D 0; i < BT_NBR_DATAPORTS; i++) { rfcomm_con *rfcomm =3D get_rfcomm_con(i); @@ -667,7 +674,6 @@ for (i =3D 0; i < BT_NBR_DATAPORTS; i++) { rfcomm_reset_con(i); } - } =20 /* This function creates an rfcomm connection over the control channel DCL= I 0 */ @@ -778,6 +784,7 @@ /* FIXME -- check that we haven't already received=20 disconnect 'acknowledge' */ interruptible_sleep_on(&rfcomm_disconnect_wq); + release_wq_timer(&rfcomm_timer); =20 /* Check that rfcomm session really disconnected */ /* FIXME -- add timer obj with status in rfcomm obj */ @@ -1181,7 +1188,6 @@ =20=09=09=09=09 /* this will take down l2cap aswell */ wake_up_interruptible(&rfcomm_disconnect_wq); -=09=09=09=09 } else { /* Data channel */ s32 tmp; |
From: anonym a. <enz...@ho...> - 2001-11-19 21:41:43
|
I appreciate comments on the following idea: As WLan 802.11 offers more users and bandwith than bluetooth the following multi module Lan acces point should be able to compete with it for applications like public hot spot, wireless university, etc: +---------------------------------------------+ | | | +---------+ +---------+ | | | stack 1 | | stack 2 | ...+-----+ | 100bt ethernet | +---+-----+ +---+-----+ | pppd| +------------- | | ttyBT1 | ttyBT2 +-----+ | | +--------------+-------+ | | | | | +----------+-----------+ | | | bluetooth usb driver | | | +----------+-----------+ | +-------------------- | ----------------------+ |usb bus +----------+------------+ | usb hub | +-+-----+----+----+-...-+ | | ..l. | module1 module2 module 10 From the above drawing you can conclude the I want to connect up to 10 bluetooth modules via one or more hubs to the lan access point, the modules handles by 10 incarnations of a bluetooth stack ( e.g. openbt ). As 1 module generates about 700 kb/s traffic, USB bus should be able to handle the overall traffic of about 7Mb/s and that bandwith is about the order of magnitude like 802.11b. About 77 bluetooth clients could be handled by this lan access point server, more than most 802.11b lan acces servers can handle. My question: Will the interference of the 10 parallel piconets reduce the bandwith dramatically or only negligible ? Looking forward to your comments enzian99 PS: by posting this message all rights of intellectual property are transfer from me to bluetooth community, following the spirit of the founders of SIG (especially ericsson). _________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp |
From: anonym a. <enz...@ho...> - 2001-11-19 21:16:35
|
I appreciate comments on the following idea: As WLan 802.11 offers more users than bluetooth the following multi module Lan acces point should be able to compete with it for applications like public hot spot, wireless university, etc: +---------------------------------------------+ | | | +---------+ +---------+ | | | stack 1 | | stack 2 | ...+-----+ | 100bt ethernet | +---+-----+ +---+-----+ | pppd| +------------- | | | +-----+ | | +--------------+-------+ | | | | | +----------+-----------+ | | | bluetooth usb driver | | | +----------+-----------+ | +-------------------- | ----------------------+ |usb bus +----------+------------+ | usb hub | +-+-----+----+----+-...-+ | | ..l. | module1 module2 module 10 From the following drawing you can conclude the I want to connect up to 10 bluetooth modules via one or more hubs to the lan access point, which are services by 10 incarnations _________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp |
From: Peter K. <pk...@us...> - 2001-11-19 11:29:31
|
The following file was modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- btconfig.h 1.32 1.33=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Only define configuration options here if neither CONFIG_BLUETOOTH nor CONFIG_BLUETOOTH_MODULE is set. The diff of the modified file(s): --- btconfig.h 2001/07/31 19:00:28 1.32 +++ btconfig.h 2001/11/19 11:29:29 1.33 @@ -49,7 +49,7 @@ * this next section. See Config.in in the source directory. * --gmcnutt */ -#ifndef CONFIG_BLUETOOTH +#if !defined(CONFIG_BLUETOOTH) && !defined(CONFIG_BLUETOOTH_MODULE) /****************** * General * ******************/ @@ -116,7 +116,7 @@ /*************** * SDP * ***************/ -#endif /* CONFIG_BLUETOOTH */ +#endif /* !CONFIG_BLUETOOTH && !CONFIG_BLUETOOTH_MODULE */ =20 /*************************************************************************= **/ =20 |
From: Peter K. <pk...@us...> - 2001-11-19 08:43:03
|
The following file was modified in apps/bluetooth/sdp_server: Name Old version New version Comment ---- ----------- ----------- ------- sdp_server.c 1.30 1.31=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Use <> instead of "" when including xmlparse.h The diff of the modified file(s): --- sdp_server.c 2001/08/22 17:46:37 1.30 +++ sdp_server.c 2001/11/19 08:43:02 1.31 @@ -46,7 +46,8 @@ #include <syslog.h> #include <unistd.h> =20 -#include "xmlparse.h" +#include <xmlparse.h> + #include "sdp_server.h" #include "sdp_parser.h" =20 |
From: Anders J. <and...@us...> - 2001-11-15 15:52:16
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- l2cap.c 1.123 1.124=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Changed timeouts to not take any action except unlocking waitqueues. * No more use of connection objects after a deletion :). The diff of the modified file(s): --- l2cap.c 2001/10/22 13:25:54 1.123 +++ l2cap.c 2001/11/15 15:52:15 1.124 @@ -210,7 +210,7 @@ static void l2cap_ertx_timeout(unsigned long ptr); #endif =20 -static void start_rtx(l2cap_con *con, unsigned short timeout, unsigned sho= rt action); +static void start_rtx(l2cap_con *con, unsigned short timeout); static void disable_rtx(l2cap_con *con); =20 static void start_ertx(l2cap_con *con, unsigned short timeout); @@ -1046,7 +1046,6 @@ l2ca_wakeup("Got connect rsp neg", con); =20=09=09=09 ENTERSTATE(con, CLOSED); - delete_con(con); } break; =20=20=20=20=20=20=20=20 @@ -1381,10 +1380,10 @@ =20=20=20=20=20=20=20 ENTERSTATE(con, W4_L2CAP_CONNECT_RSP); PRINTSTATE(con); -=09=09=09 - l2ca_wakeup(__FUNCTION__, con); } =20 +=09=09 + return 1; } else { /* neg cfm */ @@ -1576,6 +1575,7 @@ retval =3D lp_connect_req(con->remote_bd); if(retval < 0) { D_ERR(__FUNCTION__ ": failed (status %d)\n", retval); + delete_con(con); return retval; } =20 @@ -1594,19 +1594,45 @@ con->c_status =3D CSTATUS_RTX_TIMEOUT; =20 /* Leave loop when either status failed or success */ - while (con->c_status =3D=3D CSTATUS_RTX_TIMEOUT) { + do { /* baseband is up, now initiate send connect req */ - retval =3D l2cap_connect_req(con, con->psm); - if(retval < 0) { + if((retval =3D l2cap_connect_req(con, con->psm)) < 0) {=20 + /* This can be a result of insufficient memory and it's the=20=20 + callers responsibility to take proper action */ D_ERR(__FUNCTION__ ": failed (status %d)\n", retval); + if(!tmpcon) { + lp_disconnect(con->hci_hdl); + } + ENTERSTATE(con, CLOSED); + delete_con(con); + return retval; } /* wait until we received a response or after timeout */ l2ca_wait(__FUNCTION__ ": wait rsp", con); + } while (con->c_status =3D=3D CSTATUS_RTX_TIMEOUT); +=09 + + if (con->c_status !=3D RES_SUCCESS) { + if(con->c_status =3D=3D CSTATUS_ERTX_TIMEOUT) { + l2ca_disconnect_ind(con); } =20 - if (con->c_status =3D=3D CSTATUS_MAX_NO_RTX && !retval) { + if(!tmpcon) { + lp_disconnect(con->hci_hdl); + } +=09=09 + switch(con->c_status) { + case CSTATUS_MAX_NO_RTX: retval =3D -MSGCODE(MSG_LAYER_L2CAP, L2CAP_RTX_TIMEOUT); + break; +=09=09=09 + default:=20=20=20 + retval =3D -MSGCODE(MSG_LAYER_L2CAP, con->c_status); } +=09=09 + ENTERSTATE(con, CLOSED); + delete_con(con); + } return retval; } =20 @@ -1679,10 +1705,8 @@ do { retval =3D l2cap_disconnect_req(con); if(retval < 0) { - /* This will result in a timeout and we need to try again - as the error is a result of insufficent space in our - memorypool and we try again after a timeout */ D_ERR(__FUNCTION__ ": Failed (status %d)\n", retval); + return retval; } =20=09=09=09 l2ca_wait(__FUNCTION__, con); @@ -1695,23 +1719,17 @@ return -MSGCODE(MSG_LAYER_L2CAP, L2CAP_INVALID_STATE);=20=20=20=20 } =20=09 - if(con->c_status !=3D CSTATUS_MAX_NO_RTX) { - if (con->current_state =3D=3D CLOSED) {=09 - /* remove l2cap connection */ - delete_con(con); - } else { - /* FIXME: If we reach here, should we delete the connection? */ - D_ERR(__FUNCTION__ ": Failed (Connection not closed)"); - PRINTSTATE(con); - retval =3D -MSGCODE(MSG_LAYER_L2CAP, L2CAP_FAILED); - } - } + ENTERSTATE(con, CLOSED); =20=09 + if (con->c_status =3D=3D CSTATUS_MAX_NO_RTX) { + retval =3D -MSGCODE(MSG_LAYER_L2CAP, L2CAP_RTX_TIMEOUT); + l2ca_disconnect_cfm(con); + } =20=09 - /* fixme -- if we want to keep baseband connection we must=20 - leave the l2cap connection which holds the hci handle=20 - simply just clear l2cap params but keep hci handle ! */ + delete_con(con); =20=09 + /* If this is the last l2cap-session on the baseband connection we + disconnect the baseband as well */ if (count_con(tmp_hdl) =3D=3D 0) { DSYS("l2ca_disconnect_req : (C) no more l2cap cons\n"); DSYS("Shutdown baseband\n"); @@ -1935,7 +1953,7 @@ if (con->timer.rtx_no =3D=3D MAX_NO_RTX) { con->c_status =3D CSTATUS_MAX_NO_RTX; =20 - D_TIM("Connection unresponsive\n"); + D_TIM(__FUNCTION__ ": Max number of retransmit reached\n"); =20 show_con("Connection unresponsive\n", con); =20 @@ -1946,17 +1964,6 @@ =20 /* reset rtx counter */ con->timer.rtx_no =3D 0; - - if (con->timer.rtx_action =3D=3D RTX_ACTION_START_ERTX) { - /* start ertx timer */ - D_TIM("Starting ERTX\n"); - start_ertx(con, ERTX_TIMEOUT); - } else if (con->timer.rtx_action =3D=3D RTX_ACTION_TERMINATE) { - D_TIM("Removing connection\n"); - l2ca_disconnect_ind(con); - ENTERSTATE(con, CLOSED); - delete_con(con); - } } else { con->timer.rtx_no++; l2ca_timeoutind(con);=09 @@ -1980,20 +1987,8 @@ return; } =20 - if (con->timer.ertx_action =3D=3D ERTX_ACTION_TERMINATE) { - D_TIM("Removing connection\n"); - l2ca_disconnect_ind(con); - ENTERSTATE(con, CLOSED); - delete_con(con); - } else if (con->timer.ertx_action =3D=3D ERTX_ACTION_DISCONNECT) { -=09=09 - D_TIM("Disconnect connection\n"); - /* set dont sleep flag so that we wont do sleep=20 - when not running in usermode context */ - con->c_flags |=3D FLAG_DONTSLEEP; - ENTERSTATE(con, CONFIG); /* CERT HACK ! */ - l2ca_disconnect_req(con); - } + con->c_status =3D CSTATUS_ERTX_TIMEOUT; + l2ca_wakeup("ertx_timeout", con); } =20 #endif /* CONFIG_BLUETOOTH_L2CAP_USE_TIMERS */ @@ -2082,7 +2077,7 @@ =20=09 #ifdef CONFIG_BLUETOOTH_L2CAP_USE_TIMERS /* start retransmission timer */ - start_rtx(con, RTX_TIMEOUT, RTX_ACTION_START_ERTX); + start_rtx(con, RTX_TIMEOUT); #endif return hci_send_data(tx); } @@ -2210,7 +2205,7 @@ print_data("l2cap options: ", (char*)opt , opt_len); #ifdef CONFIG_BLUETOOTH_L2CAP_USE_TIMERS /* start retransmission timer */ - start_rtx(con, RTX_TIMEOUT, RTX_ACTION_START_ERTX); + start_rtx(con, RTX_TIMEOUT); #endif return hci_send_data(tx); } @@ -2260,7 +2255,7 @@ =20 #ifdef CONFIG_BLUETOOTH_L2CAP_USE_TIMERS /* start retransmission timer */ - start_rtx(con, RTX_TIMEOUT, RTX_ACTION_TERMINATE); + start_rtx(con, RTX_TIMEOUT); #endif return hci_send_data(tx); } @@ -2308,7 +2303,7 @@ tx->cur_len =3D L2CAP_HDRSIZE + payload_len; =20 #ifdef CONFIG_BLUETOOTH_L2CAP_USE_TIMERS - start_rtx(con, RTX_TIMEOUT, RTX_ACTION_DISCONNECT); + start_rtx(con, RTX_TIMEOUT); #endif return hci_send_data(tx); } @@ -2393,7 +2388,7 @@ tx->cur_len =3D L2CAP_HDRSIZE + payload_len; /* Increased when lower layers add header data */ #ifdef CONFIG_BLUETOOTH_L2CAP_USE_TIMERS - start_rtx(con, RTX_TIMEOUT, RTX_ACTION_TERMINATE); + start_rtx(con, RTX_TIMEOUT); #endif return hci_send_data(tx); } @@ -2861,6 +2856,7 @@ retval =3D lp_connect_req(con->remote_bd); if(retval < 0) { D_ERR(__FUNCTION__ ": lp_connect_req failed (status %d)\n", retval); + delete_con(con); return retval; } =20 @@ -2896,7 +2892,7 @@ =20 if (con->c_status =3D=3D CSTATUS_MAX_NO_RTX) { /* max number reached, try to disconnect */ - retval =3D l2ca_disconnect_req(con); + retval =3D l2cap_disconnect_req(con); } =20 return retval; @@ -2951,8 +2947,9 @@ D_XMIT("Now we got baseband, send info req !\n"); } else { D_ERR(__FUNCTION__ ": lp_connect_req failed, no connection (status %d)\= n", con->c_status); + retval =3D -MSGCODE(MSG_LAYER_HCI, con->c_status); delete_con(con); - return -MSGCODE(MSG_LAYER_HCI, con->c_status); + return retval; } } =20 @@ -2966,7 +2963,7 @@ retval =3D l2cap_info_req(con, infotype); if(retval < 0) { D_ERR(__FUNCTION__ ": l2cap_info_req failed (status %d)\n", retval); - /* Timeout and then try again */ + return retval; } =20 /* wait until we received a response or after timeout */ @@ -2991,7 +2988,7 @@ /* Action is used when the sending function doesn't want to handle the action it self */ void -start_rtx(l2cap_con *con, unsigned short timeout, u16 action) +start_rtx(l2cap_con *con, unsigned short timeout) { /* multiply by 2 each rtx */ =20 @@ -3015,7 +3012,6 @@ con->timer.rtx.data =3D (unsigned long)con; con->timer.rtx.expires =3D jiffies + timeout*HZ; con->timer.rtx_inuse =3D 1; - con->timer.rtx_action =3D action; add_timer(&con->timer.rtx);=20=20 =20 #else /* Usermode stack */ |
From: Anders J. <and...@us...> - 2001-11-15 15:02:37
|
The following file was modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.h 1.46 1.47=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Added bt_handle_hw_error The diff of the modified file(s): --- bluetooth.h 2001/09/18 10:48:22 1.46 +++ bluetooth.h 2001/11/15 15:02:37 1.47 @@ -96,6 +96,7 @@ s32 bt_sprint_status(u8 *buf); void bt_send_sdp_data_received(u8 line, u8 *data, int len); void bt_reset_phys_hw(void); +void bt_handle_hw_error(u8 error); =20 /* Handles wakeup of failed blocking function calls */ #ifdef __KERNEL__ |
From: Anders J. <and...@us...> - 2001-11-15 15:01:57
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.212 1.213=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Added bt_handle_hw_error. The diff of the modified file(s): --- bluetooth.c 2001/11/15 11:18:00 1.212 +++ bluetooth.c 2001/11/15 15:01:57 1.213 @@ -258,6 +258,7 @@ /****************** GLOBAL VARIABLE DECLARATION SECTION ******************= ***/ =20 extern hci_controller hci_ctrl; +static u8 btdm_pid =3D 0; =20 /****************** LOCAL VARIABLE DECLARATION SECTION *******************= ***/ =20 @@ -1335,6 +1336,8 @@ BT_LDISC(__FUNCTION__ "\n"); DSYS("Setting BT driver to use serial tty\n"); sertty =3D tty; + DSYS("Setting btdm_pid (%d)\n", current->pid); + btdm_pid =3D current->pid; return 0; } =20 @@ -2524,6 +2527,25 @@ } return old; } + +void +bt_handle_hw_error(u8 error) +{ + printk(__FUNCTION__ ": Received error with code 0x%02X ", error); + switch(error) { + case 0xfe: + printk(", resetting module\n"); + if(btdm_pid) { + kill_proc(btdm_pid, SIGUSR1, 1); + } else { + printk(__FUNCTION__ ": No btdm PID found, ignoring\n"); + }=09 + break; + default: + printk(", ignoring\n"); + } +} + =20 s32 bt_init_stack(void) |
From: Anders J. <and...@us...> - 2001-11-15 15:00:37
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- hci.c 1.188 1.189=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Added call to bt_handle_hw_error when we receive an hwerror. The diff of the modified file(s): --- hci.c 2001/10/22 12:51:44 1.188 +++ hci.c 2001/11/15 15:00:36 1.189 @@ -857,7 +857,6 @@ =20 /* enable m/s switch */=20 write_link_policy_settings(hci_hdl, 0x01); - /* we demand role switch as server */ if (force_msswitch && !i_am_initiator) { /* FIXME -- check return code */ @@ -1031,6 +1030,7 @@ case HARDWARE_ERROR: D_ERR(__FUNCTION__ ": A hardware error with error code 0x%02X occurred.\= n", buf[0]); D_ERR(__FUNCTION__ ": Please refer to your Bluetooth module's manual.\n"= ); + bt_handle_hw_error(buf[0]); break; =20 case ROLE_CHANGED: @@ -2331,7 +2331,7 @@ s32 hci_switch_role(u8 *bd, u8 role) { - DSYS(__FUNCTION__ ": role %d\n", role); + D_CMD(__FUNCTION__ ": role %d\n", role); =20 c_pkt.type =3D CMD_PKT; c_pkt.opcode =3D hci_put_opcode(SWITCH_ROLE, HCI_LP); |
From: Peter K. <pk...@us...> - 2001-11-15 11:23:45
|
The following file was modified in : Name Old version New version Comment ---- ----------- ----------- ------- Makefile 1.1 1.2=20=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Added chlog rule used to update the ChangeLog file. The diff of the modified file(s): --- Makefile 2001/02/28 23:42:08 1.1 +++ Makefile 2001/11/15 11:23:44 1.2 @@ -34,3 +34,6 @@ make -C linux/drivers/char/bluetooth clean make -C libs clean make -C apps/bluetooth clean + +chlog: + cvs2cl.pl --fsf --ignore CVSROOT |
From: Peter K. <pk...@us...> - 2001-11-15 11:20:27
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- sdp.c 1.82 1.83=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Handle l2cap->upper_con being NULL in sdp_disconnect_ind(). The diff of the modified file(s): --- sdp.c 2001/11/14 11:05:19 1.82 +++ sdp.c 2001/11/15 11:20:26 1.83 @@ -758,9 +758,10 @@ sdp_con *sdp; D_MISC(__FUNCTION__ ", remote cid : %d\n", l2cap->remote_cid); =20=20=20=20 - sdp =3D (sdp_con*) l2cap->upper_con; + if ((sdp =3D (sdp_con*) l2cap->upper_con)) { sdp->state =3D SDP_DISCONNECTED; sdp->l2cap =3D NULL; + } =20 l2ca_disconnect_rsp(l2cap); } |
From: Peter K. <pk...@us...> - 2001-11-15 11:18:15
|
The following file was modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- btdebug.h 1.41 1.42=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Renamed print_time() to bt_log_time(). The diff of the modified file(s): --- btdebug.h 2001/09/19 15:11:28 1.41 +++ btdebug.h 2001/11/15 11:18:14 1.42 @@ -184,13 +184,8 @@ =20 /***************** Function declaration section **************************= ****/ =20 -#ifdef __KERNEL__ -u8* print_time(s32 use_stdout); +u8* bt_log_time(void); void print_data(const u8 *message, u8 *buf, s32 len); -#else -char* print_time(int use_stdout); -void print_data(const unsigned char *message, unsigned char *buf, int len); -#endif =20 const char* bd2str(const unsigned char *bd); =20 |
From: Peter K. <pk...@us...> - 2001-11-15 11:18:02
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.211 1.212=20=20=20=20=20=20=20=20=20=20=20 btdebug.c 1.22 1.23=20=20=20=20=20=20=20=20=20=20=20=20 btmem.c 1.44 1.45=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Renamed print_time() to bt_log_time(). The diff of the modified file(s): --- bluetooth.c 2001/11/13 10:45:31 1.211 +++ bluetooth.c 2001/11/15 11:18:00 1.212 @@ -121,7 +121,7 @@ =20 #if BT_DATA_DEBUG #if BT_USE_TIMESTAMPS -#define BT_DATA(fmt...) do {print_time(1);printk(BT_DBG_STR"DATA " fmt);} = while (0) +#define BT_DATA(fmt...) do { printk(bt_log_time()); printk(BT_DBG_STR"DATA= " fmt); } while (0) #else #define BT_DATA(fmt...) printk(BT_DBG_STR"DATA " fmt) #endif @@ -1284,7 +1284,7 @@ { /* should simply discard data since ttySx only exists for internal use */ - BT_LDISC(__FUNCTION__ ": (%d) done!\n", count); + BT_LDISC(__FUNCTION__ ": (%lu) done!\n", (unsigned long)count); =20=20=20 return tty->driver.write(tty, 1/*from user*/, data, count); } @@ -2605,8 +2605,8 @@ =20 init_failed_exit1:=20 hci_shutdown(); -init_failed_exit0: #ifdef CONFIG_BLUETOOTH_SUPPORT_BCSP +init_failed_exit0: bcsp_shutdown(); #endif btmem_shutdown(); --- btdebug.c 2001/06/06 14:57:19 1.22 +++ btdebug.c 2001/11/15 11:18:00 1.23 @@ -63,59 +63,42 @@ =20 /****************** FUNCTION DEFINITION SECTION **************************= ***/ =20 -#ifdef __KERNEL__ - -static u8 buf[20]; -static struct timeval tv_old =3D {0, 0}; - -u8* print_time(s32 use_stdout) +u8* +bt_log_time(void) { - s32 len, diff; +#if defined(__KERNEL__) && defined(BT_USE_TIMESTAMPS) + s32 diff; struct timeval tv;=20=20 + static struct timeval tv_old =3D {0, 0}; + static u8 buf[50]; =20 do_gettimeofday(&tv); =20=09 - diff =3D ((tv.tv_sec - tv_old.tv_sec)*1000000 + tv.tv_usec) -=20 - tv_old.tv_usec; + /* Set tv_old on first call of this function */ + if (!tv_old.tv_sec && !tv_old.tv_usec) + tv_old =3D tv; =20=09 - if (use_stdout =3D=3D 1) { - printk("[%03d,%06d<%06d>] ",=20 - (int)tv.tv_sec, (int)tv.tv_usec, diff); - } - else - { - len =3D sprintf(buf, "[%03d,%06d<%06d>] ",=20 - (int)tv.tv_sec, tv.tv_usec, diff); - buf[len] =3D 0; - } + diff =3D (tv.tv_sec - tv_old.tv_sec)*1000000 + + tv.tv_usec - tv_old.tv_usec; + + sprintf(buf, "[%03ld.%06ld <%03d.%06d>] ", tv.tv_sec, tv.tv_usec, diff / = 1000000, diff % 1000000); tv_old =3D tv; - return buf; -} =20 + return buf; #else - -/* No timestamps in usermode yet */ -char* print_time(int use_stdout) -{ - printf("No timestamps in usermode stack yet\n"); - return "No timestamps in usermode stack yet\n"; -} + return ""; #endif +} =20 void=20 print_data(const u8 *message, u8 *buf, s32 len) {=20 s32 t =3D 0; =20 -#if BT_USE_TIMESTAMPS - if (message) - printk("\n%s %s (%d):\n", print_time(0), message, len); -#else if (message) - printk("\n%s (%d):\n", message, len); -#endif - while (t < len) - { + printk("\n%s%s (%d):\n", bt_log_time(), message, len); + + while (t < len) { printk("0x%02x ", buf[t++]); if (!(t % 16)) printk("\n"); @@ -124,7 +107,8 @@ printk("\n"); } =20 -const char* bd2str(const unsigned char *bd) +const char* +bd2str(const unsigned char *bd) { static char buf[20]; =20 --- btmem.c 2001/10/22 13:25:54 1.44 +++ btmem.c 2001/11/15 11:18:00 1.45 @@ -562,11 +562,11 @@ /* Graphical view of buffer size */ void btmem_show_size(s32 count) { - u32 i; - i =3D ((count*BUFFERMETERRESOLUTION)/BT_BUF_SIZE); + u32 i =3D ((count*BUFFERMETERRESOLUTION)/BT_BUF_SIZE); + memset(buffermeter, '|', i); buffermeter[i+1] =3D 0; /* null terminate */=20 - printk("%s [%s - %d bytes]\n", buffermeter, print_time(0), count); + printk("%s%s [%d bytes]\n", bt_log_time(), buffermeter, count); } =20 void show_bt_buf(bt_tx_buf *tx, s32 no_data) |
From: Anders J. <and...@us...> - 2001-11-14 11:05:20
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- sdp.c 1.81 1.82=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Corrected debugmessage in sdp_database_read The diff of the modified file(s): --- sdp.c 2001/10/15 13:29:06 1.81 +++ sdp.c 2001/11/14 11:05:19 1.82 @@ -977,7 +977,7 @@ } =20 D_XMIT(__FUNCTION__ " preparing to send %d bytes data to sdp_con[%d]\n", = db_hdl.len, db_hdl.sdp_con_id); - PRINTPKT("Data to be sent to client:", db_hdl.data, db_hdl.len); + PRINTPKT("Data to be sent to client:", sdp_buf->frame, db_hdl.len); =20 l2cap_send_data(db_write_tx_buf, sdp_con_list[db_hdl.sdp_con_id].l2cap); db_write_tx_buf =3D NULL; |
From: Anders J. <and...@us...> - 2001-11-13 10:45:31
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.210 1.211=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * test_process_cmd now returns a correct value. The diff of the modified file(s): --- bluetooth.c 2001/11/08 14:27:01 1.210 +++ bluetooth.c 2001/11/13 10:45:31 1.211 @@ -689,8 +689,7 @@ =20 copy_from_user(cmd, (u8*)arg, 260); =20=09=09 - test_process_cmd(cmd+1, cmd[0]); - return 0; + return test_process_cmd(cmd+1, cmd[0]); } =20 /* Ioctls executing HCI commands */ |
From: Anders J. <and...@us...> - 2001-11-13 10:42:04
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- unplug_test.c 1.7 1.8=20=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Corrected testdata for SDP to reflect current sdp-database. * Added UUID32, UUID128 to some testcases. The diff of the modified file(s): --- unplug_test.c 2001/11/06 18:08:07 1.7 +++ unplug_test.c 2001/11/13 10:42:03 1.8 @@ -150,10 +150,26 @@ =20 /* =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=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D */= =20 =20 -unsigned char sdp_data_52111[] =3D { 0x02, 0x77, 0x77, 0x00, 0x08, +/* UUID 16 */ +unsigned char sdp_data_52111_1[] =3D { 0x02, 0x77, 0x77, 0x00, 0x08, 0x35, 0x03, 0x19, 0x00, 0x01, 0x00, 0xff, 0x00 }; =20 +/* UUID 32 */ +unsigned char sdp_data_52111_2[] =3D { 0x02, 0x77, 0x77, 0x00, 0x0a, + 0x35, 0x05, 0x1a, 0x00, 0x00, 0x00, 0x01, 0x00, 0xff, + 0x00 }; + +/* UUID 128 */ +unsigned char sdp_data_52111_3[] =3D { 0x02, 0x77, 0x77, 0x00, 0x16, + 0x35, 0x11,=20 + 0x1c,=20 + 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x10, 0x00, + 0x80, 0x00, 0x00, 0x80, 0x5f, 0x9b, 0x34, 0xfb, + 0x00, 0xff, + 0x00 }; + + unsigned char sdp_data_52113_1[] =3D { 0x02, 0x77, 0x77, 0x00, 0x08, 0x35, 0x03, 0x19, 0x00, 0x01, 0x00, 0x01, 0x00 }; @@ -166,17 +182,38 @@ 0x35, 0x03, 0x19, 0x12, 0x34, 0x00, 0xff, 0x00 }; =20 -unsigned char sdp_data_52121[] =3D { 0x02, 0x77, 0x77, 0x00, 0x0a, +/* UUID 16 */ +unsigned char sdp_data_52121_1[] =3D { 0x02, 0x77, 0x77, 0x00, 0x0a, 0x35, 0x03, 0x19, 0x00, 0x01, 0x00, 0xff, 0x00 }; =20 +/* UUID 32 */ +unsigned char sdp_data_52121_2[] =3D { 0x02, 0x77, 0x77, 0x00, 0x0c, + 0x35, 0x05, 0x1a, 0x00, 0x00, 0x00, 0x01, 0x00, 0xff, + 0x00 }; + +/* UUID 128 */ +unsigned char sdp_data_52121_3[] =3D { 0x02, 0x77, 0x77, 0x00, 0x18, + 0x35, 0x11,=20 + 0x1c,=20 + 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x10, 0x00, + 0x80, 0x00, 0x00, 0x80, 0x5f, 0x9b, 0x34, 0xfb, + 0x00, 0xff, + 0x00 }; + unsigned char sdp_data_52122[] =3D { 0x02, 0x77, 0x77, 0x00, 0x06, 0x19, 0x00, 0x01, 0x00, 0xff, 0x00 }; =20=20=20 -unsigned char sdp_data_53111[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0c, - 0x00, 0x01, 0x00, 0x00, 0x00, 0xff, 0x35, +unsigned char sdp_data_53111_1[] =3D { 0x02, 0x77, 0x77, 0x00, 0x08, + 0x35, 0x03, 0x19, 0x10, 0x00, 0x00, 0xff, + 0x00 }; + +unsigned char sdp_data_53111_2[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0c, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x35, 0x03, 0x09, 0x00, 0x01, 0x00 }; =20 + + unsigned char sdp_data_53113_1[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0c, 0x00, 0x01, 0x00, 0x00, 0x00, 0x06, 0x35, 0x03, 0x09, 0x00, 0x01, 0x00 }; @@ -221,10 +258,20 @@ 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0x35, 0x03, 0x09, 0x00, 0x01, 0x00 }; =20 -unsigned char sdp_data_54111[] =3D { 0x06, 0x88, 0x88, 0x00, 0x0d, +unsigned char sdp_data_54111_1[] =3D { 0x06, 0x88, 0x88, 0x00, 0x0d, 0x35, 0x03, 0x19, 0x12, 0x34, 0x00, 0xff, 0x35, 0x03, 0x09, 0x00, 0x01, 0x00 }; =20 +unsigned char sdp_data_54111_2[] =3D { 0x06, 0x88, 0x88, 0x00, 0x0f, + 0x35, 0x05, 0x1a, 0x00, 0x00, 0x12, 0x34, 0x00, 0xff, + 0x35, 0x03, 0x09, 0x00, 0x01, 0x00 }; + +unsigned char sdp_data_54111_3[] =3D { 0x06, 0x88, 0x88, 0x00, 0x1b, 0x35,= 0x11, 0x1c, + 0x00, 0x00, 0x12, 0x34, 0x00, 0x00, 0= x10, 0x00, + 0x80, 0x00, 0x00, 0x80, 0x5f, 0x9b, 0= x34, 0xfb, + 0x00, 0xff ,0x35, 0x03, 0x09, 0x00, 0= x01, 0x00}; + + unsigned char sdp_data_54112[] =3D { 0x06, 0x88, 0x88, 0x00, 0x0d, 0x35, 0x03, 0x19, 0x00, 0x01, 0x00, 0xff, 0x35, 0x03, 0x09, 0x01, 0xff, 0x00 }; @@ -261,9 +308,16 @@ 0x35, 0x03, 0x19, 0x10, 0x00, 0x00, 0xff, 0x35, 0x03, 0x09, 0x00, 0x09, 0x00 }; =20 -unsigned char sdp_data_54121[] =3D { 0x06, 0x88, 0x88, 0x00, 0x0b, +unsigned char sdp_data_54121_1[] =3D { 0x06, 0x88, 0x88, 0x00, 0x0b, 0x35, 0x03, 0x19, 0x10, 0x00, 0x00, 0xff, 0x09, 0x00, 0x09, 0x00 }; +unsigned char sdp_data_54121_2[] =3D { 0x06, 0x88, 0x88, 0x00, 0x0d, + 0x35, 0x05, 0x1a, 0x00, 0x00, 0x10, 0x00, 0x00, 0xff, + 0x09, 0x00, 0x09, 0x00 }; +unsigned char sdp_data_54121_3[] =3D { 0x06, 0x88, 0x88, 0x00, 0x19, 0x35,= 0x11, 0x1c, + 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0= x10, 0x00, + 0x80, 0x00, 0x00, 0x80, 0x5f, 0x9b, 0= x34, 0xfb,=20 + 0x00, 0xff, 0x09, 0x00, 0x09, 0x00 }; =20 unsigned char sdp_data_54122[] =3D { 0x06, 0x88, 0x88, 0x00, 0x0f, 0x35, 0x03, 0x19, 0x10, 0x00, 0x00, 0xff, @@ -341,6 +395,7 @@ 0x03, 0x09, 0x00, 0x01, 0x00 }; #endif =20 +#if 1 /* UUID 128 */ unsigned char sdp_data_55111_1[] =3D { 0x02, 0x77, 0x77, 0x00, 0x16, 0x35, 0x11,=20 @@ -386,8 +441,8 @@ unsigned char sdp_data_55111_6[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0c, 0x00, 0x10, 0x00, 0x00, 0x00, 0xff, 0x35, 0x03, 0x09, 0x00, 0x01, 0x00 }; - =20 +#endif =20 =20 extern u8 testdata[]; @@ -728,8 +783,18 @@ =20 static s32 sdp_test_52111(void) { - return sdp_send_data(&sdp_con_list[0], sdp_data_52111, sdp_data_52111[4] = + 5); + static int t =3D 0; + if(t =3D=3D 0) { + t =3D 1; + return sdp_send_data(&sdp_con_list[0], sdp_data_52111_1, sdp_data_52111_= 1[4] + 5); + } else if(t =3D=3D 1) { + t =3D 2; + return sdp_send_data(&sdp_con_list[0], sdp_data_52111_2, sdp_data_52111_= 2[4] + 5); + } else { + t =3D 0; + return sdp_send_data(&sdp_con_list[0], sdp_data_52111_3, sdp_data_52111_= 3[4] + 5); } +} =20 static s32 sdp_test_52113(void) { @@ -754,8 +819,18 @@ =20 static s32 sdp_test_52121(void) { - return sdp_send_data(&sdp_con_list[0], sdp_data_52121, sdp_data_52121[4] = + 5); + static int t =3D 0; + if(t =3D=3D 0) { + t =3D 1; + return sdp_send_data(&sdp_con_list[0], sdp_data_52121_1, sdp_data_52121_= 1[4] + 5 - 2); + } else if(t =3D=3D 1) { + t =3D 2; + return sdp_send_data(&sdp_con_list[0], sdp_data_52121_2, sdp_data_52121_= 2[4] + 5 - 2); + } else { + t =3D 0; + return sdp_send_data(&sdp_con_list[0], sdp_data_52121_3, sdp_data_52121_= 3[4] + 5 - 2); } +} =20 static s32 sdp_test_52122(void) { @@ -764,7 +839,16 @@ =20 static s32 sdp_test_53111(void) { - return sdp_send_data(&sdp_con_list[0], sdp_data_53111, sdp_data_53111[4] = + 5); + static int t =3D 0; + s32 retval; + if(!t) { + t =3D 1; + return sdp_send_data(&sdp_con_list[0], sdp_data_53111_1, sdp_data_53111_= 1[4] + 5); + } else { + t =3D 0; + return sdp_send_data(&sdp_con_list[0], sdp_data_53111_2, sdp_data_53111_= 2[4] + 5); + } +=09 } =20 static s32 sdp_test_53113(void) @@ -829,7 +913,17 @@ =20 static s32 sdp_test_54111(void) { - return sdp_send_data(&sdp_con_list[0], sdp_data_54111, sdp_data_54111[4] = + 5); + static int t =3D 0; + if(t =3D=3D 0) { + t =3D 1; + return sdp_send_data(&sdp_con_list[0], sdp_data_54111_1, sdp_data_54111_= 1[4] + 5); + } else if(t =3D=3D 1) { + t =3D 2; + return sdp_send_data(&sdp_con_list[0], sdp_data_54111_2, sdp_data_54111_= 2[4] + 5); + } else { + t =3D 0; + return sdp_send_data(&sdp_con_list[0], sdp_data_54111_3, sdp_data_54111_= 3[4] + 5); + } } =20 static s32 sdp_test_54112(void) @@ -883,7 +977,17 @@ =20 static s32 sdp_test_54121(void) { - return sdp_send_data(&sdp_con_list[0], sdp_data_54121, sdp_data_54121[4] = + 5); + static int t =3D 0; + if(t =3D=3D 0) { + t =3D 1; + return sdp_send_data(&sdp_con_list[0], sdp_data_54121_1, sdp_data_54121_= 1[4] + 5); + } else if(t =3D=3D 1) { + t =3D 2; + return sdp_send_data(&sdp_con_list[0], sdp_data_54121_2, sdp_data_54121_= 2[4] + 5); + } else { + t =3D 0; + return sdp_send_data(&sdp_con_list[0], sdp_data_54121_3, sdp_data_54121_= 3[4] + 5); + } } =20 static s32 sdp_test_54122(void) |
From: Peter K. <pk...@us...> - 2001-11-08 14:27:02
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.209 1.210=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Added names for the Bluetooth driver and line discipline (supported in Linux 2.2 and 2.4). The diff of the modified file(s): --- bluetooth.c 2001/10/30 15:04:52 1.209 +++ bluetooth.c 2001/11/08 14:27:01 1.210 @@ -2275,6 +2275,9 @@ =20 memset(&bt_driver, 0, sizeof(bt_driver)); bt_driver.magic =3D BT_TTY_DRIVER_MAGIC; +#if LINUX_VERSION_CODE >=3D KERNEL_VERSION(2,2,0) + bt_driver.driver_name =3D "bluetooth"; +#endif bt_driver.name =3D "ttyBT"; bt_driver.major =3D BT_TTY_MAJOR; bt_driver.minor_start =3D 0; @@ -2327,6 +2330,9 @@ =20=09 memset(&bt_ldisc, 0, sizeof(bt_ldisc)); bt_ldisc.magic =3D TTY_LDISC_MAGIC; +#if LINUX_VERSION_CODE >=3D KERNEL_VERSION(2,2,0) + bt_ldisc.name =3D "n_bt"; +#endif bt_ldisc.open =3D bt_tty_open; bt_ldisc.close =3D bt_tty_close; bt_ldisc.read =3D bt_tty_read; @@ -2337,8 +2343,8 @@ #else bt_ldisc.poll =3D bt_tty_poll; #endif - bt_ldisc.receive_room =3D bt_tty_room; bt_ldisc.receive_buf =3D bt_receive_lower_stack; + bt_ldisc.receive_room =3D bt_tty_room; bt_ldisc.write_wakeup =3D bt_tty_wakeup; =20=09 status =3D tty_register_ldisc(N_BT, &bt_ldisc); |
From: Anders J. <and...@us...> - 2001-11-06 18:08:09
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- unplug_test.c 1.6 1.7=20=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Corrected SDP test 55111, added UUID 128 and UUID 32. The diff of the modified file(s): --- unplug_test.c 2001/10/16 16:23:45 1.6 +++ unplug_test.c 2001/11/06 18:08:07 1.7 @@ -269,48 +269,127 @@ 0x35, 0x03, 0x19, 0x10, 0x00, 0x00, 0xff, 0x35, 0x03, 0x09, 0x00, 0x01, 0x00 }; =20 + +#if 0 +/* UUID 16 */ unsigned char sdp_data_55111_1[] =3D { 0x02, 0x77, 0x77, 0x00, 0x08, 0x35, 0x03, 0x19, 0x10, 0x02, 0x00, 0xff, 0x00 }; =20 -unsigned char sdp_data_55111_2[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, - 0x00, 0x01, 0x00, 0x00, 0x00, 0xff, 0x35, +unsigned char sdp_data_55111_2_1[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x35, 0x05, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x00 }; =20 -unsigned char sdp_data_55111_3[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, +unsigned char sdp_data_55111_2_2[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, 0x00, 0x10, 0x00, 0x00, 0x00, 0xff, 0x35, 0x05, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x00 }; =20 -unsigned char sdp_data_55111_4[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, +unsigned char sdp_data_55111_2_3[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, 0x00, 0x10, 0xff, 0xff, 0x00, 0xff, 0x35, 0x05, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x00 }; =20 -unsigned char sdp_data_55111_5[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, - 0x00, 0x11, 0xff, 0xff, 0x00, 0xff, 0x35, + +unsigned char sdp_data_55111_3[] =3D { 0x02, 0x77, 0x77, 0x00, 0x08, + 0x35, 0x03, 0x19, 0x10, 0x01, 0x00, 0xff, + 0x00 }; + +unsigned char sdp_data_55111_4[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0c, + 0x00, 0x10, 0x00, 0x00, 0x00, 0xff, 0x35, + 0x03, 0x09, 0x02, 0x00, 0x00 }; + +unsigned char sdp_data_55111_5[] =3D { 0x02, 0x77, 0x77, 0x00, 0x08, + 0x35, 0x03, 0x19, 0x10, 0x01, 0x00, 0xff, + 0x00 }; + +unsigned char sdp_data_55111_6[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0c, + 0x00, 0x10, 0x00, 0x00, 0x00, 0xff, 0x35, + 0x03, 0x09, 0x00, 0x01, 0x00 }; +#endif +#if 0 +/* UUID 32 */ +unsigned char sdp_data_55111_1[] =3D { 0x02, 0x77, 0x77, 0x00, 0x0a, + 0x35, 0x05, 0x1a, 0x00, 0x00, 0x10, 0x02, 0x00, 0xff, + 0x00 }; + +unsigned char sdp_data_55111_2_1[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x35, 0x05, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x00 }; =20 -unsigned char sdp_data_55111_6[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, - 0x01, 0x00, 0xff, 0xff, 0x00, 0xff, 0x35, +unsigned char sdp_data_55111_2_2[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, + 0x00, 0x10, 0x00, 0x00, 0x00, 0xff, 0x35, 0x05, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x00 }; =20 -unsigned char sdp_data_55111_7[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, - 0x01, 0x01, 0xff, 0xff, 0x00, 0xff, 0x35, +unsigned char sdp_data_55111_2_3[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, + 0x00, 0x10, 0xff, 0xff, 0x00, 0xff, 0x35, 0x05, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x00 }; =20 -unsigned char sdp_data_55111_8[] =3D { 0x02, 0x77, 0x77, 0x00, 0x08, - 0x35, 0x03, 0x19, 0x10, 0x01, 0x00, 0xff, + +unsigned char sdp_data_55111_3[] =3D { 0x02, 0x77, 0x77, 0x00, 0x0a, + 0x35, 0x05, 0x1a, 0x00, 0x00, 0x10, 0x01, 0x00, 0xff, 0x00 }; =20 -unsigned char sdp_data_55112_1[] =3D { 0x06, 0x88, 0x88, 0x00, 0x0f, - 0x35, 0x03, 0x19, 0x10, 0x02, 0x00, 0xff, - 0x35, 0x05, 0x0a, 0x00, 0x00, 0xff, 0xff, +unsigned char sdp_data_55111_4[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0c, + 0x00, 0x10, 0x00, 0x00, 0x00, 0xff, 0x35, + 0x03, 0x09, 0x02, 0x00, 0x00 }; + +unsigned char sdp_data_55111_5[] =3D { 0x02, 0x77, 0x77, 0x00, 0x0a, + 0x35, 0x05, 0x1a, 0x00, 0x00, 0x10, 0x01, 0x00, 0xff, 0x00 }; =20 -unsigned char sdp_data_55112_2[] =3D { 0x06, 0x88, 0x88, 0x00, 0x0f, - 0x35, 0x03, 0x19, 0x10, 0x01, 0x00, 0xff, - 0x35, 0x05, 0x0a, 0x00, 0x00, 0xff, 0xff, +unsigned char sdp_data_55111_6[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0c, + 0x00, 0x10, 0x00, 0x00, 0x00, 0xff, 0x35, + 0x03, 0x09, 0x00, 0x01, 0x00 }; +#endif + +/* UUID 128 */ +unsigned char sdp_data_55111_1[] =3D { 0x02, 0x77, 0x77, 0x00, 0x16, + 0x35, 0x11,=20 + 0x1c,=20 + 0x00, 0x00, 0x10, 0x02, 0x00, 0x00, 0x10, 0x00, + 0x80, 0x00, 0x00, 0x80, 0x5f, 0x9b, 0x34, 0xfb, + 0x00, 0xff, 0x00 }; =20 +unsigned char sdp_data_55111_2_1[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x35, + 0x05, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x00 }; + +unsigned char sdp_data_55111_2_2[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, + 0x00, 0x10, 0x00, 0x00, 0x00, 0xff, 0x35, + 0x05, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x00 }; + +unsigned char sdp_data_55111_2_3[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0e, + 0x00, 0x10, 0xff, 0xff, 0x00, 0xff, 0x35, + 0x05, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x00 }; + + +unsigned char sdp_data_55111_3[] =3D { 0x02, 0x77, 0x77, 0x00, 0x16, + 0x35, 0x11,=20 + 0x1c,=20 + 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x10, 0x00, + 0x80, 0x00, 0x00, 0x80, 0x5f, 0x9b, 0x34, 0xfb, + 0x00, 0xff, + 0x00 }; + +unsigned char sdp_data_55111_4[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0c, + 0x00, 0x10, 0x00, 0x00, 0x00, 0xff, 0x35, + 0x03, 0x09, 0x02, 0x00, 0x00 }; + +unsigned char sdp_data_55111_5[] =3D { 0x02, 0x77, 0x77, 0x00, 0x16, + 0x35, 0x11,=20 + 0x1c,=20 + 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x10, 0x00, + 0x80, 0x00, 0x00, 0x80, 0x5f, 0x9b, 0x34, 0xfb, + 0x00, 0xff, + 0x00 }; + +unsigned char sdp_data_55111_6[] =3D { 0x04, 0x88, 0x88, 0x00, 0x0c, + 0x00, 0x10, 0x00, 0x00, 0x00, 0xff, 0x35, + 0x03, 0x09, 0x00, 0x01, 0x00 }; + + + + extern u8 testdata[]; static u8 test_is_initialized =3D 0; =20 @@ -817,6 +896,8 @@ static int t =3D 0; s32 retval =3D 0; =20=09 + printk("NOW RUNNING TESTCASE 55111, case %d\n", t); + switch (t) { case 0: retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_1, sdp_data_55= 111_1[4] + 5); @@ -824,41 +905,45 @@ break; =20 case 1: - retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_2, sdp_data_55= 111_2[4] + 5); + retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_2_1, sdp_data= _55111_2_1[4] + 5); t =3D 2; -// break; + break; case 2: - retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_3, sdp_data_55= 111_3[4] + 5); + retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_2_2, sdp_data= _55111_2_2[4] + 5); t =3D 3; -// break; + break; case 3: - retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_4, sdp_data_55= 111_4[4] + 5); + retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_2_3, sdp_data= _55111_2_3[4] + 5); t =3D 4; -// break; + break; +=09=20=20 case 4: - retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_5, sdp_data_55= 111_5[4] + 5); + retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_3, sdp_data_5= 5111_3[4] + 5); t =3D 5; -// break; + break; case 5: - retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_6, sdp_data_55= 111_6[4] + 5); + retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_4, sdp_data_5= 5111_4[4] + 5); t =3D 6; -// break; + break; case 6: - retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_7, sdp_data_55= 111_7[4] + 5); + retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_5, sdp_data_5= 5111_5[4] + 5); t =3D 7; -// break; + break; case 7: - retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_8, sdp_data_55= 111_8[4] + 5); + retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55111_6, sdp_data_5= 5111_6[4] + 5); t =3D 0; break;=20=20 +=09=20=20 }=20 return retval; } =20 static s32 sdp_test_55112(void) { +=20=20 static int t =3D 0; s32 retval =3D 0; + /* switch (t) { case 0: retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55112_1, sdp_data_55= 112_1[4] + 5); @@ -869,7 +954,7 @@ retval =3D sdp_send_data(&sdp_con_list[0], sdp_data_55112_2, sdp_data_55= 112_2[4] + 5); t =3D 0; break; - } + }*/ return retval; } =20 |
From: Peter K. <pk...@us...> - 2001-11-05 13:28:28
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- README 1.31 1.32=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Corrected the instruction for how to insmod the bt.o module. The diff of the modified file(s): --- README 2001/10/19 13:39:40 1.31 +++ README 2001/11/05 13:28:27 1.32 @@ -40,9 +40,9 @@ =20 # Insert the module into the kernel (must be done as root): =20 -insmod src/bt.o +insmod linux/drivers/char/bluetooth/bt.o =20 -# To get debug messages in kernel start another window and issue: +# To see debug messages from the kernel start another window and issue: =20 tail -f /var/log/messages=20 =20 |
From: Peter K. <pk...@us...> - 2001-11-05 13:24:04
|
The following file was modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- README.txt 1.2 1.3=20=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Fixed a small typo. The diff of the modified file(s): --- README.txt 2001/03/02 11:03:54 1.2 +++ README.txt 2001/11/05 13:24:02 1.3 @@ -105,8 +105,8 @@ -------- Disconnects a ttyBT =20 -Syntax : btdisc -d <dev> -S <rfcomm dlci> -e.g btdisc -d /dev/ttyBT0 -S 2 +Syntax : btdisc -d <dev> -D <rfcomm dlci> +e.g btdisc -d /dev/ttyBT0 -D 2 =20 =20 btinq.c |
From: Peter K. <pk...@us...> - 2001-10-30 15:04:53
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- Config.in 1.19 1.20=20=20=20=20=20=20=20=20=20=20=20=20 bluetooth.c 1.208 1.209=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Define and use CONFIG_BLUETOOTH_RESET_ACTIVE_HIGH to decide whether the reset pin is active high or low. The diff of the modified file(s): --- Config.in 2001/07/31 09:04:13 1.19 +++ Config.in 2001/10/30 15:04:52 1.20 @@ -52,6 +52,12 @@ Port_PB_Bit_5 CONFIG_BLUETOOTH_RESET_PB5 \ Port_G_Bit_10 CONFIG_BLUETOOTH_RESET_G10 \ Port_G_Bit_11 CONFIG_BLUETOOTH_RESET_G11" None + + if [ "$CONFIG_BLUETOOTH_RESET_NONE" !=3D "y" -a "$CONFIG_BLUETOOTH_CSR" = =3D "y" ]; then + define_bool CONFIG_BLUETOOTH_RESET_ACTIVE_HIGH y + else + define_bool CONFIG_BLUETOOTH_RESET_ACTIVE_HIGH n + fi fi =20 endmenu --- bluetooth.c 2001/10/22 12:49:20 1.208 +++ bluetooth.c 2001/10/30 15:04:52 1.209 @@ -1391,7 +1391,7 @@ void bt_reset_phys_hw(void) { #ifdef __CRIS__ -#ifdef CONFIG_BLUETOOTH_CSR +#ifdef CONFIG_BLUETOOTH_RESET_ACTIVE_HIGH int do_reset =3D 1; #else int do_reset =3D 0; |