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: Peter K. <pk...@us...> - 2001-06-19 11:21:00
|
The following file was modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- bt_vendor.c 1.20 1.21=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Only try to set the speed if the CSR firmware is new enough (temporarily setting the speed does not work correctly in 9.x). The diff of the modified file(s): --- bt_vendor.c 2001/06/13 12:34:55 1.20 +++ bt_vendor.c 2001/06/19 11:20:59 1.21 @@ -456,6 +456,8 @@ /* Connection setup, all devices, no auto accept */ unsigned char filter[3] =3D { 0x02, 0x00, 0x01 }; unsigned int wrscan =3D (PAGE_SCAN_ENABLE | INQUIRY_SCAN_ENABLE); + int firmware =3D -1; + char* buf; =20=20=20 if ((hw_vendor() =3D=3D HW_CSR_BCSP) && (csr_disable_deep_sleep(bt_cfd))) kill(getpid(), SIGUSR1); /* Restart btd (and HW) to activate change= s */ @@ -473,6 +475,15 @@ =20 sleep(1);=20=20 =20 + if ((buf =3D bt_firmware_info())) + { + sscanf(buf, " Firmware version: %d", &firmware); + } + + /* Only try to set the speed if the CSR firmware is new enough + (temporarily setting the speed does not work correctly in 9.x) */ + if (firmware >=3D 90) + { D(syslog(LOG_INFO, "Setting baudrate in CSR module [%d baud]", spd)); =20 bt_set_baudrate(bt_cfd, spd); @@ -486,6 +497,11 @@ tcflush(phys_fd, TCIOFLUSH); =20 D(syslog(LOG_INFO, "Baudrate set")); + } + else + { + syslog(LOG_INFO, "Did not set baudrate in CSR module as its firmware i= s too old (%d)", firmware); + } } =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*/ |
From: Peter K. <pk...@us...> - 2001-06-19 10:36:45
|
The following file was modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- bt_if.c 1.20 1.21=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Added bt_firmware_info(). The diff of the modified file(s): --- bt_if.c 2001/06/15 12:36:25 1.20 +++ bt_if.c 2001/06/19 10:36:45 1.21 @@ -155,6 +155,24 @@ } #endif =20 +char* bt_firmware_info(void) +{ +#ifndef BT_USERSTACK + int bt_cfd =3D bt_openctrl(); + static char buffer[80]; + + if (bt_cfd < 0 || ioctl(bt_cfd, BTFIRMWAREINFO, buffer) < 0) + { + perror(__FUNCTION__); + return NULL; + } + close(bt_cfd); + return buffer; +#else + return bt_hw_firmware(); +#endif +} + void reset_hw(void) { #ifdef __CRIS__ |
From: Peter K. <pk...@us...> - 2001-06-19 10:36:14
|
The following file was modified in apps/bluetooth/btd: Name Old version New version Comment ---- ----------- ----------- ------- btd.h 1.38 1.39=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Renumbered a couple of ioctls as BTHWVENDOR and BTWAITFORCONNECTION had accidentally gotten the same number... The diff of the modified file(s): --- btd.h 2001/06/15 12:43:16 1.38 +++ btd.h 2001/06/19 10:36:14 1.39 @@ -50,11 +50,10 @@ =20 #define BT_IOC_MAGIC 'B' /* Use B as a magic number */ #define BT_IOC_MAXNR 255 + #define BTCONNECT _IOW(BT_IOC_MAGIC, 0x00, bt_connection) #define BTDISCONNECT _IOW(BT_IOC_MAGIC, 0x01, unsigned int) =20 -#define BTWAITFORCONNECTION _IOW(BT_IOC_MAGIC, 0x0a, int) - #define BTSETSPEED _IOW(BT_IOC_MAGIC, 0x02, int) #define BTINITSTACK _IO(BT_IOC_MAGIC, 0x03) #define BTSETSERTTY _IO(BT_IOC_MAGIC, 0x04) @@ -64,22 +63,28 @@ #define BTRESETPHYSICALHW _IO(BT_IOC_MAGIC, 0x08) #define BTISINITIATED _IOR(BT_IOC_MAGIC, 0x09, int) #define BTHWVENDOR _IOR(BT_IOC_MAGIC, 0x0A, char[20]) +#define BTFIRMWAREINFO _IOR(BT_IOC_MAGIC, 0x0B, char[80]) =20 -#define BT_GETCACHEDLINKKEY _IOWR(BT_IOC_MAGIC, 0x0e, unsigned char[22]) +#define BTWAITFORCONNECTION _IOW(BT_IOC_MAGIC, 0x0C, int) +#define BTWAITNEWCONNECTIONS _IO(BT_IOC_MAGIC, 0x0D) +#define BTISLOWERCONNECTED _IOW(BT_IOC_MAGIC, 0x0E, int) + +//#define BT_SDP_REQUEST _IOW(BT_IOC_MAGIC, 0x0F, bt_sdp_request) +#define BT_GETCACHEDLINKKEY _IOWR(BT_IOC_MAGIC, 0x10, unsigned char[22]) =20 /* ioctls executing HCI commands */ =20 /* Link Control Command */ -#define HCIINQUIRY _IOWR(BT_IOC_MAGIC, 0x10, inquiry_results) -#define HCILINKKEYREPLY _IOWR(BT_IOC_MAGIC, 0x11, unsigned char[22]) -#define HCILINKKEYNEGATIVEREPLY _IOWR(BT_IOC_MAGIC, 0x12, unsigned char[6]) -#define HCIPINCODEREPLY _IOWR(BT_IOC_MAGIC, 0x13, unsigned char[23]) -#define HCIPINCODENEGATIVEREPLY _IOWR(BT_IOC_MAGIC, 0x14, unsigned char[6]) -#define HCIAUTHENTICATION_REQUESTED _IOW(BT_IOC_MAGIC, 0x15, unsigned char= [6]) -#define HCISETCONNECTION_ENCRYPTION _IOW(BT_IOC_MAGIC, 0x16, unsigned char= [7]) +#define HCIINQUIRY _IOWR(BT_IOC_MAGIC, 0x20, inquiry_results) +#define HCILINKKEYREPLY _IOWR(BT_IOC_MAGIC, 0x21, unsigned char[22]) +#define HCILINKKEYNEGATIVEREPLY _IOWR(BT_IOC_MAGIC, 0x22, unsigned char[6]) +#define HCIPINCODEREPLY _IOWR(BT_IOC_MAGIC, 0x23, unsigned char[23]) +#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]) =20 /* Link Policy Commands */ -#define HCISWITCHROLE _IOW(BT_IOC_MAGIC, 0x20, unsigned char[7]) +#define HCISWITCHROLE _IOW(BT_IOC_MAGIC, 0x28, unsigned char[7]) =20 /* Host Controler & Basband Commands */ #define HCIRESET _IO(BT_IOC_MAGIC, 0x30) |
From: Peter K. <pk...@us...> - 2001-06-19 10:35:56
|
The following file was modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- bt_if.h 1.14 1.15=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Renumbered a couple of ioctls as BTHWVENDOR and BTWAITFORCONNECTION had accidentally gotten the same number... The diff of the modified file(s): --- bt_if.h 2001/06/15 12:36:25 1.14 +++ bt_if.h 2001/06/19 10:35:56 1.15 @@ -131,14 +131,10 @@ =20 #define BT_IOC_MAGIC 'B' /* Use B as a magic number */ #define BT_IOC_MAXNR 255 + #define BTCONNECT _IOW(BT_IOC_MAGIC, 0x00, bt_connection) #define BTDISCONNECT _IOW(BT_IOC_MAGIC, 0x01, unsigned int) =20 - -#define BTWAITFORCONNECTION _IOW(BT_IOC_MAGIC, 0x0a, int) -#define BTWAITNEWCONNECTIONS _IO(BT_IOC_MAGIC, 0x0b) -#define BTISLOWERCONNECTED _IOW(BT_IOC_MAGIC, 0x0c, int) - #define BTSETSPEED _IOW(BT_IOC_MAGIC, 0x02, int) #define BTINITSTACK _IO(BT_IOC_MAGIC, 0x03) #define BTSETSERTTY _IO(BT_IOC_MAGIC, 0x04) @@ -148,24 +144,31 @@ #define BTRESETPHYSICALHW _IO(BT_IOC_MAGIC, 0x08) #define BTISINITIATED _IOR(BT_IOC_MAGIC, 0x09, int) #define BTHWVENDOR _IOR(BT_IOC_MAGIC, 0x0a, char[20]) +#define BTFIRMWAREINFO _IOR(BT_IOC_MAGIC, 0x0B, char[80]) =20 -#define BT_GETCACHEDLINKKEY _IOWR(BT_IOC_MAGIC, 0x0e, unsigned char[22]) +#define BTWAITFORCONNECTION _IOW(BT_IOC_MAGIC, 0x0C, int) +#define BTWAITNEWCONNECTIONS _IO(BT_IOC_MAGIC, 0x0D) +#define BTISLOWERCONNECTED _IOW(BT_IOC_MAGIC, 0x0E, int) + +//#define BT_SDP_REQUEST _IOW(BT_IOC_MAGIC, 0x0F, bt_sdp_request) +#define BT_GETCACHEDLINKKEY _IOWR(BT_IOC_MAGIC, 0x10, unsigned char[22]) + /* =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 */ /* Ioctls for executing HCI commands */ =20 /* Link Control Command */ =20 -#define HCIINQUIRY _IOWR(BT_IOC_MAGIC, 0x10, inquiry_results) -#define HCILINKKEYREPLY _IOWR(BT_IOC_MAGIC, 0x11, unsigned char[22]) -#define HCILINKKEYNEGATIVEREPLY _IOWR(BT_IOC_MAGIC, 0x12, unsigned char[6]) -#define HCIPINCODEREPLY _IOWR(BT_IOC_MAGIC, 0x13, unsigned char[23]) -#define HCIPINCODENEGATIVEREPLY _IOWR(BT_IOC_MAGIC, 0x14, unsigned char[6]) -#define HCIAUTHENTICATION_REQUESTED _IOW(BT_IOC_MAGIC, 0x15, unsigned char= [6]) -#define HCISETCONNECTION_ENCRYPTION _IOW(BT_IOC_MAGIC, 0x16, unsigned char= [7]) +#define HCIINQUIRY _IOWR(BT_IOC_MAGIC, 0x20, inquiry_results) +#define HCILINKKEYREPLY _IOWR(BT_IOC_MAGIC, 0x21, unsigned char[22]) +#define HCILINKKEYNEGATIVEREPLY _IOWR(BT_IOC_MAGIC, 0x22, unsigned char[6]) +#define HCIPINCODEREPLY _IOWR(BT_IOC_MAGIC, 0x23, unsigned char[23]) +#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]) =20 /* Link Policy Commands */ =20 -#define HCISWITCHROLE _IOW(BT_IOC_MAGIC, 0x20, unsigned char[7]) +#define HCISWITCHROLE _IOW(BT_IOC_MAGIC, 0x28, unsigned char[7]) =20 /* Host Controller & Baseband Commands */ =20 @@ -211,6 +214,8 @@ /* | BD(6) | type (2) |*/ #define BTGETINFO _IOW(BT_IOC_MAGIC, 0x74, unsigned char[8]) =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 */ + /* Used to calculate opcode for HCI commands using raw interface */ #define OPCODE_LSB(ocf, ogf) ((ocf) & 0xff) #define OPCODE_MSB(ocf, ogf) (((ocf) >> 8) | (((ogf) & 0x3f) << 2)) @@ -286,6 +291,7 @@ #ifndef BT_USERSTACK char* bt_hw_vendor(void); #endif +char* bt_firmware_info(void); void reset_hw(void); int bt_openctrl(void); void set_bt_line_disc(int phys_fd, int bt_disc, char* physdev); |
From: Peter K. <pk...@us...> - 2001-06-19 10:34:37
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.184 1.185=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Added BTFIRMWAREINFO ioctl. The diff of the modified file(s): --- bluetooth.c 2001/06/19 06:13:01 1.184 +++ bluetooth.c 2001/06/19 10:34:34 1.185 @@ -654,6 +654,11 @@ copy_to_user((u8*)arg, bt_hw_vendor(), strlen(bt_hw_vendor())+1); break; =20 + case BTFIRMWAREINFO: + BT_DRIVER(FNC"BTFIRMWAREINFO\n"); + copy_to_user((u8*)arg, bt_hw_firmware(), strlen(bt_hw_firmware())+1); + break; + case BTSENDTESTDATA: copy_from_user(&tmp, (s32*)arg, 4); copy_from_user(&utmp, (s32*)arg + 1, 4); |
From: Peter K. <pk...@us...> - 2001-06-19 10:34:04
|
The following file was modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- btcommon.h 1.77 1.78=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: * Added BTFIRMWAREINFO ioctl. * Renumbered a couple of ioctls as BTHWVENDOR and BTWAITFORCONNECTION had accidentally gotten the same number... The diff of the modified file(s): --- btcommon.h 2001/06/19 06:13:01 1.77 +++ btcommon.h 2001/06/19 10:34:03 1.78 @@ -116,6 +116,7 @@ /* Define the ioctls to the bt driver */ #define BT_IOC_MAGIC 'B' /* Use B as a magic number */ #define BT_IOC_MAXNR 255 + #define BTCONNECT _IOW(BT_IOC_MAGIC, 0x00, bt_connection) #define BTDISCONNECT _IOW(BT_IOC_MAGIC, 0x01, u32) #define BTSETSPEED _IOW(BT_IOC_MAGIC, 0x02, s32) @@ -127,26 +128,26 @@ #define BTRESETPHYSICALHW _IO(BT_IOC_MAGIC, 0x08) #define BTISINITIATED _IOR(BT_IOC_MAGIC, 0x09, s32) #define BTHWVENDOR _IOR(BT_IOC_MAGIC, 0x0A, char[20]) - -#define BTWAITFORCONNECTION _IOW(BT_IOC_MAGIC, 0x0a, s32) -#define BTWAITNEWCONNECTIONS _IO(BT_IOC_MAGIC, 0x0b) -#define BTISLOWERCONNECTED _IOW(BT_IOC_MAGIC, 0x0c, s32) -#define BT_SDP_REQUEST _IOW(BT_IOC_MAGIC, 0x0d, bt_sdp_request) -#define BT_GETCACHEDLINKKEY _IOWR(BT_IOC_MAGIC, 0x0e, u8[22]) +#define BTFIRMWAREINFO _IOR(BT_IOC_MAGIC, 0x0B, char[80]) +#define BTWAITFORCONNECTION _IOW(BT_IOC_MAGIC, 0x0C, s32) +#define BTWAITNEWCONNECTIONS _IO(BT_IOC_MAGIC, 0x0D) +#define BTISLOWERCONNECTED _IOW(BT_IOC_MAGIC, 0x0E, s32) +#define BT_SDP_REQUEST _IOW(BT_IOC_MAGIC, 0x0F, bt_sdp_request) +#define BT_GETCACHEDLINKKEY _IOWR(BT_IOC_MAGIC, 0x10, u8[22]) =20 /* Ioctls executing HCI commands */ =20 /* Link Control Command */ -#define HCIINQUIRY _IOWR(BT_IOC_MAGIC, 0x10, inquiry_results) -#define HCILINKKEYREPLY _IOWR(BT_IOC_MAGIC, 0x11, u8[22]) -#define HCILINKKEYNEGATIVEREPLY _IOWR(BT_IOC_MAGIC, 0x12, u8[6]) -#define HCIPINCODEREPLY _IOWR(BT_IOC_MAGIC, 0x13, u8[23]) -#define HCIPINCODENEGATIVEREPLY _IOWR(BT_IOC_MAGIC, 0x14, u8[6]) -#define HCIAUTHENTICATION_REQUESTED _IOW(BT_IOC_MAGIC, 0x15, u8[6]) -#define HCISETCONNECTION_ENCRYPTION _IOW(BT_IOC_MAGIC, 0x16, u8[7]) +#define HCIINQUIRY _IOWR(BT_IOC_MAGIC, 0x20, inquiry_results) +#define HCILINKKEYREPLY _IOWR(BT_IOC_MAGIC, 0x21, u8[22]) +#define HCILINKKEYNEGATIVEREPLY _IOWR(BT_IOC_MAGIC, 0x22, u8[6]) +#define HCIPINCODEREPLY _IOWR(BT_IOC_MAGIC, 0x23, u8[23]) +#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]) =20 /* Link Policy Commands */ -#define HCISWITCHROLE _IOW(BT_IOC_MAGIC, 0x20, u8[7]) +#define HCISWITCHROLE _IOW(BT_IOC_MAGIC, 0x28, u8[7]) =20 /* Host Controller & Baseband Commands */ #define HCIRESET _IO(BT_IOC_MAGIC, 0x30) |
From: Mats F. <ma...@us...> - 2001-06-19 08:38:30
|
The following file was modified in apps/bluetooth/sdp_server: Name Old version New version Comment ---- ----------- ----------- ------- sdp_server.c 1.28 1.29=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Should not free rec_hdl_list, since it is declared as static The diff of the modified file(s): --- sdp_server.c 2001/06/14 10:30:42 1.28 +++ sdp_server.c 2001/06/19 08:19:37 1.29 @@ -422,8 +422,8 @@ rec_hdl_list_out[cnt_out] =3D rec_hdl_list_in[i]; D_RHDL(__FUNCTION__": Found record_handle 0x%08x", rec_hdl_list_out[cnt_o= ut]); cnt_out++; - existing =3D FALSE; } + existing =3D FALSE; } =20 rec_hdl_list_out[cnt_out] =3D NO_REC_HDL; @@ -1473,23 +1473,23 @@ =20 rec_hdl_list =3D get_all_rec_hdl(db_hdl->service_class_list, db_hdl->ser= vice_class_cnt); =20=20=20 + D_REC("Got a record handle list"); +=20=20 if (is_err()) - { - if (rec_hdl_list) { - D_MEM("<--- free%d 0x%8p", --malloc_dbg, rec_hdl_list); - free(rec_hdl_list); - } + D_REC("Error occured, sending error response"); send_error_rsp(&db_hdl->db, get_err()); return; } =20 if (rec_hdl_list) { + rec_hdl_cnt =3D 0; while (rec_hdl_list[rec_hdl_cnt] !=3D NO_REC_HDL) { rec_hdl_cnt++; } + D_REC("Found %d record handles", rec_hdl_cnt); } =20=20=20 /* Skip the sdp header and the attribute byte count field */ @@ -1525,11 +1525,6 @@ } else if (is_err()) { - if (rec_hdl_list) - { - D_MEM("<--- free%d 0x%8p", --malloc_dbg, rec_hdl_list); - free(rec_hdl_list); - } send_error_rsp(&db_hdl->db, get_err()); return; } @@ -1540,11 +1535,6 @@ rsp_pkt[rsp_pkt_len + 1] =3D tmp_len - 2; rsp_pkt_len +=3D tmp_len; } - } - if (rec_hdl_list) - { - D_MEM("<--- free%d 0x%8p", --malloc_dbg, rec_hdl_list); - free(rec_hdl_list); } =20 /* Set the attribute byte count to packet length minus sdp pdu header si= ze |
From: Mats F. <ma...@us...> - 2001-06-19 06:13:32
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.183 1.184=20=20=20=20=20=20=20=20=20=20=20 btmem.c 1.42 1.43=20=20=20=20=20=20=20=20=20=20=20=20 rfcomm.c 1.113 1.114=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: We need to keep track of how many bytes there are in the BT-buf for each li= ne The diff of the modified file(s): --- bluetooth.c 2001/06/15 12:30:03 1.183 +++ bluetooth.c 2001/06/19 06:13:01 1.184 @@ -470,12 +470,7 @@ static s32 bt_chars_in_buffer(struct tty_struct *tty) { - u16 n =3D buf_byte_count(); - /* what if multiple pppd are running and one pppd=20 - ends, then this won't be zero.... */ - - /* fixme -- we must find number bytes belonging to=20 - this line */ + u16 n =3D buf_byte_count(GET_TTYLINE(tty)); =20 BT_DRIVER("bt_chars_in_buffer : %d\n", n);=20=20 return n; @@ -1578,7 +1573,7 @@ =20 /* If buffer usage is less than BTMEM_UNTHROTTLE_SIZE check if we=20 should wake up ldisc */ - if (buf_byte_count() >=3D BTMEM_UNTHROTTLE_SIZE) { + if (buf_byte_count(-1) >=3D BTMEM_UNTHROTTLE_SIZE) { return; }=09 =20=09 @@ -2624,7 +2619,7 @@ statename(SESSIONSTATE(line)), NBR_CTRL_FDS); =20 pos +=3D sprintf(buf+pos, "\n[BTMEM]\n"); - pos +=3D sprintf(buf+pos, "Buffer holds : %d\n", buf_byte_count()); + pos +=3D sprintf(buf+pos, "Buffer holds : %d\n", buf_byte_count(-1)); pos +=3D sprintf(buf+pos, "Bytes left : %d\n", buf_write_room()); =20 return pos; --- btmem.c 2001/06/06 14:57:44 1.42 +++ btmem.c 2001/06/19 06:13:01 1.43 @@ -327,6 +327,7 @@ tx->magic =3D 0x4321; tx->subscr_len =3D send_len; tx->flushed =3D 0; + tx->line =3D -1; =20 sti(); return tx; @@ -341,9 +342,52 @@ =20 /* Returns total number of bytes in buffer (fragmented) */ =20 -s32 buf_byte_count() +s32 buf_byte_count(s32 line) { + u8 *pos =3D bt_buf.head; + bt_tx_buf *tx; + u32 sum =3D 0; + + if (line < 0) { + //printk(__FUNCTION__": Total bytes in buffer %d\n", bt_buf.count); return bt_buf.count; + } else { + if (bt_buf.free > bt_buf.send) { + /* read from send -> free */ + pos =3D bt_buf.send; + while (pos < bt_buf.free) { + tx =3D (bt_tx_buf *)(pos); + if (tx->line =3D=3D line) { + sum +=3D tx->subscr_len; + } + pos +=3D BT_TX_HDRSIZE + tx->subscr_len; + } + } else if (bt_buf.free < bt_buf.send) { + /* read send -> toss_tail + read from head -> free */ + pos =3D bt_buf.send; + while (pos < bt_buf.toss_tail) { + tx =3D (bt_tx_buf *)(pos); + if (tx->line =3D=3D line) { + sum +=3D tx->subscr_len; + } + pos +=3D BT_TX_HDRSIZE + tx->subscr_len; + } +=09=09=09 + pos =3D bt_buf.head;=20 + while (pos < bt_buf.free) { + tx =3D (bt_tx_buf*)(pos); + if (tx->line =3D=3D line) { + sum +=3D tx->subscr_len; + } + pos +=3D BT_TX_HDRSIZE + tx->subscr_len; + } + } else { + /* Buffer empty */ + sum =3D 0; + } + //printk(__FUNCTION__": %d chars in buf for line:%d, total:%d\n", sum, l= ine, bt_buf.count); + return sum; + } } =20 /* Returns unfragmented buffer space */=20 --- rfcomm.c 2001/06/14 10:45:24 1.113 +++ rfcomm.c 2001/06/19 06:13:01 1.114 @@ -1926,6 +1926,7 @@ =20 /* FIXME - How should we propagate result up to higher layers ? through len or success/no success? */ + tx_buf->line =3D rfcomm->line; l2cap_send_data(tx_buf, rfcomm->l2cap); return len; } |
From: Mats F. <ma...@us...> - 2001-06-19 06:13:02
|
The following files were modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- btcommon.h 1.76 1.77=20=20=20=20=20=20=20=20=20=20=20=20 btmem.h 1.18 1.19=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: We need to keep track of how many bytes there are in the BT-buf for each li= ne The diff of the modified file(s): --- btcommon.h 2001/06/15 12:31:55 1.76 +++ btcommon.h 2001/06/19 06:13:01 1.77 @@ -224,6 +224,7 @@ u32 hci_hdl; /* The destination hci connection handle */ u8 pb_flag; /* Packet boundary flag */ u8 bc_flag; /* Broadcast flag */ + s32 line; /* -1 means that the buffer isn't allocated for a line */ =20 /* 'Filled in' data length (up to this point) when creating object. Also used when sending data to mark how much that has been sent --- btmem.h 2001/02/15 16:28:46 1.18 +++ btmem.h 2001/06/19 06:13:01 1.19 @@ -82,7 +82,7 @@ s32 buf_count(void); =20 /* Returns total number of bytes in buffer (fragmented) */ -s32 buf_byte_count(void); +s32 buf_byte_count(s32 line); =20 /* Returns unfragmented buffer space */=20 s32 buf_write_room(void); |
From: Peter K. <pk...@us...> - 2001-06-18 14:45:09
|
The following file was modified in apps/bluetooth/sdp_server: Name Old version New version Comment ---- ----------- ----------- ------- sdp_parser.c 1.19 1.20=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Made it compile with debug enabled. The diff of the modified file(s): --- sdp_parser.c 2001/06/14 10:30:42 1.19 +++ sdp_parser.c 2001/06/18 14:45:08 1.20 @@ -186,7 +186,7 @@ return; } =20 - D_REC("id: 0x%x, trans_id: 0x%x, par_len: %d", id, trans_id, par_len); + D_REC("id: 0x%x, trans_id: 0x%x, par_len: %d", id, db.trans_id, par_len); =20 switch (id) { |
From: Lena H. <le...@us...> - 2001-06-18 14:00:29
|
The following file was modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- Makefile 1.5 1.6=20=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Added GLIBC to AXIS_USABLE_LIBS The diff of the modified file(s): --- Makefile 2001/05/07 11:25:59 1.5 +++ Makefile 2001/06/18 13:59:57 1.6 @@ -1,7 +1,7 @@ # $Id$ =20 ifdef APPS -AXIS_USABLE_LIBS =3D UCLIBC +AXIS_USABLE_LIBS =3D UCLIBC GLIBC include $(APPS)/Rules.elinux endif =20 |
From: Lena H. <le...@us...> - 2001-06-18 14:00:00
|
The following file was modified in apps/bluetooth/sdp_server: Name Old version New version Comment ---- ----------- ----------- ------- Makefile 1.10 1.11=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Added GLIBC to AXIS_USABLE_LIBS The diff of the modified file(s): --- Makefile 2001/05/07 11:25:59 1.10 +++ Makefile 2001/06/18 13:59:58 1.11 @@ -1,7 +1,7 @@ # $Id$ =20 ifdef APPS -AXIS_USABLE_LIBS =3D UCLIBC +AXIS_USABLE_LIBS =3D UCLIBC GLIBC include $(APPS)/Rules.elinux endif =20 |
From: Mats F. <ma...@us...> - 2001-06-18 12:49:32
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- l2cap.c 1.109 1.110=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Use get_lcon instead of get_rcon, since remote cid isn't unik The diff of the modified file(s): --- l2cap.c 2001/06/14 10:52:14 1.109 +++ l2cap.c 2001/06/18 12:49:31 1.110 @@ -857,8 +857,8 @@ D_STATE(__FUNCTION__ ": disconnection request id %d\n",=20 req->id); =20 - if ((con =3D get_rcon(discreq->src_cid)) =3D=3D NULL) { - D_STATE("not connected... discard!\n"); + if ((con =3D get_lcon(discreq->dst_cid)) =3D=3D NULL) { + DSYS(__FUNCTION__"Disconnecting NULL object!\n"); return; } =20 @@ -1443,7 +1443,7 @@ l2cap_con *con;=20 =20 /* temp link down */ - DSYS("lp_disconnect_ind : Connection handle %d disconnected\n", + DSYS(__FUNCTION__": Connection handle %d disconnected\n", con_hdl); =20 /* find & notify/remove l2cap connection(s) on this hci handle */ |
From: Mats F. <ma...@us...> - 2001-06-18 12:15:14
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- hci.c 1.160 1.161=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Corrected bug in inquiry result The diff of the modified file(s): --- hci.c 2001/06/15 12:30:03 1.160 +++ hci.c 2001/06/18 12:15:13 1.161 @@ -789,10 +789,8 @@ } print_data("BD", tmp_bd, 6); for (j =3D 0; j < inq_res->nbr_of_units; j++) { - if (!memcmp(inq_res->bd_addr +=20 - inq_res->nbr_of_units * 6, tmp_bd, - 6)) { - j =3D inq_res->nbr_of_units; + if (!memcmp(inq_res->bd_addr + j * 6, tmp_bd, 6)) { + break; } } if (j >=3D inq_res->nbr_of_units) { |
From: Mats F. <ma...@us...> - 2001-06-15 13:40:34
|
The following file was modified in apps/bluetooth/userstack: Name Old version New version Comment ---- ----------- ----------- ------- unplug_test.c 1.17 1.18=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Removed test_con object The diff of the modified file(s): --- unplug_test.c 2001/06/12 08:58:45 1.17 +++ unplug_test.c 2001/06/15 13:40:34 1.18 @@ -63,7 +63,6 @@ extern sdp_con sdp_con_list[7]; =20 extern l2cap_con *testcon; /* is set in test.c */ -extern l2cap_con *test_con; extern s32 emulate_pending; /* is set in test.c */ extern s32 test_assymmetric_mtu; extern s32 dont_send_config_req; @@ -362,7 +361,7 @@ void test_2_5_1(void) { /* FIXME - Client sends configure request with MTU 4096 */ - if(l2ca_config_req(test_con, 48, NULL, 0, 0)){ + if(l2ca_config_req(testcon, 48, NULL, 0, 0)){ D_ERR("l2ca_connect_cfm : Configuration request failed\n"); } } |
From: Mats F. <ma...@us...> - 2001-06-15 13:39:08
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- hci_vendor.c 1.45 1.46=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Made userstack compile The diff of the modified file(s): --- hci_vendor.c 2001/06/13 11:55:16 1.45 +++ hci_vendor.c 2001/06/15 13:39:08 1.46 @@ -680,7 +680,6 @@ =20=09 return bt_write_lower_driver((u8*) &c_pkt, c_pkt.len + CMD_HDR_LEN + HCI_= HDR_LEN); } -#endif =20 /* When using BCSP this function is used to wait for the COMMAND_STATUS which contains cmd_num */ @@ -699,6 +698,8 @@ } } =20 +#endif + s32=20 csr_pskey(u16 ps_key, u16 rw_mode, u16 *retb, u16 n_pars) { @@ -977,8 +978,9 @@ tmp =3D bt_write_lower_driver((u8*) &c_pkt,=20 c_pkt.len + CMD_HDR_LEN + HCI_HDR_LEN); =20 +#ifdef __KERNEL__ bt_wait_tx(2000); /* wait until DMA empty + 2 ms */ - +#endif hci_ctrl.hc_buf.cmd_num--; =20 return tmp; |
From: Mats F. <ma...@us...> - 2001-06-15 13:38:46
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- test.c 1.14 1.15=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Removed test_con object The diff of the modified file(s): --- test.c 2001/06/15 12:29:23 1.14 +++ test.c 2001/06/15 13:38:45 1.15 @@ -123,7 +123,6 @@ l2cap_con *testcon; l2cap_con *testcon2; l2cap_con *testcon3; -l2cap_con *test_con; s32 emulate_pending =3D 0; s32 test_assymmetric_mtu =3D 0; s32 dont_send_config_req =3D 0; |
From: Peter K. <pk...@us...> - 2001-06-15 12:43:17
|
The following files were modified in apps/bluetooth/btd: Name Old version New version Comment ---- ----------- ----------- ------- btd.c 1.97 1.98=20=20=20=20=20=20=20=20=20=20=20=20 btd.h 1.37 1.38=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: read_remote_bd() now takes a line argument. The diff of the modified file(s): --- btd.c 2001/04/27 16:48:43 1.97 +++ btd.c 2001/06/15 12:43:15 1.98 @@ -298,7 +298,7 @@ static void bt_inquiry(int bt_cfd, int nbr_rsp, int t); static void bt_set_bd_addr(int bt_cfd, int* bd); static void read_local_bd(int bt_cfd, unsigned char *bd_addr); -static void read_remote_bd(int bt_cfd, unsigned char *bd_addr); +static void read_remote_bd(int bt_cfd, int line, unsigned char *bd_addr); static void role_switch(int bt_cfd, unsigned char *bd_addr, int role); #ifndef BTD_USERSTACK static char* bt_hw_vendor(void); @@ -2663,7 +2663,10 @@ struct ipa_client *client; =20 read_local_bd(bt_cfd, local_bd); - read_remote_bd(bt_cfd, remote_bd); + + /* fixme -- for now only use line 0 */ + read_remote_bd(bt_cfd, 0, remote_bd); + /*=20 * Get options from IPAssigner=20 */ @@ -3054,9 +3057,11 @@ =20 /* FIXME -- add "line" parameter to differentiate between the remote devic= es */ void -read_remote_bd(int bt_cfd, unsigned char *bd_addr) +read_remote_bd(int bt_cfd, int line, unsigned char *bd_addr) { #ifndef BTD_USERSTACK + *(int*)bd_addr =3D line; + if (ioctl(bt_cfd, BTREADREMOTEBDADDR, bd_addr) < 0) { perror("Read client bd addr"); @@ -3065,7 +3070,7 @@ BD_ADDR rev_bd; int i; =20=20 - get_remote_bd(rev_bd); + get_remote_bd(line, rev_bd); =20 /* return as big endian */ for (i =3D 0; i < 6; i++) { --- btd.h 2001/04/26 14:02:18 1.37 +++ btd.h 2001/06/15 12:43:16 1.38 @@ -60,7 +60,7 @@ #define BTSETSERTTY _IO(BT_IOC_MAGIC, 0x04) #define BTSETMODEMDUMMY _IOW(BT_IOC_MAGIC, 0x05, int) #define BTSHUTDOWN _IO(BT_IOC_MAGIC, 0x06) -#define BTREADREMOTEBDADDR _IOR(BT_IOC_MAGIC, 0x07, unsigned char[6]) +#define BTREADREMOTEBDADDR _IOWR(BT_IOC_MAGIC, 0x07, unsigned char[6]) #define BTRESETPHYSICALHW _IO(BT_IOC_MAGIC, 0x08) #define BTISINITIATED _IOR(BT_IOC_MAGIC, 0x09, int) #define BTHWVENDOR _IOR(BT_IOC_MAGIC, 0x0A, char[20]) |
From: Peter K. <pk...@us...> - 2001-06-15 12:36:26
|
The following files were modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- bt_if.c 1.19 1.20=20=20=20=20=20=20=20=20=20=20=20=20 bt_if.h 1.13 1.14=20=20=20=20=20=20=20=20=20=20=20=20 btd.c 1.21 1.22=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: read_remote_bd() now takes a line argument. The diff of the modified file(s): --- bt_if.c 2001/06/13 12:26:05 1.19 +++ bt_if.c 2001/06/15 12:36:25 1.20 @@ -642,12 +642,12 @@ printf("done.\n"); } =20 -/* fixme<1> -- add "line" parameter to differentiate between the=20 - remote devices */ void -read_remote_bd(int bt_cfd, unsigned char *bd_addr) +read_remote_bd(int bt_cfd, int line, unsigned char *bd_addr) { #ifndef BT_USERSTACK + *(int*)bd_addr =3D line; + if (ioctl(bt_cfd, BTREADREMOTEBDADDR, bd_addr) < 0) { perror(__FUNCTION__); @@ -656,7 +656,7 @@ BD_ADDR rev_bd; int i; =20 - get_remote_bd(rev_bd); + get_remote_bd(line, rev_bd); =20 /* return as big endian */ for (i =3D 0; i < 6; i++) { --- bt_if.h 2001/06/13 12:25:02 1.13 +++ bt_if.h 2001/06/15 12:36:25 1.14 @@ -144,7 +144,7 @@ #define BTSETSERTTY _IO(BT_IOC_MAGIC, 0x04) #define BTSETMODEMDUMMY _IOW(BT_IOC_MAGIC, 0x05, int) #define BTSHUTDOWN _IO(BT_IOC_MAGIC, 0x06) -#define BTREADREMOTEBDADDR _IOR(BT_IOC_MAGIC, 0x07, unsigned char[6]) +#define BTREADREMOTEBDADDR _IOWR(BT_IOC_MAGIC, 0x07, unsigned char[6]) #define BTRESETPHYSICALHW _IO(BT_IOC_MAGIC, 0x08) #define BTISINITIATED _IOR(BT_IOC_MAGIC, 0x09, int) #define BTHWVENDOR _IOR(BT_IOC_MAGIC, 0x0a, char[20]) @@ -319,7 +319,7 @@ int bt_set_baudrate(int bt_cfd, int spd); void bt_set_bd_addr(int bt_cfd, unsigned char *bd); void read_local_bd(int bt_cfd, unsigned char *bd_addr); -void read_remote_bd(int bt_cfd, unsigned char *bd_addr); +void read_remote_bd(int bt_cfd, int line, unsigned char *bd_addr); void role_switch(int bt_cfd, unsigned char *bd_addr, int role); =20 int bt_set_event_filter(int bt_cfd, unsigned char filter[3]); --- btd.c 2001/06/14 15:13:23 1.21 +++ btd.c 2001/06/15 12:36:25 1.22 @@ -415,7 +415,7 @@ syslog(LOG_INFO, "Found connection on line: %d", line); STATE(line) =3D CONNECTED; =20=20=20=20=20=20=20 - read_remote_bd(bt_cfd, PEER(line).remote_bd); + read_remote_bd(bt_cfd, line, PEER(line).remote_bd); printf("Remote bd: %s\n", bd2str(PEER(line).remote_bd)); =20=20=20=20=20=20=20 if (ipa_available) |
From: Peter K. <pk...@us...> - 2001-06-15 12:31:56
|
The following files were modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- btcommon.h 1.75 1.76=20=20=20=20=20=20=20=20=20=20=20=20 hci.h 1.60 1.61=20=20=20=20=20=20=20=20=20=20=20=20 hci_internal.h 1.18 1.19=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Added line argument to get_remote_bd() and corresponding ioctl to retrieve the BD address for a specific line, instead of the last one connected. The diff of the modified file(s): --- btcommon.h 2001/06/06 14:58:45 1.75 +++ btcommon.h 2001/06/15 12:31:55 1.76 @@ -123,7 +123,7 @@ #define BTSETSERTTY _IO(BT_IOC_MAGIC, 0x04) #define BTSETMODEMDUMMY _IOW(BT_IOC_MAGIC, 0x05, s32) #define BTSHUTDOWN _IO(BT_IOC_MAGIC, 0x06) -#define BTREADREMOTEBDADDR _IOR(BT_IOC_MAGIC, 0x07, u8[6]) +#define BTREADREMOTEBDADDR _IOWR(BT_IOC_MAGIC, 0x07, u8[6]) #define BTRESETPHYSICALHW _IO(BT_IOC_MAGIC, 0x08) #define BTISINITIATED _IOR(BT_IOC_MAGIC, 0x09, s32) #define BTHWVENDOR _IOR(BT_IOC_MAGIC, 0x0A, char[20]) --- hci.h 2001/06/14 10:53:33 1.60 +++ hci.h 2001/06/15 12:31:55 1.61 @@ -170,7 +170,7 @@ =20 /* Internal */ /* FIXME -- add parameter to choose from different devices */ -s32 get_remote_bd(u8 *bd); +s32 get_remote_bd(int line, u8 *bd); =20 /* Testing commands */ s32 hci_enable_dut(void); --- hci_internal.h 2001/06/08 12:50:15 1.18 +++ hci_internal.h 2001/06/15 12:31:55 1.19 @@ -332,7 +332,6 @@ hci_in_buffer hci_in_buf[NBR_OF_HCI_INBUFFERS]; u32 nbr_of_connections; u8 local_bd[6]; - s32 active_connection; hci_con con[MAX_NBR_OF_CONNECTIONS]; } hci_controller; =20 |
From: Peter K. <pk...@us...> - 2001-06-15 12:30:04
|
The following files were modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.182 1.183=20=20=20=20=20=20=20=20=20=20=20 hci.c 1.159 1.160=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Added line argument to get_remote_bd() and corresponding ioctl to retrieve the BD address for a specific line, instead of the last one connected. The diff of the modified file(s): --- bluetooth.c 2001/06/14 10:59:58 1.182 +++ bluetooth.c 2001/06/15 12:30:03 1.183 @@ -628,22 +628,24 @@ break; =20 case BTREADREMOTEBDADDR: - BT_DRIVER(FNC"BTREADREMOTEBDADDR\n"); - - /* FIXME -- add parameter do get remote bd from any - connected device */ - get_remote_bd(bd_addr); - { BD_ADDR rev_bd; + s32 line;=09=20=20 u16 i; + + BT_DRIVER(FNC"BTREADREMOTEBDADDR\n"); + + copy_from_user(&line, (s32*)arg, size); + + get_remote_bd(line, bd_addr); + /* return as big endian */ for (i =3D 0; i < 6; i++) { rev_bd[5-i] =3D bd_addr[i]; } copy_to_user((s32*)arg, rev_bd, 6); - } break; + } =20 case BTRESETPHYSICALHW: bt_reset_phys_hw(); @@ -2429,7 +2431,7 @@ if (!tmp_bt_buf) { page =3D get_free_page(GFP_KERNEL); if (!page) - return; + return -ENOMEM; =20=09=09 if (tmp_bt_buf) free_page(page); --- hci.c 2001/06/14 10:52:14 1.159 +++ hci.c 2001/06/15 12:30:03 1.160 @@ -1609,14 +1609,12 @@ memcpy(hci_ctrl.con[i].bd, bd, 6); hci_ctrl.con[i].con_hdl =3D con_hdl; hci_ctrl.con[i].state =3D UNIT_ACTIVE; - hci_ctrl.active_connection =3D i; return; } } - if (i >=3D MAX_NBR_OF_CONNECTIONS) { + D_ERR(__FUNCTION__ ": No free connection object\n"); } -} =20 void reset_hci_con_bd(u16 con_hdl) { @@ -1630,10 +1628,9 @@ return; } } - if (i >=3D MAX_NBR_OF_CONNECTIONS) { + D_ERR(__FUNCTION__ ": Didn't find connection with con_hdl %d\n", con_hdl= ); } -} =20 void set_hci_con_name(u8 *bd, u8 *name) @@ -1651,10 +1648,9 @@ return; } } - if (i >=3D MAX_NBR_OF_CONNECTIONS) { + D_ERR(__FUNCTION__ ": Didn't fin connecton with BD adress 0x%02x:%02x:%0= 2x:%02x:%02x:%02x\n", bd[5],bd[4],bd[3],bd[2],bd[1],bd[0]); } -} =20 s32 hci_sprint_local_bd(u8 *buf) { @@ -1673,7 +1669,6 @@ =20 pos +=3D sprintf(buf + pos, "unit_id unit_bd_address unit_mode unit_name\= n"); =20 - /* Then we printout the other connections bd addresses and their user friendly device names */ for (i =3D 0; i < MAX_NBR_OF_CONNECTIONS; i++) { @@ -1692,7 +1687,6 @@ } pos +=3D sprintf(buf + pos, "%s\n", hci_ctrl.con[i].name); } - } =20=09 return pos; @@ -3024,17 +3018,13 @@ =20=09 for (i =3D 0 ; i < MAX_NBR_OF_CONNECTIONS ; i ++) { if (memcmp(hci_ctrl.con[i].bd, bd, 6) =3D=3D 0) { - break; + return hci_ctrl.con[i].con_hdl; } } =20 - if (i >=3D MAX_NBR_OF_CONNECTIONS) { D_ERR(__FUNCTION__ ": No connection handle found for bd 0x%02x:%02x:%02x= :%02x:%02x:%02x:\n", bd[5], bd[4], bd[3], bd[2], bd[1], bd[0]); return -1; - } else { - return hci_ctrl.con[i].con_hdl; } -} =20 #ifdef CONFIG_BLUETOOTH_USE_SECURITY_MANAGER u8* @@ -3044,43 +3034,36 @@ =20=20 for (i =3D 0 ; i < MAX_NBR_OF_CONNECTIONS ; i ++) { if (hci_ctrl.con[i].con_hdl =3D=3D con_hdl) { - break; + return hci_ctrl.con[i].bd; } } =20 - if (i >=3D MAX_NBR_OF_CONNECTIONS) { D_ERR(__FUNCTION__ ": No BD Address found for connection handle %d\n", c= on_hdl); return NULL; - } else { - return hci_ctrl.con[i].bd; - } } #endif /* CONFIG_BLUETOOTH_USE_SECURITY_MANAGER */ =20 /* - * This function will return the value of the active bd address, i.e. the - * bd address of the last connected client + * This function will return the BD address for a specific line */ =20 /* Consider changing bd to BD_ADDR */ =20 s32 -get_remote_bd(u8 *bd) +get_remote_bd(s32 line, u8 *bd) { - s32 active =3D hci_ctrl.active_connection; - D_CMD(__FUNCTION__ "\n"); =20 memset(bd, 0, 6); =20 - if (active >=3D 0 && active < MAX_NBR_OF_CONNECTIONS) { - memcpy(bd, hci_ctrl.con[active].bd, 6); + if (line >=3D 0 && line < MAX_NBR_OF_CONNECTIONS) { + memcpy(bd, hci_ctrl.con[line].bd, 6); DSYS(__FUNCTION__": %02x:%02x:%02x:%02x:%02x:%02x\n", bd[5], bd[4], bd[3], bd[2], bd[1], bd[0]); return 0; } else { /* No connection yet */ - D_WARN("get_remote_bd : No active connection!\n"); + D_WARN(__FUNCTION__ ": Unknown line: %d!\n", line); return -1; } } |
From: Mats F. <ma...@us...> - 2001-06-15 12:29:23
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- test.c 1.13 1.14=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Added another l2cap_con object, used for testing The diff of the modified file(s): --- test.c 2001/03/30 12:04:43 1.13 +++ test.c 2001/06/15 12:29:23 1.14 @@ -123,6 +123,7 @@ l2cap_con *testcon; l2cap_con *testcon2; l2cap_con *testcon3; +l2cap_con *test_con; s32 emulate_pending =3D 0; s32 test_assymmetric_mtu =3D 0; s32 dont_send_config_req =3D 0; |
From: Mats F. <ma...@us...> - 2001-06-14 15:13:25
|
The following file was modified in apps/bluetooth/experimental: Name Old version New version Comment ---- ----------- ----------- ------- btd.c 1.20 1.21=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Disconnect bluetooth link if IPA fails The diff of the modified file(s): --- btd.c 2001/06/13 12:18:00 1.20 +++ btd.c 2001/06/14 15:13:23 1.21 @@ -376,11 +376,24 @@ ipa_read(ipa_fd, msg); if ((retval =3D parse_ipa_response(msg)) < 0) { - /* FIXME -- we got an error. Reset peer ? */ - syslog(LOG_INFO, "Got IPA error %d", retval); + unsigned int con_id; + int line =3D ((struct ipa_status*)(msg->msg))->id; + syslog(LOG_INFO, "Got IPA error %d, disconnecting line %d", retval,= line); +=09=20=20=20=20=20=20 + con_id =3D CREATE_RFCOMM_ID(line, 0); +=09=20=20=20=20=20=20 + if (bt_disconnect(bt_cfd, con_id) < 0) + { + /* FIXME: What to do if disconnection fails */ + syslog(LOG_INFO, "Disconnection failed"); + } + else + { + STATE(line) =3D NOCONNECTION; }=20=20=20=20=20=20=20=20=20=20=20 } }=20 + }=20 #endif } break; @@ -929,7 +942,7 @@ /* Check state */ if (STATE(rsp->id) !=3D WAITING_RETURN_PPPCONF) { - syslog(LOG_INFO, __FUNCTION__ ": Wrong state"); + syslog(LOG_INFO, __FUNCTION__ ": Wrong state (case IPARSP_STATUS)"= ); return -ERR_WRONGSTATE; } =20 @@ -959,7 +972,7 @@ /* Check state */ if (STATE(rsp->id) !=3D WAITING_PPPCONF) { - syslog(LOG_INFO, __FUNCTION__ ": Wrong state"); + syslog(LOG_INFO, __FUNCTION__ ": Wrong state case (IPARSP_PEERSETT= INGS)"); return -ERR_WRONGSTATE; } =20 |
From: Mats F. <ma...@us...> - 2001-06-14 10:59:59
|
The following file was modified in linux/drivers/char/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- bluetooth.c 1.181 1.182=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Actually we shouldn't do bt_feedstack when the rfcomm flow is stopped, but for now this is disabled by default, since we don't know which dlci we are using here... The diff of the modified file(s): --- bluetooth.c 2001/06/13 12:45:14 1.181 +++ bluetooth.c 2001/06/14 10:59:58 1.182 @@ -1561,6 +1561,8 @@ return 0; } =20 +//#define IMPROVE_RFCOMM_FLOW + void bt_feedstack(void) { #define FNC "bt_feedstack: " @@ -1614,6 +1616,13 @@ return; } =20=09 +#ifdef IMPROVE_RFCOMM_FLOW + /* FIXME: How should we know what serverchannel we are using ? */ + if (rfcomm_flow_stop(check_line, 2)) { + BT_DATA(__FUNCTION__": Flow stopped in RFCOMM\n"); + return; + } +#endif if ((upper_tty->flags & (1 << TTY_DO_WRITE_WAKEUP)) && upper_tty->ldisc.write_wakeup) { //BT_DATA(" |X|<<*** [%d]\n", check_line); |
From: Mats F. <ma...@us...> - 2001-06-14 10:53:34
|
The following file was modified in linux/include/linux/bluetooth: Name Old version New version Comment ---- ----------- ----------- ------- hci.h 1.59 1.60=20=20=20=20=20=20=20=20=20=20=20=20 The accompanying log: Added exit_park_mode and exit_sniff_mode The diff of the modified file(s): --- hci.h 2001/06/13 12:13:20 1.59 +++ hci.h 2001/06/14 10:53:33 1.60 @@ -131,7 +131,9 @@ /* Link Policy Commands */ s32 hci_hold_mode(u16 hci_hdl, u16 max_int, u16 min_int); s32 hci_sniff_mode(u16 hci_hdl, u16 max_int, u16 min_int, u16 attempt, u16= timeout); +s32 hci_exit_sniff_mode(u16 hci_hdl); s32 hci_park_mode(u16 hci_hdl, u16 max_int, u16 min_int); +s32 hci_exit_park_mode(u16 hci_hdl); s32 hci_switch_role(u8 *bd, u8 role); =20 /* Host Controller and Baseband Commands */ |