summaryrefslogtreecommitdiffstats
path: root/meta/packages/bluez
diff options
context:
space:
mode:
authorMarcin Juszkiewicz <hrw@openedhand.com>2007-09-07 08:58:41 +0000
committerMarcin Juszkiewicz <hrw@openedhand.com>2007-09-07 08:58:41 +0000
commit94346b04b8ddf4b7c18d7143474f714ab4f9ddf1 (patch)
tree81b14b55125031c74960ec0f6f5eeead162530a2 /meta/packages/bluez
parentb860f81b051da13109ef091d25a06b20dc8b9bd6 (diff)
downloadpoky-94346b04b8ddf4b7c18d7143474f714ab4f9ddf1.tar.gz
bluez: dropped not used files
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@2708 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'meta/packages/bluez')
-rw-r--r--meta/packages/bluez/files/base.patch33
-rw-r--r--meta/packages/bluez/files/blueboxes.patch18
-rw-r--r--meta/packages/bluez/files/bluetooth.conf13
-rw-r--r--meta/packages/bluez/files/bluetooth.default37
-rw-r--r--meta/packages/bluez/files/hciattach-ti-bts.patch489
-rw-r--r--meta/packages/bluez/files/hciattach_devlength.patch11
-rw-r--r--meta/packages/bluez/files/hcid.conf72
-rw-r--r--meta/packages/bluez/files/no-user-include.patch18
8 files changed, 0 insertions, 691 deletions
diff --git a/meta/packages/bluez/files/base.patch b/meta/packages/bluez/files/base.patch
deleted file mode 100644
index 337c9aa73e..0000000000
--- a/meta/packages/bluez/files/base.patch
+++ /dev/null
@@ -1,33 +0,0 @@
1
2#
3# Patch managed by http://www.holgerschurig.de/patcher.html
4#
5
6--- bluez-utils-2.17/pcmcia/bluetooth~base.patch
7+++ bluez-utils-2.17/pcmcia/bluetooth
8@@ -15,9 +15,16 @@
9
10 if [ -r ./shared ]; then . ./shared ; else . /etc/pcmcia/shared ; fi
11
12+# Give the port some time to complete initialization
13+sleep 5
14+
15 # Get device attributes
16 get_info $DEVICE
17
18+test "$DEVICE" = "ttyS7" && DEVICE="/dev/tts/7"
19+test -z "$MANFID" && MANFID="bcsp"
20+test "$MANFID" = "0000,0000" && MANFID="bcsp"
21+
22 #
23 # Serial devices
24 #
25@@ -25,7 +32,7 @@
26 IRQ=`setserial /dev/$DEVICE | sed -e 's/.*IRQ: //'`
27 setserial /dev/$DEVICE irq 0 ; setserial /dev/$DEVICE irq $IRQ
28
29- /usr/sbin/hciattach $DEVICE $MANFID
30+ /sbin/hciattach $DEVICE $MANFID
31 }
32 stop_serial() {
33 do_fuser -k -HUP /dev/$DEVICE > /dev/null
diff --git a/meta/packages/bluez/files/blueboxes.patch b/meta/packages/bluez/files/blueboxes.patch
deleted file mode 100644
index c429b06c06..0000000000
--- a/meta/packages/bluez/files/blueboxes.patch
+++ /dev/null
@@ -1,18 +0,0 @@
1
2#
3# Patch managed by http://www.holgerschurig.de/patcher.html
4#
5
6--- bluez-utils-2.14/pcmcia/bluetooth.conf~base
7+++ bluez-utils-2.14/pcmcia/bluetooth.conf
8@@ -26,6 +26,10 @@
9 version "Brain Boxes", "Bluetooth PC Card"
10 bind "serial_cs" class "bluetooth"
11
12+card "F+ Bluetooth_Card, BCSP"
13+ manfid 0x0160, 0xaba0
14+ bind "serial_cs" class "bluetooth"
15+
16 card "IBM Bluetooth PC Card II"
17 version "IBM", "Bluetooth PC Card II"
18 bind "serial_cs" class "bluetooth"
diff --git a/meta/packages/bluez/files/bluetooth.conf b/meta/packages/bluez/files/bluetooth.conf
deleted file mode 100644
index 872084702a..0000000000
--- a/meta/packages/bluez/files/bluetooth.conf
+++ /dev/null
@@ -1,13 +0,0 @@
1#
2# additional cards for /etc/pcmcia/bluetooth.conf
3# Note for OE: This file is _appended_ to the stock
4# bluetooth.conf in bluez-utils, so no need to duplicate
5# entries for individual cards.
6#
7card "CSR BT01x0M Bluetooth CF Card"
8 version "Bluetooth BT0100M", "", ""
9 bind "serial_cs" class "bluetooth"
10
11card "Socket Bluetooth CF Card Rev. G"
12 manfid 0x0104, 0x0096
13 bind "serial_cs" class "bluetooth"
diff --git a/meta/packages/bluez/files/bluetooth.default b/meta/packages/bluez/files/bluetooth.default
deleted file mode 100644
index 4817d38c60..0000000000
--- a/meta/packages/bluez/files/bluetooth.default
+++ /dev/null
@@ -1,37 +0,0 @@
1# Bluetooth configuraton file
2
3# Start of hcid (allowed values are "true" and "false")
4HCID_ENABLE=true
5
6# Config file for hcid
7HCID_CONFIG="/etc/bluetooth/hcid.conf"
8
9# Start sdpd (allowed values are "true" and "false")
10SDPD_ENABLE=true
11
12# Start hidd (allowed values are "true" and "false")
13HIDD_ENABLE=true
14
15# Arguments to hidd
16HIDD_OPTIONS=""
17
18# Run hid2hci (allowed values are "true" and "false")
19HID2HCI_ENABLE=true
20
21# Bind rfcomm devices (allowed values are "true" and "false")
22RFCOMM_ENABLE=true
23
24# Config file for rfcomm
25RFCOMM_CONFIG="/etc/bluetooth/rfcomm.conf"
26
27# Start dund (allowed values are "true" and "false")
28DUND_ENABLE=false
29
30# Arguments to dund
31DUND_OPTIONS="--listen --persist"
32
33# Start pand (allowed values are "true" and "false")
34PAND_ENABLE=false
35
36# Arguments to pand
37PAND_OPTIONS="--listen --role NAP"
diff --git a/meta/packages/bluez/files/hciattach-ti-bts.patch b/meta/packages/bluez/files/hciattach-ti-bts.patch
deleted file mode 100644
index 8fe37de9d3..0000000000
--- a/meta/packages/bluez/files/hciattach-ti-bts.patch
+++ /dev/null
@@ -1,489 +0,0 @@
1--- bluez-utils-2.24/tools/hciattach.c.orig 2005-12-10 15:14:36.000000000 +0100
2+++ bluez-utils-2.24/tools/hciattach.c 2006-01-22 13:56:13.000000000 +0100
3@@ -57,6 +57,8 @@
4 #define HCI_UART_3WIRE 2
5 #define HCI_UART_H4DS 3
6
7+#include "ti_bts.h"
8+
9 struct uart_t {
10 char *type;
11 int m_id;
12@@ -66,6 +68,7 @@
13 int speed;
14 int flags;
15 int (*init) (int fd, struct uart_t *u, struct termios *ti);
16+ char *bts; /* bluetooth script */
17 };
18
19 #define FLOW_CTL 0x0001
20@@ -241,6 +244,114 @@
21 return 0;
22 }
23
24+static int brf6150(int fd, struct uart_t *u, struct termios *ti)
25+{
26+ bts_t *bfp;
27+ int i;
28+ unsigned long vers;
29+ unsigned char actionbuf[256];
30+ unsigned char resp[128]; /* Response */
31+ unsigned long count;
32+ unsigned short atype;
33+
34+ if (u->bts == NULL) /* no script, ignore */
35+ return 0;
36+
37+ bfp = bts_load_script( u->bts, &vers );
38+ if (bfp == NULL)
39+ return -1;
40+
41+ fprintf( stderr, "Loading BTS script version %lu\n", vers );
42+
43+ while ((count = bts_next_action( bfp, actionbuf,
44+ sizeof actionbuf - 1, &atype )) != 0) {
45+ if (atype == ACTION_REMARKS) {
46+ if (actionbuf[0] != 0)
47+ fprintf( stderr, "%s\n", actionbuf );
48+ }
49+ else if (atype == ACTION_SEND_COMMAND) {
50+#if 0
51+ fprintf( stderr, "ACTION_SEND_COMMAND: ", (int)atype );
52+ for (i=0; i<count; i++) {
53+ fprintf( stderr, "0x%02x ", actionbuf[i] );
54+ }
55+ fprintf( stderr, "\n" );
56+#endif
57+ int n;
58+ n = write(fd, actionbuf, count);
59+ if (n < 0 || n < count) {
60+ perror("Failed to write TI action command");
61+ return -1;
62+ }
63+ }
64+ else if (atype == ACTION_WAIT_EVENT) {
65+ action_wait_t *wait = (action_wait_t *)actionbuf;
66+#if 0
67+ fprintf( stderr, "ACTION_WAIT_EVENT: %u msec, %u size, data = ", wait->msec, wait->size );
68+ for (i=0; i<wait->size; i++) {
69+ fprintf( stderr, "0x%02x ", wait->data[i] );
70+ }
71+ fprintf( stderr, "\n" );
72+#endif
73+ usleep(wait->msec); /* seems they give usec, not msec */
74+ /* Read reply. */
75+ if ((count = read_hci_event(fd, resp, sizeof resp)) < 0) {
76+ perror("Failed to read TI command response");
77+ return -1;
78+ }
79+ if (count < wait->size) {
80+ fprintf( stderr, "TI command response is short.");
81+ }
82+ for (i=0; i<wait->size; i++) {
83+ if (i == 3) continue; /* ignore */
84+ if (resp[i] != wait->data[i]) {
85+ fprintf( stderr, "TI command response does not match expected result.\n" );
86+ }
87+ }
88+ }
89+ else if (atype == ACTION_SERIAL_PORT_PARAMETERS) {
90+ action_serial_t *sercmd = (action_serial_t *)actionbuf;
91+
92+ /* Set actual baudrate */
93+ fprintf( stderr,
94+ "BTS changing baud rate to %u, flow control to %u\n",
95+ sercmd->baud, sercmd->flow_control );
96+
97+ tcflush(fd, TCIOFLUSH);
98+
99+ if (sercmd->flow_control)
100+ ti->c_cflag |= CRTSCTS;
101+ else
102+ ti->c_cflag &= ~CRTSCTS;
103+ if (tcsetattr(fd, TCSANOW, ti) < 0) {
104+ perror("Can't set port settings");
105+ return -1;
106+ }
107+
108+ u->speed = sercmd->baud;
109+
110+ tcflush(fd, TCIOFLUSH);
111+ if (set_speed(fd, ti, sercmd->baud) < 0) {
112+ perror("Can't set baud rate");
113+ return -1;
114+ }
115+ }
116+ else if (atype == ACTION_DELAY) {
117+ action_delay_t *delay = (action_delay_t *)actionbuf;
118+ usleep(delay->msec); /* seems they give usec, not msec */
119+ }
120+ else {
121+ fprintf( stderr, "BTS action type = %d: ", (int)atype );
122+ for (i=0; i<count; i++) {
123+ fprintf( stderr, "0x%02x ", actionbuf[i] );
124+ }
125+ fprintf( stderr, "\n" );
126+ }
127+ }
128+ bts_unload_script( bfp );
129+ return 0;
130+}
131+
132 static int texas(int fd, struct uart_t *u, struct termios *ti)
133 {
134 struct timespec tm = {0, 50000};
135@@ -281,14 +392,25 @@
136 } while (resp[4] != cmd[1] && resp[5] != cmd[2]);
137
138 /* Verify manufacturer */
139- if ((resp[11] & 0xFF) != 0x0d)
140+ if (resp[11] != 0x0d)
141 fprintf(stderr,"WARNING : module's manufacturer is not Texas Instrument\n");
142
143 /* Print LMP version */
144- fprintf(stderr, "Texas module LMP version : 0x%02x\n", resp[10] & 0xFF);
145+ fprintf(stderr, "TI module LMP version : 0x%02x\n", resp[10]);
146
147 /* Print LMP subversion */
148- fprintf(stderr, "Texas module LMP sub-version : 0x%02x%02x\n", resp[14] & 0xFF, resp[13] & 0xFF);
149+ fprintf(stderr, "TI module LMP sub-version : 0x%02x%02x\n", resp[14], resp[13]);
150+ if ((resp[14] >> 2) == 3) {
151+ int err;
152+ nanosleep(&tm, NULL);
153+
154+ /* BRF6150 */
155+ if ((err=brf6150( fd, u, ti )) != 0) {
156+ fprintf( stderr, "TI script failed (err=%d)\n",
157+ err );
158+ return -1;
159+ }
160+ }
161
162 nanosleep(&tm, NULL);
163 return 0;
164@@ -953,7 +1075,7 @@
165 {
166 printf("hciattach - HCI UART driver initialization utility\n");
167 printf("Usage:\n");
168- printf("\thciattach [-n] [-p] [-b] [-t timeout] [-s initial_speed] <tty> <type | id> [speed] [flow|noflow]\n");
169+ printf("\thciattach [-n] [-p] [-b] [-t timeout] [-s initial_speed] [-S bts-script] <tty> <type | id> [speed] [flow|noflow]\n");
170 printf("\thciattach -l\n");
171 }
172
173@@ -970,11 +1092,12 @@
174 pid_t pid;
175 struct sigaction sa;
176 char dev[PATH_MAX];
177+ char *bts = NULL;
178
179 detach = 1;
180 printpid = 0;
181
182- while ((opt=getopt(argc, argv, "bnpt:s:l")) != EOF) {
183+ while ((opt=getopt(argc, argv, "bnpt:s:S:l")) != EOF) {
184 switch(opt) {
185 case 'b':
186 send_break = 1;
187@@ -996,6 +1119,10 @@
188 init_speed = atoi(optarg);
189 break;
190
191+ case 'S':
192+ bts = optarg;
193+ break;
194+
195 case 'l':
196 for (i = 0; uart[i].type; i++) {
197 printf("%-10s0x%04x,0x%04x\n", uart[i].type,
198@@ -1067,6 +1194,8 @@
199 if (init_speed)
200 u->init_speed = init_speed;
201
202+ u->bts = bts;
203+
204 memset(&sa, 0, sizeof(sa));
205 sa.sa_flags = SA_NOCLDSTOP;
206 sa.sa_handler = sig_alarm;
207--- bluez-utils-2.24/tools/Makefile.am.orig 2005-12-03 07:22:16.000000000 +0100
208+++ bluez-utils-2.24/tools/Makefile.am 2006-01-22 13:53:59.000000000 +0100
209@@ -37,6 +37,9 @@
210
211 noinst_PROGRAMS = hcisecfilter ppporc
212
213+hciattach_SOURCES = hciattach.c ti_bts.h ti_bts.c
214+hciattach_LDADD = @BLUEZ_LIBS@
215+
216 hciconfig_SOURCES = hciconfig.c csr.h csr.c
217 hciconfig_LDADD = @BLUEZ_LIBS@ $(top_builddir)/common/libtextfile.a
218
219--- bluez-utils-2.24/tools/ti_bts.h.orig 2006-01-22 13:56:38.000000000 +0100
220+++ bluez-utils-2.24/tools/ti_bts.h 2006-01-22 13:53:59.000000000 +0100
221@@ -0,0 +1,116 @@
222+/*
223+ * Copyright (c) 2005 Texas Instruments, Inc.
224+ * Ported by SDG Systems, LLC
225+ *
226+ * This program is free software; you can redistribute it and/or modify
227+ * it under the terms of the GNU General Public License version 2 as
228+ * published by the Free Software Foundation;
229+ *
230+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
231+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
232+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS.
233+ * IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) AND AUTHOR(S) BE LIABLE FOR ANY
234+ * CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES
235+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
236+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
237+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
238+ *
239+ * ALL LIABILITY, INCLUDING LIABILITY FOR INFRINGEMENT OF ANY PATENTS,
240+ * COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS, RELATING TO USE OF THIS
241+ * SOFTWARE IS DISCLAIMED.
242+ *
243+ */
244+
245+#ifndef BT_SCRIPT_H
246+#define BT_SCRIPT_H
247+
248+#ifdef __cplusplus
249+extern "C" {
250+#endif
251+
252+/*
253+ * Define the interface of Bluetooth Script
254+ */
255+
256+typedef void bts_t;
257+
258+
259+#define ACTION_SEND_COMMAND 1 /* Send out raw data (as is) */
260+#define ACTION_WAIT_EVENT 2 /* Wait for data */
261+#define ACTION_SERIAL_PORT_PARAMETERS 3
262+#define ACTION_DELAY 4
263+#define ACTION_RUN_SCRIPT 5
264+#define ACTION_REMARKS 6
265+
266+/*
267+ * Structure for ACTION_SEND_COMMAND
268+ */
269+typedef struct tagCActionCommand
270+{
271+ unsigned char data[1]; /* Data to send */
272+} action_command_t;
273+
274+/*
275+ * Structure for ACTION_WAIT_EVENT
276+ */
277+typedef struct tagCActionWaitEvent
278+{
279+ unsigned long msec; /* in milliseconds */
280+ unsigned long size;
281+ unsigned char data[1]; /* Data to wait for */
282+} action_wait_t;
283+
284+
285+/*
286+ * Structure for ACTION_SERIAL_PORT_PARAMETERS
287+ */
288+typedef struct tagCActionSerialPortParameters
289+{
290+ unsigned long baud;
291+ unsigned long flow_control;
292+} action_serial_t;
293+
294+/* Flow Control Type */
295+#define FCT_NONE 0
296+#define FCT_HARDWARE 1
297+
298+#define DONT_CHANGE 0xFFFFFFFF /* For both baud rate and flow control */
299+
300+
301+/*
302+ * Structure for ACTION_DELAY
303+ */
304+typedef struct tagCActionDelay
305+{
306+ unsigned long msec; /* in milliseconds */
307+} action_delay_t;
308+
309+/*
310+ * Structure for ACTION_RUN_SCRIPT
311+ */
312+typedef struct tagCActionRunScript
313+{
314+ char filename[1];
315+} action_run_t;
316+
317+/*
318+ * Structure for ACTION_REMARKS
319+ */
320+typedef struct tagCActionRemarks
321+{
322+ char m_szRemarks[1];
323+} action_remarks_t;
324+
325+
326+const char *cis_create_filename(const unsigned char* cmdparms);
327+bts_t * bts_load_script(const char* fname, unsigned long* version);
328+unsigned long bts_next_action(const bts_t* bts_fp, unsigned char* action_buf,
329+ unsigned long nMaxSize, unsigned short* ptype);
330+void bts_unload_script(bts_t* bts_fp);
331+
332+#ifdef __cplusplus
333+};
334+#endif
335+
336+#endif /* BT_SCRIPT_H */
337+
338--- bluez-utils-2.24/tools/ti_bts.c.orig 2006-01-22 13:56:36.000000000 +0100
339+++ bluez-utils-2.24/tools/ti_bts.c 2006-01-22 13:56:31.000000000 +0100
340@@ -0,0 +1,149 @@
341+/*
342+ * Copyright (c) 2005 Texas Instruments, Inc.
343+ * Ported by SDG Systems, LLC
344+ *
345+ * This program is free software; you can redistribute it and/or modify
346+ * it under the terms of the GNU General Public License version 2 as
347+ * published by the Free Software Foundation;
348+ *
349+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
350+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
351+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS.
352+ * IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) AND AUTHOR(S) BE LIABLE FOR ANY
353+ * CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES
354+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
355+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
356+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
357+ *
358+ * ALL LIABILITY, INCLUDING LIABILITY FOR INFRINGEMENT OF ANY PATENTS,
359+ * COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS, RELATING TO USE OF THIS
360+ * SOFTWARE IS DISCLAIMED.
361+ *
362+ */
363+
364+
365+#include <stdio.h>
366+#include <stdlib.h>
367+#include "ti_bts.h"
368+
369+#ifndef MAKEWORD
370+#define MAKEWORD(a, b) ((unsigned short)(((unsigned char)(a)) | ((unsigned short)((unsigned char)(b))) << 8))
371+#endif
372+
373+#define TI_MANUFACTURER_ID 13
374+
375+/*
376+ * Common Init Script specific
377+ */
378+const char *
379+cis_create_filename(const unsigned char* cmdparms)
380+{
381+ static char bts_file[50];
382+
383+ /* Check for TI's id */
384+ unsigned short manfid = MAKEWORD(cmdparms[8], cmdparms[9]);
385+
386+ if (TI_MANUFACTURER_ID == manfid) {
387+ unsigned short version = MAKEWORD(cmdparms[10], cmdparms[11]);
388+
389+ unsigned short chip = (version & 0x7C00) >> 10;
390+ unsigned short min_ver = (version & 0x007F);
391+ unsigned short maj_ver = (version & 0x0380) >> 7;
392+
393+ if (0 != (version & 0x8000)) {
394+ maj_ver |= 0x0008;
395+ }
396+
397+ sprintf( bts_file, "TIInit_%d.%d.%d.bts",
398+ (int)chip, (int)maj_ver, (int)min_ver);
399+
400+ return &bts_file[0];
401+ }
402+ return NULL;
403+}
404+
405+typedef struct tagCHeader
406+{
407+ unsigned long magic;
408+ unsigned long version;
409+ unsigned char future[24];
410+} cheader_t;
411+
412+
413+/* The value 0x42535442 stands for (in ASCII) BTSB */
414+/* which is Bluetooth Script Binary */
415+#define FILE_HEADER_MAGIC 0x42535442
416+
417+
418+bts_t *
419+bts_load_script(const char* fname, unsigned long* version)
420+{
421+ bts_t* bts = NULL;
422+ FILE* fp = fopen(fname, "rb");
423+
424+ if (NULL != fp) {
425+ /* Read header */
426+ cheader_t header;
427+
428+ /* Read header */
429+ if (1 == fread(&header, sizeof(header), 1, fp)) {
430+ /* Check magic number for correctness */
431+ if (header.magic == FILE_HEADER_MAGIC) {
432+ /* If user wants the version number */
433+ if (NULL != version) {
434+ *version = header.version;
435+ }
436+ bts = (bts_t*)fp;
437+ }
438+ }
439+ /* If failed reading the file, close it */
440+ if (NULL == bts) {
441+ fclose(fp);
442+ }
443+ }
444+ return bts;
445+}
446+
447+unsigned long
448+bts_next_action(const bts_t* bts_fp, unsigned char* action_buf,
449+ unsigned long nMaxSize, unsigned short* ptype)
450+{
451+ unsigned long bytes = 0;
452+ FILE* fp = (FILE*)bts_fp;
453+ unsigned char action_hdr[4];
454+
455+ if (bts_fp == NULL)
456+ return 0;
457+
458+ /* Each Action has the following: */
459+ /* UINT16 type of this action */
460+ /* UINT16 size of rest */
461+ /* BYTE[] action buffer (for HCI, includes the type byte e.g. 1 for hci command) */
462+
463+ if (1 == fread(&action_hdr[0], sizeof(action_hdr), 1, fp)) {
464+ unsigned short type = *(unsigned short*)&action_hdr[0];
465+ unsigned short size = *(unsigned short*)&action_hdr[2];
466+
467+ if (size <= nMaxSize) {
468+ int nread = fread(action_buf, sizeof(action_buf[0]), size, fp);
469+
470+ if (nread == size) {
471+ *ptype = type;
472+ bytes = (unsigned long)size;
473+ }
474+ }
475+ }
476+
477+ return bytes;
478+}
479+
480+void
481+bts_unload_script(bts_t* bts_fp)
482+{
483+ FILE* fp = (FILE*)bts_fp;
484+
485+ if (NULL != fp) {
486+ fclose(fp);
487+ }
488+}
489+
diff --git a/meta/packages/bluez/files/hciattach_devlength.patch b/meta/packages/bluez/files/hciattach_devlength.patch
deleted file mode 100644
index 8d84cb1b00..0000000000
--- a/meta/packages/bluez/files/hciattach_devlength.patch
+++ /dev/null
@@ -1,11 +0,0 @@
1--- bluez-utils-2.21/tools/hciattach.c.orig 2005-12-15 16:29:55.000000000 +0100
2+++ bluez-utils-2.21/tools/hciattach.c 2005-12-15 16:29:37.000000000 +0100
3@@ -973,7 +973,7 @@
4 int send_break = 0;
5 pid_t pid;
6 struct sigaction sa;
7- char dev[20];
8+ char dev[25];
9
10 detach = 1;
11 printpid = 0;
diff --git a/meta/packages/bluez/files/hcid.conf b/meta/packages/bluez/files/hcid.conf
deleted file mode 100644
index 44e9c46fb0..0000000000
--- a/meta/packages/bluez/files/hcid.conf
+++ /dev/null
@@ -1,72 +0,0 @@
1#
2# HCI daemon configuration file.
3#
4# $Id: hcid.conf,v 1.4 2004/04/29 20:14:21 holtmann Exp $
5#
6
7# HCId options
8options {
9 # Automatically initialize new devices
10 autoinit yes;
11
12 # Security Manager mode
13 # none - Security manager disabled
14 # auto - Use local PIN for incoming connections
15 # user - Always ask user for a PIN
16 #
17 security auto;
18
19 # Pairing mode
20 # none - Pairing disabled
21 # multi - Allow pairing with already paired devices
22 # once - Pair once and deny successive attempts
23 pairing multi;
24
25 # PIN helper
26 pin_helper /bin/bluepin;
27
28 # D-Bus PIN helper
29 # dbus_pin_helper;
30}
31
32# Default settings for HCI devices
33device {
34 # Local device name
35 # %d - device id
36 # %h - host name
37 name "%h";
38
39 # Local device class
40 class 0x120112;
41
42 # Default packet type
43 #pkt_type DH1,DM1,HV1;
44
45 # Inquiry and Page scan
46 iscan enable; pscan enable;
47
48 # Default link mode
49 # none - no specific policy
50 # accept - always accept incoming connections
51 # master - become master on incoming connections,
52 # deny role switch on outgoing connections
53 #
54 #lm accept,master;
55 #
56 lm accept;
57
58 # Default link policy
59 # none - no specific policy
60 # rswitch - allow role switch
61 # hold - allow hold mode
62 # sniff - allow sniff mode
63 # park - allow park mode
64 #
65 #lp hold,sniff;
66 #
67 lp rswitch,hold,sniff,park;
68
69 # Authentication and Encryption
70 #auth enable;
71 encrypt enable;
72}
diff --git a/meta/packages/bluez/files/no-user-include.patch b/meta/packages/bluez/files/no-user-include.patch
deleted file mode 100644
index 8c1b1b6d6d..0000000000
--- a/meta/packages/bluez/files/no-user-include.patch
+++ /dev/null
@@ -1,18 +0,0 @@
1Do not add -I/usr/include to the compile line just because we will
2install bluez-utils there says zecke...
3
4Index: bluez-utils-2.25/acinclude.m4
5===================================================================
6--- bluez-utils-2.25.orig/acinclude.m4 2006-05-18 12:39:57.473577920 +0200
7+++ bluez-utils-2.25/acinclude.m4 2006-05-19 00:58:52.694599848 +0200
8@@ -69,7 +69,9 @@
9 ac_save_LDFLAGS=$LDFLAGS
10
11 BLUEZ_CFLAGS=""
12- test -d "${bluez_prefix}/include" && BLUEZ_CFLAGS="$BLUEZ_CFLAGS -I${bluez_prefix}/include"
13+ if test "$cross_compiling" = no; then
14+ test -d "${bluez_prefix}/include" && BLUEZ_CFLAGS="$BLUEZ_CFLAGS -I${bluez_prefix}/include"
15+ fi
16
17 CPPFLAGS="$CPPFLAGS $BLUEZ_CFLAGS"
18 AC_CHECK_HEADER(bluetooth/bluetooth.h, dummy=yes, AC_MSG_ERROR(Bluetooth header files not found))