Linux bluetooth development
 help / color / mirror / Atom feed
* [PATCH 01/13] android/handsfree: Define proper type for device structure
@ 2014-10-08  7:12 Szymon Janc
  2014-10-08  7:12 ` [PATCH 02/13] android/handsfree: Make init, cleanup and state functions static less Szymon Janc
                   ` (11 more replies)
  0 siblings, 12 replies; 18+ messages in thread
From: Szymon Janc @ 2014-10-08  7:12 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Szymon Janc

---
 android/handsfree.c | 36 +++++++++++++++++++-----------------
 1 file changed, 19 insertions(+), 17 deletions(-)

diff --git a/android/handsfree.c b/android/handsfree.c
index 6c7c061..df3cb42 100644
--- a/android/handsfree.c
+++ b/android/handsfree.c
@@ -110,22 +110,7 @@ struct hfp_codec {
 	bool remote_supported;
 };
 
-static const struct indicator inds_defaults[] = {
-		{ "service",   0, 1, 0, false, true },
-		{ "call",      0, 1, 0, true, true },
-		{ "callsetup", 0, 3, 0, true, true },
-		{ "callheld",  0, 2, 0, true, true },
-		{ "signal",    0, 5, 0, false, true },
-		{ "roam",      0, 1, 0, false, true },
-		{ "battchg",   0, 5, 0, false, true },
-};
-
-static const struct hfp_codec codecs_defaults[] = {
-	{ CODEC_ID_CVSD, true, false},
-	{ CODEC_ID_MSBC, false, false},
-};
-
-static struct {
+struct hf_device {
 	bdaddr_t bdaddr;
 	uint8_t state;
 	uint8_t audio_state;
@@ -152,7 +137,24 @@ static struct {
 
 	GIOChannel *sco;
 	guint sco_watch;
-} device;
+};
+
+static const struct indicator inds_defaults[] = {
+		{ "service",   0, 1, 0, false, true },
+		{ "call",      0, 1, 0, true, true },
+		{ "callsetup", 0, 3, 0, true, true },
+		{ "callheld",  0, 2, 0, true, true },
+		{ "signal",    0, 5, 0, false, true },
+		{ "roam",      0, 1, 0, false, true },
+		{ "battchg",   0, 5, 0, false, true },
+};
+
+static const struct hfp_codec codecs_defaults[] = {
+	{ CODEC_ID_CVSD, true, false},
+	{ CODEC_ID_MSBC, false, false},
+};
+
+static struct hf_device device;
 
 static uint32_t hfp_ag_features = 0;
 
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2014-10-08  9:44 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-08  7:12 [PATCH 01/13] android/handsfree: Define proper type for device structure Szymon Janc
2014-10-08  7:12 ` [PATCH 02/13] android/handsfree: Make init, cleanup and state functions static less Szymon Janc
2014-10-08  7:12 ` [PATCH 03/13] android/handsfree: Pass device as user data to AT handlers Szymon Janc
2014-10-08  7:12 ` [PATCH 04/13] android/handsfree: Pass device to connection handling functions Szymon Janc
2014-10-08  7:12 ` [PATCH 05/13] android/handsfree: Pass device pointer when registering AT commands Szymon Janc
2014-10-08  7:12 ` [PATCH 06/13] android/handsfree: Pass device pointer to codec handling functions Szymon Janc
2014-10-08  7:12 ` [PATCH 07/13] android/handsfree: Pass device to SCO " Szymon Janc
2014-10-08  7:12 ` [PATCH 08/13] android/handsfree: Move clip into device structure Szymon Janc
2014-10-08  8:06   ` Andrei Emeltchenko
2014-10-08  7:12 ` [PATCH 09/13] android/handsfree: Pass device to SCO handling functions Szymon Janc
2014-10-08  8:10   ` Andrei Emeltchenko
2014-10-08  7:12 ` [PATCH 10/13] android/handsfree: Pass device object to disconnect watch Szymon Janc
2014-10-08  7:12 ` [PATCH 11/13] android/handsfree: Pass device to phone state and indicators functions Szymon Janc
2014-10-08  7:12 ` [PATCH 12/13] android/handsfree: Add helper for getting device Szymon Janc
2014-10-08  8:23   ` Andrei Emeltchenko
2014-10-08  9:44     ` Szymon Janc
2014-10-08  7:12 ` [PATCH 13/13] android/handsfree: Make remote device non-static Szymon Janc
2014-10-08  8:30   ` Andrei Emeltchenko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox