[oe-commits] org.oe.dev bluez-utils 3.23: Revamp brf6150 hispeed support.

pfalcon commit openembedded-commits at lists.openembedded.org
Mon Dec 24 13:04:56 UTC 2007


bluez-utils 3.23: Revamp brf6150 hispeed support.
* Fixes #3520.

Author: pfalcon at openembedded.org
Branch: org.openembedded.dev
Revision: 1585e84b2f1f1c143a60c4d80cd9b5f9dfd1bfa7
ViewMTN: http://monotone.openembedded.org/revision/info/1585e84b2f1f1c143a60c4d80cd9b5f9dfd1bfa7
Files:
1
packages/bluez/bluez-utils/hciattach-ti-bts.patch
packages/bluez/bluez-utils3.inc
packages/bluez/bluez-utils_3.23.bb
Diffs:

#
# mt diff -r7b374568bec2e4e827db4c01cb9353aa0b61d4d4 -r1585e84b2f1f1c143a60c4d80cd9b5f9dfd1bfa7
#
# 
# 
# patch "packages/bluez/bluez-utils/hciattach-ti-bts.patch"
#  from [1d4e3c1718d18414e477efcb65a77b37de1616cb]
#    to [2325160feaae636c3e834dcf0b73984945c0899f]
# 
# patch "packages/bluez/bluez-utils3.inc"
#  from [57a5ef74c55de81a92629f96194e3390e75484af]
#    to [4e06e74f7b9a84e626e018ff0d2e9969bdd5ac67]
# 
# patch "packages/bluez/bluez-utils_3.23.bb"
#  from [585b498ec4a54ca79531aca3aabb3569a3dd6476]
#    to [ced9c6fefb46b72511b94a625501250c47472202]
# 
============================================================
--- packages/bluez/bluez-utils/hciattach-ti-bts.patch	1d4e3c1718d18414e477efcb65a77b37de1616cb
+++ packages/bluez/bluez-utils/hciattach-ti-bts.patch	2325160feaae636c3e834dcf0b73984945c0899f
@@ -1,6 +1,6 @@
 --- bluez-utils-3.1/tools/hciattach.c.orig	2006-07-23 14:02:14.000000000 +0200
 +++ bluez-utils-3.1/tools/hciattach.c	2006-07-23 14:06:29.000000000 +0200
-@@ -58,6 +58,8 @@
+@@ -60,6 +60,8 @@
  #define HCI_UART_3WIRE	2
  #define HCI_UART_H4DS	3
  
@@ -9,15 +9,15 @@
  struct uart_t {
  	char *type;
  	int  m_id;
-@@ -67,6 +69,7 @@
- 	int  speed;
+@@ -70,6 +72,7 @@
  	int  flags;
+ 	char *bdaddr;
  	int  (*init) (int fd, struct uart_t *u, struct termios *ti);
 +	char *bts;	/* bluetooth script */
  };
  
  #define FLOW_CTL	0x0001
-@@ -256,6 +259,114 @@
+@@ -279,6 +282,114 @@
  	return 0;
  }
  
@@ -132,29 +132,17 @@
  static int texas(int fd, struct uart_t *u, struct termios *ti)
  {
  	struct timespec tm = {0, 50000};
-@@ -296,15 +407,26 @@
- 	} while (resp[4] != cmd[1] && resp[5] != cmd[2]);
+@@ -328,6 +439,17 @@
+ 	/* Print LMP subversion */
+ 	fprintf(stderr, "Texas module LMP sub-version : 0x%02x%02x\n", resp[14] & 0xFF, resp[13] & 0xFF);
  
- 	/* Verify manufacturer */
--	if ((resp[11] & 0xFF) != 0x0d)
-+	if (resp[11] != 0x0d)
- 		fprintf(stderr,"WARNING : module's manufacturer is not Texas Instrument\n");
- 
- 	/* Print LMP version */
--	fprintf(stderr, "Texas module LMP version : 0x%02x\n", resp[10] & 0xFF);
-+	fprintf(stderr, "TI module LMP version : 0x%02x\n", resp[10]);
- 
- 	/* Print LMP subversion */
--	fprintf(stderr, "Texas module LMP sub-version : 0x%02x%02x\n", resp[14] & 0xFF, resp[13] & 0xFF);
-+	fprintf(stderr, "TI module LMP sub-version : 0x%02x%02x\n", resp[14], resp[13]);
 +	if ((resp[14] >> 2) == 3) {
++		/* BRF6150 */
 +		int err;
++
 +		nanosleep(&tm, NULL);
- 
-+		/* BRF6150 */
-+		if ((err=brf6150( fd, u, ti )) != 0) {
-+			fprintf( stderr, "TI script failed (err=%d)\n",
-+				err );
++		if ((err = brf6150(fd, u, ti)) != 0) {
++			fprintf(stderr, "Texas module script failed (err=%d)\n", err);
 +			return -1;
 +		}
 +	}
@@ -162,16 +150,16 @@
  	nanosleep(&tm, NULL);
  	return 0;
  }
-@@ -1103,7 +1225,7 @@
+@@ -1204,7 +1326,7 @@
  {
  	printf("hciattach - HCI UART driver initialization utility\n");
  	printf("Usage:\n");
--	printf("\thciattach [-n] [-p] [-b] [-t timeout] [-s initial_speed] <tty> <type | id> [speed] [flow|noflow]\n");
-+	printf("\thciattach [-n] [-p] [-b] [-t timeout] [-s initial_speed] [-S bts-script] <tty> <type | id> [speed] [flow|noflow]\n");
+-	printf("\thciattach [-n] [-p] [-b] [-t timeout] [-s initial_speed] <tty> <type | id> [speed] [flow|noflow] [bdaddr]\n");
++	printf("\thciattach [-n] [-p] [-b] [-t timeout] [-s initial_speed] [-S bts-script] <tty> <type | id> [speed] [flow|noflow] [bdaddr]\n");
  	printf("\thciattach -l\n");
  }
  
-@@ -1118,11 +1240,12 @@
+@@ -1219,11 +1341,12 @@
  	struct sigaction sa;
  	struct pollfd p;
  	char dev[PATH_MAX];
@@ -185,7 +173,7 @@
  		switch(opt) {
  		case 'b':
  			send_break = 1;
-@@ -1144,6 +1267,10 @@
+@@ -1245,6 +1368,10 @@
  			init_speed = atoi(optarg);
  			break;
  
@@ -196,7 +184,7 @@
  		case 'l':
  			for (i = 0; uart[i].type; i++) {
  				printf("%-10s0x%04x,0x%04x\n", uart[i].type,
-@@ -1215,6 +1342,8 @@
+@@ -1320,6 +1447,8 @@
  	if (init_speed)
  		u->init_speed = init_speed;
  
@@ -205,17 +193,6 @@
  	memset(&sa, 0, sizeof(sa));
  	sa.sa_flags   = SA_NOCLDSTOP;
  	sa.sa_handler = sig_alarm;
---- bluez-utils-3.1/tools/Makefile.am.orig	2006-07-23 14:06:59.000000000 +0200
-+++ bluez-utils-3.1/tools/Makefile.am	2006-07-23 14:07:18.000000000 +0200
-@@ -37,7 +37,7 @@
- 
- noinst_PROGRAMS = hcisecfilter ppporc
- 
--hciattach_SOURCES = hciattach.c hciattach_st.c
-+hciattach_SOURCES = hciattach.c hciattach_st.c ti_bts.h ti_bts.c
- 
- hciconfig_SOURCES = hciconfig.c csr.h csr.c
- hciconfig_LDADD = @BLUEZ_LIBS@ $(top_builddir)/common/libhelper.a
 --- bluez-utils-3.1/tools/ti_bts.h.orig	2006-07-23 14:07:26.000000000 +0200
 +++ bluez-utils-3.1/tools/ti_bts.h	2006-07-23 14:07:46.000000000 +0200
 @@ -0,0 +1,116 @@
@@ -487,3 +464,14 @@
 +    }
 +}
 +
+--- bluez-utils-3.1/tools/Makefile.am.orig	2006-07-23 14:06:59.000000000 +0200
++++ bluez-utils-3.1/tools/Makefile.am	2006-07-23 14:07:18.000000000 +0200
+@@ -45,7 +45,7 @@
+ 
+ noinst_PROGRAMS = hcisecfilter ppporc
+ 
+-hciattach_SOURCES = hciattach.c hciattach_st.c
++hciattach_SOURCES = hciattach.c hciattach_st.c ti_bts.h ti_bts.c
+ hciattach_LDADD = @BLUEZ_LIBS@
+ 
+ hciconfig_SOURCES = hciconfig.c csr.h csr.c
============================================================
--- packages/bluez/bluez-utils3.inc	57a5ef74c55de81a92629f96194e3390e75484af
+++ packages/bluez/bluez-utils3.inc	4e06e74f7b9a84e626e018ff0d2e9969bdd5ac67
@@ -8,10 +8,10 @@ LICENSE = "GPL"
 RCONFLICTS_${PN} = "bluez-utils-nodbus"
 LICENSE = "GPL"
 
-# ti patch doesn't apply, people using it should rediff it and send it upstream
+# ti patch should be sent it upstream!
 SRC_URI = "http://bluez.sourceforge.net/download/bluez-utils-${PV}.tar.gz \
-           file://hcid.conf "
-#           file://hciattach-ti-bts.patch;patch=1 \
+           file://hcid.conf \
+           file://hciattach-ti-bts.patch;patch=1"
 
 S = "${WORKDIR}/bluez-utils-${PV}"
 
============================================================
--- packages/bluez/bluez-utils_3.23.bb	585b498ec4a54ca79531aca3aabb3569a3dd6476
+++ packages/bluez/bluez-utils_3.23.bb	ced9c6fefb46b72511b94a625501250c47472202
@@ -1,4 +1,5 @@ require bluez-utils3.inc
 require bluez-utils3.inc
+PR = "1"
 
 # see bluez-utils3.inc for the explanation of these option
 EXTRA_OECONF = " \






More information about the Openembedded-commits mailing list